Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root


1 badge earned


Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!


Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.


Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!


Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
Community Members
Community Events
Community Groups

Do Docker start-up scripts run in a containerized pipeline?

If a container starts up with CMD or ENTRYPOINT, will that CMD or ENTRYPOINT run in the background or another shell while the pipeline script is running?

More specifically:

I have a Dockerfile that ends like this:


I want to use the container built from this Dockerfile as an environment to run my pipeline script in.

Will my CMD run in the background or another shell as my pipeline is running?

I don't want it to -- I just want to run the pipeline script.

But I need to know if I need to update the CMD script so that it won't run when the pipeline starts.

What I've Tried

I've looked for details in the official documentation on the subject and listed processes as a step in the pipeline.


1 answer

1 accepted

0 votes
Answer accepted
Patrik S
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
Apr 06, 2023

Hello @joe ,

Welcome to Atlassian Community!

When a build is triggered in pipelines, it will start the build container to run your script commands. The docker run command that is executed under the hood in pipelines to start the container utilizes the --entrypoint flag to override any CMD or ENTRYPOINT you have defined in the image itself.

This means that pipelines will ignore any entry point/cmd you have defined in the image itself, and will always overwrite it with /bin/bash which is the shell session where the commands you have included in the script part of your YML file will be executed.

Hope that helps to clarify your questions :)

Thank you, @joe !
Patrik S

Thanks @Patrik S . Can you post a link in the official documentation that indicates this?

Suggest an answer

Log in or Sign up to answer
Site Admin
AUG Leaders

Atlassian Community Events