Skip to content

Commit

Permalink
add Parameter Store as an alternative to AppConfig
Browse files Browse the repository at this point in the history
  • Loading branch information
briskt committed Feb 19, 2025
1 parent 3828e81 commit 73cd82f
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ COPY application/ /data/
RUN chown -R www-data:www-data \
console/runtime/

ADD https://github.com/silinternational/config-shim/releases/latest/download/config-shim.gz config-shim.gz
ADD https://github.com/silinternational/config-shim/releases/download/v1.2.0/config-shim.gz config-shim.gz
RUN gzip -d config-shim.gz && chmod 755 config-shim && mv config-shim /usr/local/bin

CMD ["/data/run.sh"]
8 changes: 5 additions & 3 deletions application/run.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
#!/usr/bin/env bash

if [[ -z "${APP_ID}" ]]; then
/data/yii batch/full
else
if [[ $PARAMETER_STORE_PATH ]]; then
config-shim --path $PARAMETER_STORE_PATH /data/yii batch/full
elif [[ $APP_ID ]]; then
config-shim --app $APP_ID --config $CONFIG_ID --env $ENV_ID /data/yii batch/full
else
/data/yii batch/full
fi

0 comments on commit 73cd82f

Please sign in to comment.