Skip to content

Commit

Permalink
added info on docker compose + fixed bugs in examples (#966)
Browse files Browse the repository at this point in the history
  • Loading branch information
masapr authored Sep 1, 2022
1 parent b52be1d commit cc49785
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions docker/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,22 +2,22 @@

## Prerequisite

* Make sure you have installed Docker with `docker-compose` (version > `1.25.0`). On Windows, this can be Docker Desktop with WSL 2 integration.
* Make sure you have installed Docker (version > `1.25.0`) with [Docker Compose](https://docs.docker.com/compose/install/). On Windows, this can be Docker Desktop with WSL 2 integration.
* In case you also build the worker directly, without docker (e.g. on a dev machine, running `make`), you should run `make clean` before running the docker build. Otherwise, it can occasionally lead to build errors.
* The node image version that is loaded in the `docker-compose.yml`, (e.g. `image: "integritee/integritee-node-dev:1.0.11"`) needs to be compatible with the worker you're trying to build.

## Building the Docker containers

Run
```
COMPOSE_DOCKER_CLI_BUILD=1 DOCKER_BUILDKIT=1 docker-compose build
COMPOSE_DOCKER_CLI_BUILD=1 DOCKER_BUILDKIT=1 docker compose build
```
in this folder to build the worker image. This will build the worker from source and tag it in an image called `integritee-worker:dev`.

## Running the docker setup

```
docker-compose up
docker compose up
```
Starts all services (node and workers), using the `integritee-worker:dev` images you've built in the previous step.

Expand All @@ -26,9 +26,9 @@ Starts all services (node and workers), using the `integritee-worker:dev` images
### Demo indirect invocation (M6)
Build
```
COMPOSE_DOCKER_CLI_BUILD=1 DOCKER_BUILDKIT=1 docker compose -f docker compose.yml -f demo-indirect-invocation.yml build --build-arg WORKER_MODE_ARG=offchain-worker
COMPOSE_DOCKER_CLI_BUILD=1 DOCKER_BUILDKIT=1 docker compose -f docker-compose.yml -f demo-indirect-invocation.yml build --build-arg WORKER_MODE_ARG=offchain-worker
```
Run
Run
```
docker compose -f docker-compose.yml -f demo-indirect-invocation.yml up demo-indirect-invocation --exit-code-from demo-indirect-invocation
```
Expand Down

0 comments on commit cc49785

Please sign in to comment.