1
0
Fork 0

build.sh: give the container a name EnglishPal.

Lanhui-add-articles
Hui Lan 2021-07-16 19:04:43 +08:00
parent 543458430e
commit c1062eef31
1 changed files with 17 additions and 0 deletions

17
build.sh Executable file
View File

@ -0,0 +1,17 @@
#!/bin/sh
cd /home/lanhui/englishpal
# Stop service
sudo docker stop EnglishPal
# Rebuild container. Run this after modifying the source code.
sudo docker build -t englishpal .
# Run the application
sudo docker run -d --name EnglishPal -p 90:80 -v /home/lanhui/englishpal/app/static/frequency:/app/static/frequency -t englishpal # for permanently saving data
# Save space. Run it after sudo docker run
sudo docker system prune -a -f