Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docker compose doesnt work #579

Open
2 of 8 tasks
dev-dantealighieri opened this issue Nov 14, 2024 · 4 comments
Open
2 of 8 tasks

docker compose doesnt work #579

dev-dantealighieri opened this issue Nov 14, 2024 · 4 comments

Comments

@dev-dantealighieri
Copy link

Summary

Summary

I have a docker-compose file to start cardano-rosette service, but when I start it, it doesn't work and have some errors in the logs.

docker-compose:

version: '3.8'
services:
  cardano-rosetta:
    image: inputoutput/cardano-rosetta:master
    container_name: cardano-rosetta
    ports:
      - "8080:8080"
    volumes:
      #  - /data/docker/volumes/f28ecac02f8a2bb2209734f534adb1294b8c2591429d2242cbedf1a293080e05/_data:/data
      - /data/ada:/data
    shm_size: 2g
    deploy:
      resources:
        limits:
          memory: 55g
    restart: always

logs:

5)\n    at async Object.getNetworkStatus (/cardano-rosetta-server/dist/src/server/services/network-service.js:45:29)\n    at async /cardano-rosetta-server/dist/src/server/controllers/network-controller.js:21:31\n    at async withNetworkValidation (/cardano-rosetta-server/dist/src/server/controllers/controllers-helper.js:20:12)","type":"Error","v":1}
cardano-rosetta  | {"level":30,"time":1731592833330,"pid":103,"hostname":"8468e77eb196","reqId":23,"res":{"statusCode":500},"responseTime":1.2754135131835938,"msg":"request completed","v":1}
cardano-rosetta  | [8468e77e:cardano.node.DnsSubscription:Warning:56] [2024-11-14 14:00:36.34 UTC] Domain: "relays-new.cardano-mainnet.iohk.io" Failed to start all required subscriptions
cardano-rosetta  | [8468e77e:cardano.node.DnsSubscription:Warning:56] [2024-11-14 14:00:46.34 UTC] Domain: "relays-new.cardano-mainnet.iohk.io" Failed to start all required subscriptions
cardano-rosetta  | [8468e77e:cardano.node.DnsSubscription:Warning:56] [2024-11-14 14:00:56.34 UTC] Domain: "relays-new.cardano-mainnet.iohk.io" Failed to start all required subscriptions
cardano-rosetta  | {"level":30,"time":1731592863324,"pid":103,"hostname":"8468e77eb196","reqId":24,"req":{"method":"POST","url":"/network/status","hostname":"ba50cd3.ada-rosetta.dev.nodes.int:8080","remoteAddress":"10.226.31.181","remotePort":59494},"msg":"incoming request","v":1}
cardano-rosetta  | {"level":30,"time":1731592863324,"pid":103,"hostname":"8468e77eb196","reqId":24,"msg":"[networkStatus] Looking for latest block","v":1}
cardano-rosetta  | {"level":30,"time":1731592863324,"pid":103,"hostname":"8468e77eb196","reqId":24,"msg":"[networkStatus] Looking for latest block","v":1}
cardano-rosetta  | {"level":30,"time":1731592863324,"pid":103,"hostname":"8468e77eb196","reqId":24,"msg":"[getLatestBlock] About to look for latest block","v":1}
cardano-rosetta  | {"level":50,"time":1731592863329,"pid":103,"hostname":"8468e77eb196","reqId":24,"msg":"[errorHandler] An error ocurred and will be sent as response","stack":"TypeError: Cannot read properties of undefined (reading 'blockHeight')\n    at Object.findLatestBlockNumber (/cardano-rosetta-server/dist/src/server/db/blockchain-repository.js:390:50)\n    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)\n    at async Object.getLatestBlock (/cardano-rosetta-server/dist/src/server/services/block-service.js:45:35)\n    at async Object.getNetworkStatus (/cardano-rosetta-server/dist/src/server/services/network-service.js:45:29)\n    at async /cardano-rosetta-server/dist/src/server/controllers/network-controller.js:21:31\n    at async withNetworkValidation (/cardano-rosetta-server/dist/src/server/controllers/controllers-helper.js:20:12)","type":"Error","v":1}
cardano-rosetta  | {"level":30,"time":1731592863329,"pid":103,"hostname":"8468e77eb196","reqId":24,"res":{"statusCode":500},"responseTime":5.098918914794922,"msg":"request completed","v":1}
cardano-rosetta  | [8468e77e:cardano.node.DnsSubscription:Warning:56] [2024-11-14 14:01:06.34 UTC] Domain: "relays-new.cardano-mainnet.iohk.io" Failed to start all required subscriptio

why its not working?

Steps to reproduce the bug

docker-compose up -d

Actual Result

.

Expected Result

rosetta service working properly

Environment

.

Platform

  • Linux (Ubuntu)
  • Linux (Other)
  • macOS
  • Windows

Platform version

Ubuntu 22.04.2 LTS

Docker version

24.0.7

Steps to reproduce the bug

.

Actual Result

.

Expected Result

.

Environment

.

Platform

  • Linux (Ubuntu)
  • Linux (Other)
  • macOS
  • Windows

Platform version

Ubuntu 22.04.2 LTS

Docker version

24.0.7

@Godspeed-exe
Copy link
Collaborator

Hello @dev-dantealighieri

In your logs I'm seeing relays-new.cardano-mainnet.iohk.io , this is the old relay network. This has been decommissioned a few weeks ago because all components have switched to using the P2P functionality on Cardano mainnet.

The recent Rosetta versions already include this new topology which enables the P2P functionality. Can you check

Keep me posted!

Kind regards!

@dev-dantealighieri
Copy link
Author

i already tried main, latest, and v2.1 versions within this docker-compose to start the rosetta service, but i still get this error.

how can i start the rosetta service with minimum configurations (i dont have a node)

if i cannot do this with docker-compose, is there any fast installation script to install rosetta service.

@linconvidal
Copy link
Member

@dev-dantealighieri The simplest approach is to build and run the application using Docker Compose, as outlined in the readme. It has all you need to run, including cardano-node and cardano-db-sync. You can use the tag v2.3.3. If you encounter any issues, feel free to share the logs after attempting the updated version.

@dev-dantealighieri
Copy link
Author

thanks, its working and syncing now!

i have one more question, how can i use a snapshot while doing an installation via docker-compose?

my current setup

version: '3.8'
services:
  cardano-rosetta:
    image: cardanofoundation/cardano-rosetta:2.3.3
    container_name: cardano-rosetta
    ports:
      - "8080:8080"
    volumes:
      #  - /data/docker/volumes/f28ecac02f8a2bb2209734f534adb1294b8c2591429d2242cbedf1a293080e05/_data:/data
      - /data/ada:/data
    shm_size: 2g
    deploy:
      resources:
        limits:
          memory: 55g
    restart: always

and i just did docker-compose up -d

thanks, dante

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants