Skip to content

Commit

Permalink
amend README
Browse files Browse the repository at this point in the history
  • Loading branch information
antondlr committed May 16, 2024
1 parent 5242b52 commit 9dbab59
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 17 deletions.
4 changes: 0 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,6 @@ build:
dev:
yarn && yarn start

# Runs a docker production webserver
docker:
docker build -t siren . && docker run --rm -it --name siren -p 80:80 siren

# Compile into a number of releases
release:
yarn && yarn build-all
Expand Down
28 changes: 15 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -56,35 +56,37 @@ $ yarn dev
#### Docker (Recommended)

Docker is the recommended way to run a webserver that hosts Siren and can be
connected to via a web browser. We recommend this method as it established a
production-grade web-server to host the application.
connected to via a web browser. For now, we only have a development docker image.

`docker` is required to be installed with the service running.

The docker image can be built and run via the Makefile by running:
Recommended config for using the development docker image (assuming the BN/VC API's are exposed on your localhost):

```
$ make docker
PORT=3000
BACKEND_URL=http://127.0.0.1:3001
VALIDATOR_URL=http://host.docker.internal:5062
BEACON_URL=http://host.docker.internal:5052
```

Alternatively, to run with Docker, the image needs to be built. From the repository directory
run:

The docker image can be built and run with the following commands:
```
$ docker build -t siren .
$ docker build -f Dockerfile.dev -t siren .
```

Then to run the image:

```
$ docker run --rm -ti --name siren -p 80:80 siren
$ docker run --rm -ti -p 3000:3000 -v $PWD/.env:/app/.env:ro siren
```
Linux users may want to add this flag:
`--add-host=host.docker.internal:host-gateway`


This will open port 3000 and allow your browser to connect.

This will open port 80 and allow your browser to connect. You can choose
another local port by modifying the command. For example `-p 8000:80` will open
port 8000.
To view Siren, simply go to `http://localhost:3000` in your web browser.

To view Siren, simply go to `http://localhost` in your web browser.

# Running a Local Testnet

Expand Down

0 comments on commit 9dbab59

Please sign in to comment.