Skip to content
Ruslan Konviser edited this page Sep 11, 2021 · 7 revisions

Images

We have Docker images published into:

More specifically:

To build such images on each release (push to our master branch), we are using relevant Github Action.

Using local images

Run docker-compose up -d --build to build the Docker images and run in detached mode(-d).

Using latest images from GitHub Releases

Run docker-compose -f docker-compose.demo.yaml up -d to use the latest image from GitHub. You may have to run docker-compose -f docker-compose.demo.yaml pull to update your images.

Build & Run Containers manually

To build a website (from the root of mono-repo):

docker build . -t gauzy-webapp -f .deploy/webapp/Dockerfile

To run website:

docker run -p 127.0.0.1:4200:4200/tcp --env API_BASE_URL=http://localhost:3000 --env API_HOST=10.0.0.1 gauzy-webapp

Note: replace API_HOST value with IP address or hostname of the API host and API_BASE_URL value with external URL for API, i.e. where API will be accessible for browser. Leave as above if you just want to run it locally for testing.

To build API (from the root of mono-repo):

docker build . -t gauzy-api -f .deploy/api/Dockerfile

To run API:

docker run -p 127.0.0.1:3000:3000/tcp gauzy-api

Check Docker Image

docker run --rm -it --entrypoint=sh name-of-image

For example:

docker run --rm -it --entrypoint=sh ghcr.io/ever-co/gauzy-api

To just run the same image without entrypoint:

docker run --rm -it ghcr.io/ever-co/gauzy-api

Configuration Notes

Currently, you need to setup a .env file containing all the necessary environment variables. You can use the existing .env.sample. Set up .env using cp .env.sample .env.