1
2
3
4
5
6
7
8
9
10
11
12
| #!/bin/bash
| DATE=`date +%Y%m%d%H%M`
| NAME=hxsl-api
| cd ../yami-shop-api && docker build -t hxsl/${NAME}:$DATE .
| #docker部署方式
| #docker push visit/${NAME}:$DATE
| docker stop ${NAME}
| docker rm ${NAME}
| docker run -it -m 4000MB --dns 8.8.8.8 --dns 8.8.4.4 --name=${NAME} -v /root/logs:/application/logs -p 10082:8086 -p 587:587 -p 465:465 -d --restart=always hxsl/${NAME}:$DATE
|
| #k8s部署方式
| #kubectl set image deployment/${NAME} ${NAME}=youzan.com/vote-saas/${NAME}:$DATE -n vote-serversss
|
|