Clarifying working_directory

Hi,

So I’ve been reading the docs and googling around but can’t seem to find anything clarifying this. The docs say working_directory is not required and will default to ~/project. Does this path refer to the a path that resolves to /home/my_docker_container/project? And so all my steps will run in there e.g., checkout will pull my code from my github repo and store it in /home/my_docker_container/project etc.?

Thanks!

I think it is /home/circleci, but if you want to find out, add a step in your config that does a pwd (print working directory). That will let you know what it defaults to.

1 Like

Thanks! but to clarify, this directory is inside the docker container and not my machine, right?

Yes, the build server runs inside Docker, assuming:

  • you are using the Docker executor
  • you are using the hosted version of CircleCI
  • you are not using the circleci console command (I am not familiar with this)
1 Like

Thank you!