Merge pull request #275 from progrium/shebang-pipefail

normalizing shebang and bash options + long-term fix for bootstrap instructions
This commit is contained in:
rhy-jot committed 2013-10-30 15:41:39 -07:00
commit fc11d5b8e9
15 files changed
+32 -32

No files matched your search

+4 -5
View File
@@ -1,6 +1,5 @@
#!/usr/bin/env sh #!/usr/bin/env bash
set -eo pipefail
set -e
export DEBIAN_FRONTEND=noninteractive export DEBIAN_FRONTEND=noninteractive
export DOKKU_REPO=${DOKKU_REPO:-"https://github.com/progrium/dokku.git"} export DOKKU_REPO=${DOKKU_REPO:-"https://github.com/progrium/dokku.git"}
@@ -18,5 +17,5 @@ cd dokku && test $DOKKU_BRANCH && git checkout origin/$DOKKU_BRANCH || true
make install make install
echo echo
echo "Be sure to upload a public key for your user:" echo "Almost done! For next steps on configuration:"
echo " cat ~/.ssh/id_rsa.pub | ssh root@$HOSTNAME \"gitreceive upload-key progrium\"" echo " https://github.com/progrium/dokku#configuring"
+1 -6
View File
@@ -1,6 +1,5 @@
#!/usr/bin/env bash #!/usr/bin/env bash
set -e set -eo pipefail; [[ $DOKKU_TRACE ]] && set -x
set -o pipefail
export PLUGIN_PATH=${PLUGIN_PATH:="/var/lib/dokku/plugins"} export PLUGIN_PATH=${PLUGIN_PATH:="/var/lib/dokku/plugins"}
export DOKKU_ROOT=${DOKKU_ROOT:="/home/dokku"} export DOKKU_ROOT=${DOKKU_ROOT:="/home/dokku"}
@@ -9,16 +8,12 @@ case "$1" in
APP="$2"; IMAGE="app/$APP" APP="$2"; IMAGE="app/$APP"
echo "-----> Building $APP ..." echo "-----> Building $APP ..."
cat | dokku build $APP $IMAGE cat | dokku build $APP $IMAGE
echo "-----> Build complete!"
echo "-----> Releasing $APP ..." echo "-----> Releasing $APP ..."
dokku release $APP $IMAGE dokku release $APP $IMAGE
echo "-----> Release complete!"
echo "-----> Deploying $APP ..." echo "-----> Deploying $APP ..."
dokku deploy $APP $IMAGE dokku deploy $APP $IMAGE
echo "-----> Deploy complete!"
echo "-----> Cleaning up ..." echo "-----> Cleaning up ..."
dokku cleanup dokku cleanup
echo "-----> Cleanup complete!"
echo "=====> Application deployed:" echo "=====> Application deployed:"
echo " $(dokku url $APP)" echo " $(dokku url $APP)"
echo echo
+3 -2
View File
@@ -1,5 +1,6 @@
#!/bin/bash #!/usr/bin/env bash
set -e; case "$1" in set -eo pipefail
case "$1" in
delete) delete)
if [[ -z $2 ]]; then if [[ -z $2 ]]; then
echo "Please specify an app to delete" echo "Please specify an app to delete"
+2 -1
View File
@@ -1,4 +1,5 @@
#!/bin/bash #!/usr/bin/env bash
set -eo pipefail
sed -i 's/docker -d$/docker -d -r=true/' /etc/init/docker.conf sed -i 's/docker -d$/docker -d -r=true/' /etc/init/docker.conf
+2 -2
View File
@@ -1,3 +1,3 @@
#!/bin/bash #!/usr/bin/env bash
set -e set -eo pipefail
[[ -n $1 ]] && rm -r "$DOKKU_ROOT/$1" > /dev/null [[ -n $1 ]] && rm -r "$DOKKU_ROOT/$1" > /dev/null
+2 -2
View File
@@ -1,5 +1,5 @@
#!/bin/bash #!/usr/bin/env bash
set -e; set -eo pipefail
# Check if name is specified # Check if name is specified
if [[ $1 == config ]] || [[ $1 == config:* ]]; then if [[ $1 == config ]] || [[ $1 == config:* ]]; then
+2 -2
View File
@@ -1,5 +1,5 @@
#!/bin/bash #!/usr/bin/env bash
set -e; set -eo pipefail
case "$1" in case "$1" in
git-hook) git-hook)
+2 -1
View File
@@ -1,2 +1,3 @@
#!/bin/bash #!/usr/bin/env bash
set -eo pipefail
cat cat
+2 -1
View File
@@ -1,4 +1,5 @@
#!/bin/bash #!/usr/bin/env bash
set -eo pipefail
# latest stable NGINX 1.4.x with websocket support # latest stable NGINX 1.4.x with websocket support
add-apt-repository -y ppa:nginx/stable add-apt-repository -y ppa:nginx/stable
+2 -2
View File
@@ -1,3 +1,3 @@
#!/bin/bash #!/usr/bin/env bash
set -e set -eo pipefail
sudo /etc/init.d/nginx reload > /dev/null sudo /etc/init.d/nginx reload > /dev/null
+2 -2
View File
@@ -1,5 +1,5 @@
#!/bin/bash #!/usr/bin/env bash
set -e set -eo pipefail
APP="$1"; PORT="$2" APP="$1"; PORT="$2"
WILDCARD_SSL="$DOKKU_ROOT/ssl" WILDCARD_SSL="$DOKKU_ROOT/ssl"
SSL="$DOKKU_ROOT/$APP/ssl" SSL="$DOKKU_ROOT/$APP/ssl"
+2 -2
View File
@@ -1,5 +1,5 @@
#!/bin/bash #!/usr/bin/env bash
set -e set -eo pipefail
KEYNAME="$1" KEYNAME="$1"
indent() { sed "s/^/ /"; } indent() { sed "s/^/ /"; }
echo "-----> Booting EC2 instance..." echo "-----> Booting EC2 instance..."
+2 -1
View File
@@ -1,4 +1,5 @@
#!/bin/bash #!/usr/bin/env bash
set -eo pipefail
SELF=`which $0` SELF=`which $0`
VAGRANT_SSH_PORT=${VAGRANT_SSH_PORT:-"2222"} VAGRANT_SSH_PORT=${VAGRANT_SSH_PORT:-"2222"}
PUBLIC_KEY=${PUBLIC_KEY:-"$HOME/.ssh/id_rsa.pub"} PUBLIC_KEY=${PUBLIC_KEY:-"$HOME/.ssh/id_rsa.pub"}
+2 -1
View File
@@ -1,4 +1,5 @@
#!/bin/bash #!/usr/bin/env bash
set -eo pipefail
sed --in-place "s|access_key|access_key = $AWS_ACCESS_KEY|" .s3cfg sed --in-place "s|access_key|access_key = $AWS_ACCESS_KEY|" .s3cfg
sed --in-place "s|secret_key|secret_key = $AWS_SECRET_KEY|" .s3cfg sed --in-place "s|secret_key|secret_key = $AWS_SECRET_KEY|" .s3cfg
s3cmd -c .s3cfg get s3://progrium-private/ec2_cert.pem /tmp/cert s3cmd -c .s3cfg get s3://progrium-private/ec2_cert.pem /tmp/cert
+2 -2
View File
@@ -1,5 +1,5 @@
#!/bin/bash #!/usr/bin/env bash
set -e set -eo pipefail
SELF=`which $0`; APP="$1"; TARGET="$2"; FORWARDED_PORT="$3" SELF=`which $0`; APP="$1"; TARGET="$2"; FORWARDED_PORT="$3"
TMP=$(mktemp -d -t "$TARGET.XXXXX") TMP=$(mktemp -d -t "$TARGET.XXXXX")
trap "rm -rf $TMP" EXIT trap "rm -rf $TMP" EXIT