Skip to content

Commit

Permalink
Fix up docker-compose file (linkedin#701)
Browse files Browse the repository at this point in the history
Setting the domain and password enables the web server to
connect to mysql.

Steps to reproduce/test fix:

```
docker compose up
```

Errors seen:

```
iris-web_1    | DB not up yet. Waiting a few seconds..
iris-web_1    | Waited too long for DB to come up. Bailing.

Enter password: ERROR 1045 (28000): Access denied for user 'root'@'172.18.0.3' (using password: YES)
```

Following this I needed to run these bootstrapping commands:

```
docker exec -it $(docker ps -f name=iris_iris-web_1 -q) bash

mysql -u root --host mysql -p < ./db/schema_0.sql
mysql -u root --host mysql -p -o iris < ./db/dummy_data.sql
```
  • Loading branch information
bilbof authored Apr 11, 2022
1 parent 500822a commit 94b9897
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,13 @@ services:
- "16649:16649"
environment:
- DOCKER_DB_BOOTSTRAP=1
- IRIS_CFG_DB_HOST=mysql
- IRIS_CFG_DB_PASSWORD=1234
volumes:
- ./configs/config.dev.yaml:/home/iris/config/config.yaml

iris-mysql:
image: mysql:5.5
hostname: mysql
environment:
- MYSQL_ROOT_PASSWORD=1234
- MYSQL_ROOT_PASSWORD=1234

0 comments on commit 94b9897

Please sign in to comment.