Created
December 1, 2020 07:24
-
-
Save saniyathossain/a0ab7100d11601b3df0047c098c4967e to your computer and use it in GitHub Desktop.
Init project docker-compose commands from shell file - Linux
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| USER="saniyathossain" | |
| DOCKER_COMMONS_DIR="/home/$USER/app/docker/www/commons/docker-commons" | |
| PROJECT_DIR="/home/$USER/app/docker/www/company/project/microservice" | |
| PROJECT_DOCKER_DIR="$PROJECT_DIR/docker" | |
| echo "USER: $USER" | |
| sleep 2 | |
| echo "DOCKER COMMONS DIRECTORY: $DOCKER_COMMONS_DIR" | |
| cd $DOCKER_COMMONS_DIR; | |
| docker-compose up -d --build; | |
| docker-compose ps -a; | |
| sleep 2 | |
| echo "PROJECT DIRECTORY: $PROJECT_DIR" | |
| cd $PROJECT_DOCKER_DIR; | |
| docker-compose up -d --build; | |
| docker-compose ps -a; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment