diff --git a/Makefile b/Makefile index a29f02c2a..add62273e 100644 --- a/Makefile +++ b/Makefile @@ -19,7 +19,7 @@ endif all: # Type "make install" to install. -install: dependencies stack copyfiles plugins version +install: dependencies stack copyfiles plugin-dependencies plugins version copyfiles: addman cp dokku /usr/local/bin/dokku @@ -34,6 +34,9 @@ addman: version: git describe --tags > ${DOKKU_ROOT}/VERSION 2> /dev/null || echo '~${DOKKU_VERSION} ($(shell date -uIminutes))' > ${DOKKU_ROOT}/VERSION +plugin-dependencies: pluginhook + dokku plugins-install-dependencies + plugins: pluginhook docker dokku plugins-install diff --git a/dokku b/dokku index d933b112e..c27cf7f34 100755 --- a/dokku +++ b/dokku @@ -108,6 +108,10 @@ case "$1" in pluginhook install ;; + plugins-install-dependencies) + pluginhook dependencies + ;; + # temporary hack for https://github.com/progrium/dokku/issues/82 deploy:all) for app in $(ls -d $DOKKU_ROOT/*/); do diff --git a/plugins/nginx-vhosts/dependencies b/plugins/nginx-vhosts/dependencies new file mode 100755 index 000000000..8166474a1 --- /dev/null +++ b/plugins/nginx-vhosts/dependencies @@ -0,0 +1,7 @@ +#!/bin/bash + +# latest stable NGINX 1.4.x with websocket support +apt-get install -qq -y software-properties-common python-software-properties +add-apt-repository -y ppa:nginx/stable +apt-get update +apt-get install -qq -y nginx dnsutils diff --git a/plugins/nginx-vhosts/install b/plugins/nginx-vhosts/install index 52d35e1f8..ae5fa5079 100755 --- a/plugins/nginx-vhosts/install +++ b/plugins/nginx-vhosts/install @@ -1,12 +1,6 @@ #!/usr/bin/env bash set -eo pipefail; [[ $DOKKU_TRACE ]] && set -x -# latest stable NGINX 1.4.x with websocket support -apt-get install -qq -y software-properties-common python-software-properties -add-apt-repository -y ppa:nginx/stable -apt-get update -apt-get install -qq -y nginx dnsutils - if ! grep -q dokku-nginx-reload "/etc/sudoers"; then touch /etc/sudoers.tmp cp /etc/sudoers /tmp/sudoers.new