diff --git a/.envrc_sample b/.envrc_sample index 9212e8b..8b2c3ee 100644 --- a/.envrc_sample +++ b/.envrc_sample @@ -3,8 +3,8 @@ export TYPEORM_CONNECTION=postgres export TYPEORM_HOST=localhost export TYPEORM_USERNAME=terra -export TYPEORM_PASSWORD=terra -export TYPEORM_DATABASE=terra_fcd +export TYPEORM_PASSWORD=abc123 +export TYPEORM_DATABASE=fcd export TYPEORM_PORT=5432 export TYPEORM_SYNCHRONIZE=false export TYPEORM_LOGGING=false @@ -12,9 +12,9 @@ export TYPEORM_ENTITIES=src/orm/*Entity.ts export TYPEORM_MIGRATIONS=src/orm/migration/*.ts export SERVER_PORT=3060 -export CHAIN_ID=tequila-0004 -export LCD_URI=https://tequila-lcd.terra.dev -export FCD_URI=https://tequila-fcd.terra.dev -export RPC_URI= +export CHAIN_ID=localterra +export LCD_URI=http://localhost:1317 +export FCD_URI=http://localhost:3060 +export RPC_URI=http://localhost:26657 export SENTRY_DSN= #export USE_LOG_FILE=true \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..dbe686d --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,89 @@ +version: "3.8" + +x-fcd-env: &fcd-env + - CHAIN_ID=localterra + - LCD_URI=http://terrad:1317 + - RPC_URI=http://terrad:26657 + - USE_LOG_FILE=true + - TYPEORM_CONNECTION=postgres + - TYPEORM_HOST=postgres + - TYPEORM_USERNAME=terra + - TYPEORM_PASSWORD=abc123 + - TYPEORM_DATABASE=fcd + - TYPEORM_SYNCHRONIZE=true + - TYPEORM_LOGGING=false + - TYPEORM_ENTITIES=src/orm/*Entity.ts + - LEGACY_NETWORK=false + +services: + fcd-collector: + build: + context: . + dockerfile: Dockerfile + args: + TERRA_VERSION: ${TERRA_VERSION} + image: ghcr.io/terra-money/fcd:${TERRA_VERSION} + container_name: localterra-fcd-collector + hostname: fcd-collector + command: collector + restart: unless-stopped + environment: *fcd-env + volumes: + - ./logs:/app/logs + networks: + - localterra + + fcd-api: + build: + context: . + dockerfile: Dockerfile + args: + TERRA_VERSION: ${TERRA_VERSION} + image: ghcr.io/terra-money/fcd:${TERRA_VERSION} + container_name: localterra-fcd-api + hostname: fcd-api + command: start + environment: *fcd-env + volumes: + - ./logs:/app/logs + networks: + - localterra + ports: + - 3060:3060 + + terrad: + image: ghcr.io/terra-money/localterra:${TERRA_VERSION} + container_name: localterra-terrad + hostname: terrad + pull_policy: always + volumes: + - localterra:/app + networks: + - localterra + ports: + - "1317:1317" + - "9090:9090" + - "9091:9091" + - "26657:26657" + + postgres: + image: postgres:14-alpine + container_name: localterra-postgres + hostname: postgres + environment: + POSTGRES_USER: terra + POSTGRES_PASSWORD: abc123 + volumes: + - ./initdb.d:/docker-entrypoint-initdb.d + - pgdata:/var/lib/postgresql/data + networks: + - localterra + ports: + - 5433:5432 + +volumes: + localterra: + pgdata: + +networks: + localterra: diff --git a/package.json b/package.json index afcee55..79eba7f 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "fcd", - "version": "2.0.6", + "version": "2.3.1", "description": "Terra FCD Suite", "main": "index.js", "author": "Terra Engineering ",