-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-commands.txt
28 lines (22 loc) · 1.49 KB
/
docker-commands.txt
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
27
*******************************************************
To create docker in local env:
*******************************************************
git clone
docker images
docker build -t plan-my-day-app .
docker run --name plan-my-day-app -p 9205:80 -d plan-my-day-app
docker image tag plan-my-day-app pabloguerra/plan-my-day-app:1.0
docker images
docker login
docker push pabloguerra/plan-my-day-app:1.0
Deploy web in azure with docker image located in docker hub registry:
****************************************************************************
az webapp create --resource-group myResourceGroup --plan myAppServicePlan --name <app name> --deployment-container-image-name microsoft/azure-appservices-go-quickstart
web1, with public container:
az webapp create --resource-group bootcamp-webapps-group --plan myAppServicePlan --name pg-bootcamp-WebApp01 --deployment-container-image-name microsoft/azure-appservices-go-quickstart
web1, with private container. note (credentials were configured in azure portal> container settings):
az webapp create --resource-group bootcamp-webapps-group --plan myAppServicePlan --name pg-bootcamp-webapp02 --deployment-container-image-name pabloguerra/plan-my-day-app:1.0
https://pg-bootcamp-webapp02.scm.azurewebsites.net/api/logs/docker
Activar los logs de docker:
az webapp log config --name pg-bootcamp-webapp02 --resource-group bootcamp-webapps-group --docker-container-logging filesystem
az webapp log tail --name pg-bootcamp-webapp02 --resource-group bootcamp-webapps-group