-
Notifications
You must be signed in to change notification settings - Fork 10
/
docker-compose-dev.yaml
executable file
·56 lines (55 loc) · 1.69 KB
/
docker-compose-dev.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
version: '3.9'
services:
snapshotter-lite:
image: powerloom-snapshotter-lite
expose:
- 8002
ports:
- 8002:8002
volumes:
- ./snapshotter:/snapshotter
- ./config:/config
- ./logs:/logs
environment:
- SIGNER_ACCOUNT_ADDRESS=$SIGNER_ACCOUNT_ADDRESS
- SIGNER_ACCOUNT_PRIVATE_KEY=$SIGNER_ACCOUNT_PRIVATE_KEY
- SLOT_ID=$SLOT_ID
- SOURCE_RPC_URL=$SOURCE_RPC_URL
- RELAYER_HOST=$RELAYER_HOST
- PROST_RPC_URL=$PROST_RPC_URL
- IPFS_URL=$IPFS_URL
- IPFS_API_KEY=$IPFS_API_KEY
- IPFS_API_SECRET=$IPFS_API_SECRET
- PROTOCOL_STATE_CONTRACT=$PROTOCOL_STATE_CONTRACT
- SLACK_REPORTING_URL=$SLACK_REPORTING_URL
- POWERLOOM_REPORTING_URL=$POWERLOOM_REPORTING_URL
- WEB3_STORAGE_TOKEN=$WEB3_STORAGE_TOKEN
- NAMESPACE=$NAMESPACE
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8002/health"]
interval: 10s
timeout: 5s
retries: 3
start_period: 30s
command:
bash -c "sh snapshotter_autofill.sh && sh init_docker.sh"
ipfs:
image: ipfs/kubo:release
profiles: ["ipfs"]
environment:
- IPFS_PROFILE=server
entrypoint: >
/bin/sh -c "
echo 'adding cronjob';
mkdir -p /var/spool/cron/crontabs;
croncmd=\"cd /data/ipfs && find . -type f -mtime +7 -name \\"*.data\\" | xargs rm -f 2>&1\";
cronjob=\"0 * * * * $$croncmd\";
( crontab -l | grep -v -F \"$$croncmd\" ; echo \"$$cronjob\" ) | crontab -;
echo 'starting ipfs';
/sbin/tini -- /usr/local/bin/start_ipfs daemon --migrate=true --agent-version-suffix=docker;
"
expose:
- 5001
ports:
- 5001:5001
restart: on-failure