Skip to content

Commit

Permalink
Merge pull request #333 from amazeeio/nginx-ep-only-non-empty
Browse files Browse the repository at this point in the history
only ep folders that are not empty
  • Loading branch information
Schnitzel authored Apr 12, 2018
2 parents c98853f + ff98264 commit 5d13aba
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions images/nginx/docker-entrypoint
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,11 @@ if [ ! "${BASIC_AUTH}" == "off" ]; then
fi

ep /etc/nginx/*
find /etc/nginx/conf.d/ -type d | while read DIR ;
do ep $DIR/*;
# find all folders within /etc/nginx/conf.d/
find /etc/nginx/conf.d/ -type d | while read DIR; do
# envplate if found folder is not empty
if find $DIR -mindepth 1 | read; then
ep $DIR/*;
fi
done
ep /etc/nginx/helpers/*

0 comments on commit 5d13aba

Please sign in to comment.