This repository has been archived by the owner on Dec 14, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Issue #140: Drush aliases inside parrot.
- Loading branch information
1 parent
4d8381a
commit 3081cd3
Showing
3 changed files
with
63 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
25 changes: 25 additions & 0 deletions
25
modules/parrot_drush/manifests/components/php/drush_alias.pp
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
define parrot_drush::components::php::drush_alias ( | ||
$root, | ||
$ensure = 'present', | ||
$uri = $name, | ||
$php_executable = undef, | ||
$protocol = '', | ||
) | ||
{ | ||
|
||
file {"/home/vagrant/.drush/$name.aliases.drushrc.php": | ||
ensure => $ensure, | ||
owner => 'root', | ||
group => 'root', | ||
content => template('parrot_drush/php/drush_alias.erb'), | ||
#require => File['/home/vagrant/.drush'], | ||
} | ||
|
||
file {"/root/.drush/$name.aliases.drushrc.php": | ||
ensure => $ensure, | ||
owner => 'www-data', | ||
group => 'www-data', | ||
content => template('parrot_drush/php/drush_alias.erb'), | ||
#require => File['/root/.drush'], | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<?php | ||
|
||
$aliases['<%= @name %>'] = array( | ||
'uri' => '<%= @protocol %><%= @uri %>', | ||
'root' => '<%= @root %>', | ||
<%- if @php_executable -%> | ||
'php' => '<%= @php_executable %>', | ||
<%- end -%> | ||
'local' => TRUE, // Required to avoid double-calling, see https://github.com/drush-ops/drush/issues/1870 | ||
); |