Links

Endpoints

Run your own endpoints

How to deploy Dandelion endpoints

How to deploy Graphql endpoint with docker-compose

Clone repo:
git clone \
--single-branch \
--branch 6.1.0 \
--recurse-submodules \
https://github.com/input-output-hk/cardano-graphql.git
&& cd cardano-graphql

Run Testnet

export NETWORK=testnet &&\
docker pull inputoutput/cardano-graphql:6.1.0-${NETWORK} &&\
docker pull inputoutput/cardano-graphql-hasura:6.1.0 &&\
docker pull cardanosolutions/cardano-node-ogmios:v4.2.1-${NETWORK} &&\
RESTORE_SNAPSHOT=https://updates-cardano-testnet.s3.amazonaws.com/cardano-db-sync/12/db-sync-snapshot-schema-12-block-3166999-x86_64.tgz \
API_PORT=3101 \
HASURA_PORT=8091 \
OGMIOS_PORT=1338 \
POSTGRES_PORT=5433 \
docker-compose -p ${NETWORK} up -d &&\
docker-compose -p ${NETWORK} logs -f
Check logs:
docker-compose -p ${NETWORK} logs -f
Open the playground on the browser:
Rebuild postgres:
cgql docker rebuild-service

Run Mainnet

export NETWORK=mainnet
# <testnet-port> + 1
export API_PORT=3102 &&\
export HASURA_PORT=8092 &&\
export OGMIOS_PORT=1339 &&\
export POSTGRES_PORT=5434
docker pull inputoutput/cardano-graphql:5.1.0-${NETWORK} &&\
docker pull inputoutput/cardano-graphql-hasura:5.1.0 &&\
docker pull cardanosolutions/cardano-node-ogmios:v4.0.0-beta.9-${NETWORK} &&\
docker-compose up -d &&\
docker-compose logs -f

Docker Utils:

docker ps
docker logs <ID>
docker stop $(docker ps -a -q)
docker rm $(docker ps -a -q)
docker restart <ID>
docker image prune
docker volume prune
docker container prune
docker network prune
docker system prune
Check process using ports:
sudo netstat -plten
sudo kill -9 <PID>
Last modified 2yr ago