Docker
Author
fabricegeib
Date Published

Install docker
1# Add Docker's official GPG key:2sudo apt update3sudo apt install ca-certificates curl4sudo install -m 0755 -d /etc/apt/keyrings5sudo curl -fsSL https://download.docker.com/linux/debian/gpg -o /etc/apt/keyrings/docker.asc6sudo chmod a+r /etc/apt/keyrings/docker.asc78# Add the repository to Apt sources:9sudo tee /etc/apt/sources.list.d/docker.sources <<EOF10Types: deb11URIs: https://download.docker.com/linux/debian12Suites: $(. /etc/os-release && echo "$VERSION_CODENAME")13Components: stable14Architectures: $(dpkg --print-architecture)15Signed-By: /etc/apt/keyrings/docker.asc16EOF1718sudo apt update
Set up Docker's apt repository
1sudo apt install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin23sudo systemctl status docker45sudo systemctl start docker67sudo docker run hello-world89sudo systemctl stop docker
Install the Docker packages and status
1# build with simple tag2docker build -t fabricegeib:1.0.0 .34# build with specific Dockerfile5docker build -f Dockerfile.prod -t fabricegeib:prod .67# build + tag8docker build -t ghcr.io/fabricegeib/fabricegeib:1.0.0 .910# rename or give another tag11docker tag fabricegeib:1.0.0 registry.fabricegeib.com/fabricegeib:1.0.01213# push to your registry14docker push registry.fabricegeib.com/fabricegeib:1.0.01516# start the image17docker run -p 3000:3000 fabricegeib/fabricegeib:1.0.0
create image and push to registry