Skip to content

Instantly share code, notes, and snippets.

@jasdeepkhalsa
Last active March 31, 2020 14:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jasdeepkhalsa/52ae0f53668ea3666590a4f75af0ac30 to your computer and use it in GitHub Desktop.
Save jasdeepkhalsa/52ae0f53668ea3666590a4f75af0ac30 to your computer and use it in GitHub Desktop.
Build and run a Docker image

Build Image

cd into the project root and then...

docker build --tag "app:latest" --file "app.dockerfile" .

Run Image

The --ipc=host command is particularly important if running Cypress in Docker. The --shm-size="1g" command is to enable higher shared memory usage in CI environments

docker run -i -t --ipc=host --shm-size="1g" "app:latest"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment