1
0
stack-orchestrator/app/data/stacks/uniswap-v3
David Boreham ec6b5439f4
Support for git hosts other than github (#407)
* Update repository list file

* Add host part to repo name

* Allow git hosts other than github
2023-05-24 17:19:21 -06:00
..
README.md Refactor for shiv package 2023-01-07 21:02:14 -07:00
stack.yml Support for git hosts other than github (#407) 2023-05-24 17:19:21 -06:00

Uniswap v3

Instructions to deploy Uniswap v3 watcher stack (watcher + uniswap-v3-info frontend app) using laconic-stack-orchestrator

Prerequisites

  • Access to uniswap-watcher-ts.

  • This deployment expects core services to be running; specifically, it requires ipld-eth-server RPC and GQL endpoints. Update the upstream.ethServer endpoints in the watcher config files accordingly:

    [upstream]
      [upstream.ethServer]
        gqlApiEndpoint = "http://ipld-eth-server.example.com:8083/graphql"
        rpcProviderEndpoint = "http://ipld-eth-server.example.com:8082"
    
  • uni-watcher and uni-info-watcher database dumps (optional).

Setup

  • Clone / pull required repositories:

    $ laconic-so setup-repositories --include vulcanize/uniswap-watcher-ts,vulcanize/uniswap-v3-info --git-ssh --pull
    
  • Build watcher and info app container images:

    $ laconic-so build-containers --include cerc/watcher-uniswap-v3,cerc/uniswap-v3-info
    

    This should create the required docker images in the local image registry.

Deploy

  • (Optional) Initialize the watcher database with existing database dumps if available:

    • Start the watcher database to be initialized:

      $ laconic-so deploy-system --include watcher-uniswap-v3 up uniswap-watcher-db
      
    • Find the watcher database container's id using docker ps and export it for further usage:

      $ export CONTAINER_ID=<CONTAINER_ID>
      
    • Load watcher database dumps:

      # uni-watcher database
      $ docker exec -i $CONTAINER_ID psql -U vdbm uni-watcher < UNI_WATCHER_DB_DUMP_FILE_PATH.sql
      
      # uni-info-watcher database
      $ docker exec -i $CONTAINER_ID psql -U vdbm uni-info-watcher < UNI_INFO_WATCHER_DB_DUMP_FILE_PATH.sql
      
  • Start all the watcher and info app services:

    $ laconic-so deploy-system --include watcher-uniswap-v3 up
    
  • Check that all the services are up and healthy:

    $ docker ps
    
    • The uni-info-watcher GraphQL Playground can be accessed at http://localhost:3004/graphql
    • The frontend app can be accessed at http://localhost:3006

Clean up

  • To stop all the services running in background:

    $ laconic-so deploy-system --include watcher-uniswap-v3 down