Skip to content

Commit

Permalink
Revise docker scripts to use optional dockfiles
Browse files Browse the repository at this point in the history
  • Loading branch information
macanudo527 committed Nov 7, 2024
1 parent 4e1cc2f commit ba3fe27
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
6 changes: 5 additions & 1 deletion docker/build
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,9 @@ set -e
# This script builds the Docker container, seeds the app with sample data, and logs the screen output.

DATE=`date +%Y%m%d-%H%M%S-%3N`
docker/build-log 2>&1 | tee log/build-$DATE.log
if [ -n "$1" ]; then
docker/build-log $1 2>&1 | tee log/build-$DATE.log
else
docker/build-log 2>&1 | tee log/build-$DATE.log
fi
docker/seed 2>&1 | tee log/seed-$DATE.log
7 changes: 6 additions & 1 deletion docker/build-log
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,12 @@ wait
echo '###########################'
echo 'BEGIN: docker compose build'
echo '###########################'
docker compose build # Set up the Docker containers
if [ -n "$1" ]; then
docker compose build $1 . # Set up the Docker containers
else
docker compose build # Set up the Docker containers
fi
docker compose build $1 # Set up the Docker containers
echo '##############################'
echo 'FINISHED: docker compose build'
echo '##############################'

0 comments on commit ba3fe27

Please sign in to comment.