release.sh

master
Tudor Stanciu 2021-08-01 03:04:48 +03:00
parent ffe9daa30f
commit 31d9a5b61c
3 changed files with 31 additions and 3 deletions

View File

@ -25,11 +25,17 @@ Pull image from registry
--pull image
docker pull alpine-nexus:8500/cdn/cdn-admin-frontend:1.0.0
Stop old container
docker stop cdn-admin-frontend && docker rm cdn-admin-frontend
Run container in prod env
docker run -d --name cdn-admin-frontend --restart=always -p 5010:80 alpine-nexus:8500/cdn/cdn-admin-frontend:1.0.0
Rename container
docker rename <container_id> cdn-admin-frontend
Remove old image
docker rmi alpine-nexus:8500/cdn/cdn-admin-frontend:1.0.0
Get container logs
docker logs cdn-admin-frontend
#######################################################################################################################################################
Docker container last version: 1.0.0

22
release.sh Normal file
View File

@ -0,0 +1,22 @@
#!/bin/bash
echo "Welcome!"
version="1.0.1"
oldver="1.0.0"
echo "Pull docker image cdn-admin-frontend:$version from registry."
docker pull alpine-nexus:8500/cdn/cdn-admin-frontend:$version
echo "Stop old container."
docker stop cdn-admin-frontend && docker rm cdn-admin-frontend
echo "Run new container."
docker run -d --name cdn-admin-frontend --restart=always -p 5010:80 alpine-nexus:8500/cdn/cdn-admin-frontend:$version
echo "Remove old image cdn-admin-frontend:$oldver."
docker rmi alpine-nexus:8500/cdn/cdn-admin-frontend:$oldver
echo "Get container logs:"
docker logs cdn-admin-frontend
echo "DONE!"

View File

@ -34,7 +34,7 @@ function Login(props) {
var [activeTabId, setActiveTabId] = useState(0);
var [nameValue, setNameValue] = useState("");
var [loginValue, setLoginValue] = useState(***REMOVED***);
var [passwordValue, setPasswordValue] = useState("***REMOVED***");
var [passwordValue, setPasswordValue] = useState("");
return (
<Grid container className={classes.container}>