Fix docker build documentation: dont need sudo.

This commit is contained in:
John Livingston 2022-10-10 15:37:10 +02:00
parent 8426218caf
commit e3970bd8c7
No known key found for this signature in database
GPG Key ID: B17B5640CE66CDBC

View File

@ -7,7 +7,7 @@ Clone the git repository.
Then: Then:
```shell ```shell
sudo docker build . -f docker/Dockerfile.bullseye docker build . -f docker/Dockerfile.bullseye
``` ```
## Publish docker image ## Publish docker image
@ -18,24 +18,24 @@ if you really need to build such an image.
First, you have to authenticate your Docker environment. First, you have to authenticate your Docker environment.
Create an access token on your hub.docker.com account, then use Create an access token on your hub.docker.com account, then use
`sudo docker login --username johnxlivingston` to add your credentials. `docker login --username johnxlivingston` to add your credentials.
```shell ```shell
# pull the current peertube production image: # pull the current peertube production image:
sudo docker pull chocobozzz/peertube:production-bullseye docker pull chocobozzz/peertube:production-bullseye
# build the docker image, if not done yet: # build the docker image, if not done yet:
sudo docker build . -f docker/Dockerfile.bullseye docker build . -f docker/Dockerfile.bullseye
# list images to find the image id: # list images to find the image id:
sudo docker images docker images
#REPOSITORY TAG IMAGE ID CREATED SIZE #REPOSITORY TAG IMAGE ID CREATED SIZE
#<none> <none> xx_image_id_xx 17 seconds ago 1.19GB #<none> <none> xx_image_id_xx 17 seconds ago 1.19GB
#chocobozzz/peertube production-bullseye xx_peertube_image_id_xx 4 days ago 1.17GB #chocobozzz/peertube production-bullseye xx_peertube_image_id_xx 4 days ago 1.17GB
# tag the image: # tag the image:
sudo docker tag xx_image_id_xx johnxlivingston/peertubelivechat:production-bullseye docker tag xx_image_id_xx johnxlivingston/peertubelivechat:production-bullseye
# push on the main tag name: # push on the main tag name:
sudo docker push johnxlivingston/peertubelivechat:production-bullseye docker push johnxlivingston/peertubelivechat:production-bullseye
# push on the current peertube tag name: # push on the current peertube tag name:
sudo docker tag johnxlivingston/peertubelivechat:production-bullseye johnxlivingston/peertubelivechat:v4.1.0-bullseye docker tag johnxlivingston/peertubelivechat:production-bullseye johnxlivingston/peertubelivechat:v4.1.0-bullseye
sudo docker push johnxlivingston/peertubelivechat:v4.1.0-bullseye docker push johnxlivingston/peertubelivechat:v4.1.0-bullseye
``` ```