Complete the code to build a Docker image in a CI/CD pipeline.
docker build -t myapp:latest [1] .The -f Dockerfile option specifies the Dockerfile to use when building the image.
Complete the code to push the Docker image to a registry in the CI/CD pipeline.
docker [1] myapp:latestThe docker push command uploads the image to the Docker registry.
Fix the error in the command to run a container in detached mode in the CI/CD pipeline.
docker run [1] myapp:latestThe -d flag runs the container in detached mode, which is needed for background deployment.
Fill both blanks to tag and push the Docker image to a remote registry in the CI/CD pipeline.
docker tag myapp:latest [1] && docker [2] [1]
First, tag the image with the remote registry name, then push it using docker push.
Fill all three blanks to build, tag, and push a Docker image in a CI/CD pipeline.
docker build -t [1] . && docker tag [1] [2] && docker [3] [2]
Build the image with a local tag, tag it for the remote registry, then push it.