Initial commit

This commit is contained in:
Tom Wiesing 2020-06-01 16:46:03 +02:00
commit 5a1bf22e0b
No known key found for this signature in database
GPG key ID: DC1F29F2BC78AB15
15 changed files with 1604 additions and 0 deletions

17
factory/shell.sh Normal file
View file

@ -0,0 +1,17 @@
#!/bin/bash
set -e
# read the lib/shared.sh and lib/slug.sh
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
cd "$DIR"
source "$DIR/lib/lib.sh"
require_slug_argument
log_info " => Opening shell in '$COMPOSER_DIR'"
# cd into the right directory.
cd "$COMPOSER_DIR"
# add /usr/local/bin (for composer) and the vendor bin (for drush) to path
# and open a bash shell as www-data there.
sudo -u "$SYSTEM_USER" PATH="$COMPOSER_DIR/vendor/bin:/usr/local/bin:$PATH" /bin/bash