some documentation about docker and docker-compose usage (#3082)
This commit is contained in:
parent
d86c781b09
commit
2f57c04f02
|
|
@ -2,6 +2,7 @@ version: '3'
|
|||
services:
|
||||
grafana:
|
||||
image: grafana/grafana:7.0.4
|
||||
hostname: grafana
|
||||
depends_on:
|
||||
- graphite
|
||||
links:
|
||||
|
|
@ -20,6 +21,7 @@ services:
|
|||
restart: always
|
||||
graphite:
|
||||
image: sitespeedio/graphite:1.1.5-12
|
||||
hostname: graphite
|
||||
ports:
|
||||
- "2003:2003"
|
||||
- "8080:80"
|
||||
|
|
|
|||
|
|
@ -128,8 +128,17 @@ docker run --shm-size 2g --rm -v "$(pwd)":/sitespeed.io --network=host sitespeed
|
|||
```
|
||||
|
||||
## Access host in your local network
|
||||
|
||||
Sometimes the server you wanna test is in your local network at work and Docker cannot reach it (but you can from your physical machine). Usually you can fix that by making sure Docker uses the same network as your machine. Add `--network=host` and it should work.
|
||||
|
||||
### Docker compose
|
||||
|
||||
If you are using docker-compose for setting up Graphite and Grafana, your network name is normally named after the folder that you are running docker-compose from with an additional `_default` in the name, so if your folder name is sitespeedio, your network name would be `sitespeedio_default`.
|
||||
|
||||
```bash
|
||||
docker run --shm-size 2g --rm -v "$(pwd)":/sitespeed.io --network sitespeedio_default sitespeedio/sitespeed.io:{% include version/sitespeed.io.txt %} -b firefox http://localhost:4000/
|
||||
```
|
||||
|
||||
|
||||
## Extra start script
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue