-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathentrypoint.sh
More file actions
26 lines (18 loc) · 821 Bytes
/
entrypoint.sh
File metadata and controls
26 lines (18 loc) · 821 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
#!/bin/bash
cd ~
# # copy in the .env file - this file is manually created and placed in this EC2 instance
# echo "----- Copy .env file -----"
# cp .FinkelsteinLab.env ArsenyLabWorkflow/docker/standard_worker/.env
# build and start the container
cd ArsenyLabWorkflow/docker/standard_worker/dist/debian
echo "----- Build Docker image -----"
docker compose --env-file=../../.env -f docker-compose-standard_worker.yaml build --no-cache
echo "----- Start the Docker container -----"
docker compose --env-file=../../.env -f docker-compose-standard_worker.yaml up
echo "----- Processing finished -----"
sleep 20
echo "----- Cleanup Docker -----"
docker compose --env-file=../../.env -f docker-compose-standard_worker.yaml down
docker system prune -a -f --volumes
echo "----- Shutdown server -----"
sudo shutdown now