diff --git a/.env.example b/.env.example new file mode 100644 index 00000000..71efc645 --- /dev/null +++ b/.env.example @@ -0,0 +1,2 @@ +RECAPTCHA_SITE_KEY= +RECAPTCHA_SECRET_KEY= diff --git a/.gitignore b/.gitignore index a8edd793..d1f1658a 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ .emergence .php_cs.cache +.env diff --git a/script/studio b/script/studio index ed36f8bc..33736156 100755 --- a/script/studio +++ b/script/studio @@ -22,6 +22,14 @@ if [ -n "${1}" ]; then fi +# initialize .env +if [ ! -f .env ]; then + echo + echo "==> studio: initializing .env" + cp .env.example .env +fi + + echo echo "==> studio: configuring Chef Habitat studio Docker options…" STUDIO_NAME="${STUDIO_NAME:-laddr-studio}" @@ -33,6 +41,7 @@ export HAB_DOCKER_OPTS=" -v $(cd ~/.ssh; pwd)/known_hosts:/root/.ssh/known_hosts:ro --env STUDIO_DEVELOPER_UID=$(id -u) --env STUDIO_DEVELOPER_GID=$(id -g) + --env-file .env " echo "${HAB_DOCKER_OPTS}"