mirror of
https://github.com/RustyRaptor/deploy-sourcegraph-docker.git
synced 2026-12-04 00:05:19 -07:00
* Add pure-docker migrator support * Update pure-docker to latest release
31 lines
893 B
Bash
Executable File
31 lines
893 B
Bash
Executable File
#!/usr/bin/env bash
|
|
set -e
|
|
source ./replicas.sh
|
|
|
|
# Description: Publishes Prometheus metrics about Docker containers.
|
|
#
|
|
# Disk: none
|
|
# Network: 100mbps
|
|
# Liveness probe: none
|
|
# Ports exposed to other Sourcegraph services: 8080/TCP
|
|
# Ports exposed to the public internet: none
|
|
#
|
|
# Also add the following volume mount for container monitoring on MacOS:
|
|
# --volume='/var/run/docker.sock:/var/run/docker.sock:ro'
|
|
#
|
|
sudo docker run --detach \
|
|
--name=cadvisor \
|
|
--network=sourcegraph \
|
|
--restart=always \
|
|
--cpus=1 \
|
|
--memory=1g \
|
|
--volume=/:/rootfs:ro \
|
|
--volume=/var/run:/var/run:ro \
|
|
--volume=/sys:/sys:ro \
|
|
--volume=/var/lib/docker/:/var/lib/docker:ro \
|
|
--volume=/dev/disk/:/dev/disk:ro \
|
|
index.docker.io/sourcegraph/cadvisor:3.36.3@sha256:249c573262967979889a186344ba5cc4e8e9186ec4f26c759ce9f8527560da69 \
|
|
--port=8080
|
|
|
|
echo "Deployed cadvisor"
|