docker notes
parent
be36ec6b7e
commit
3d247e903d
|
@ -0,0 +1,40 @@
|
||||||
|
##############################################################################################
|
||||||
|
Docker commands:
|
||||||
|
*****************
|
||||||
|
|
||||||
|
Create image:
|
||||||
|
--from solution folder:
|
||||||
|
docker image build -t "reverse-proxy-frontend:1.0.1" .
|
||||||
|
|
||||||
|
Run image:
|
||||||
|
docker run -p 5055:80 -it reverse-proxy-frontend:1.0.1
|
||||||
|
|
||||||
|
Push image to registry:
|
||||||
|
--tag image
|
||||||
|
docker tag reverse-proxy-frontend:1.0.1 alpine-nexus:8500/reverse-proxy/reverse-proxy-frontend:1.0.1
|
||||||
|
|
||||||
|
--login to registry
|
||||||
|
docker login --username=admin --password="***REMOVED***" alpine-nexus:8500
|
||||||
|
|
||||||
|
--push image
|
||||||
|
docker push alpine-nexus:8500/reverse-proxy/reverse-proxy-frontend:1.0.1
|
||||||
|
|
||||||
|
Pull image from registry
|
||||||
|
--login to registry
|
||||||
|
|
||||||
|
--pull image
|
||||||
|
docker pull alpine-nexus:8500/reverse-proxy/reverse-proxy-frontend:1.0.1
|
||||||
|
|
||||||
|
Stop old container
|
||||||
|
docker stop reverse-proxy-frontend
|
||||||
|
docker rm reverse-proxy-frontend
|
||||||
|
|
||||||
|
Run container in prod env
|
||||||
|
docker run -d --name reverse-proxy-frontend --restart=always -p 5005:80 alpine-nexus:8500/reverse-proxy/reverse-proxy-frontend:1.0.1
|
||||||
|
|
||||||
|
Remove old image
|
||||||
|
docker rmi alpine-nexus:8500/reverse-proxy/reverse-proxy-frontend:1.0.0
|
||||||
|
|
||||||
|
Get container logs
|
||||||
|
docker logs reverse-proxy-frontend
|
||||||
|
##############################################################################################
|
|
@ -8,39 +8,7 @@ import { useTranslation } from 'react-i18next';
|
||||||
function MyComponent() {
|
function MyComponent() {
|
||||||
const { t, i18n } = useTranslation();
|
const { t, i18n } = useTranslation();
|
||||||
|
|
||||||
##############################################################################################
|
|
||||||
Docker commands:
|
|
||||||
*****************
|
|
||||||
|
|
||||||
Create image:
|
|
||||||
--from solution folder:
|
|
||||||
docker image build -t "reverse-proxy-frontend:1.0.0" .
|
|
||||||
|
|
||||||
Run image:
|
|
||||||
docker run -p 5055:80 -it reverse-proxy-frontend:1.0.0
|
|
||||||
|
|
||||||
Push image to registry:
|
|
||||||
--tag image
|
|
||||||
docker tag reverse-proxy-frontend:1.0.0 alpine-nexus:8500/reverse-proxy/reverse-proxy-frontend:1.0.0
|
|
||||||
|
|
||||||
--login to registry
|
|
||||||
docker login --username=admin --password="***REMOVED***" alpine-nexus:8500
|
|
||||||
|
|
||||||
--push image
|
|
||||||
docker push alpine-nexus:8500/reverse-proxy/reverse-proxy-frontend:1.0.0
|
|
||||||
|
|
||||||
Pull image from registry
|
|
||||||
--login to registry
|
|
||||||
|
|
||||||
--pull image
|
|
||||||
docker pull alpine-nexus:8500/reverse-proxy/reverse-proxy-frontend:1.0.0
|
|
||||||
|
|
||||||
Run container in prod env
|
|
||||||
docker run -d --name reverse-proxy-frontend --restart=always -p 5005:80 alpine-nexus:8500/reverse-proxy/reverse-proxy-frontend:1.0.0
|
|
||||||
|
|
||||||
Rename container
|
|
||||||
docker rename <container_id> reverse-proxy-frontend
|
|
||||||
##############################################################################################
|
|
||||||
|
|
||||||
import { makeStyles, useTheme } from "@material-ui/core/styles";
|
import { makeStyles, useTheme } from "@material-ui/core/styles";
|
||||||
const theme = useTheme();
|
const theme = useTheme();
|
||||||
|
|
Loading…
Reference in New Issue