31 lines
434 B
Markdown
31 lines
434 B
Markdown
# Docker
|
|
|
|
Dockerfile and compose files used as basis for service deployment.
|
|
|
|
## Build and push an image
|
|
|
|
Move to desired folder
|
|
```
|
|
$ cd [folder]
|
|
```
|
|
|
|
Build the image.
|
|
```
|
|
$ docker build -t [registryUrl]/[imageName]:[tag] .
|
|
```
|
|
|
|
Login into docker registry.
|
|
```
|
|
$ docker login [registryUrl]
|
|
```
|
|
|
|
Push the image.
|
|
```
|
|
$ docker push [registryUrl]/[imageName]:[tag]
|
|
```
|
|
|
|
Logout from docker registry.
|
|
```
|
|
$ docker logout [registryUrl]
|
|
```
|