dm3-org / dm3

The dm3 protocol | New standard of web3 messaging | Decentralized ENS-based registry | Secure end-to-end encryption | Easy dApp integration
https://dm3.network
BSD 2-Clause "Simplified" License
73 stars 15 forks source link

What is the format of the config.yml file that is needed for the delivery service #1051

Open enghibrahem opened 1 month ago

enghibrahem commented 1 month ago

Hi, I am trying to run the delivery service node on my machine but could not figure out the format for the needed config.yml file. Steps I did to run the delivery service: 1) created an .env file that contains the required variables:

SIGNING_PUBLIC_KEY: ${SIGNING_PUBLIC_KEY}
SIGNING_PRIVATE_KEY: ${SIGNING_PRIVATE_KEY}
ENCRYPTION_PUBLIC_KEY: ${ENCRYPTION_PUBLIC_KEY}
ENCRYPTION_PRIVATE_KEY: ${ENCRYPTION_PRIVATE_KEY}
RPC: ${RPC}

2) in main branch I run docker-compose.yml that exists in the folder https://github.com/dm3-org/dm3/tree/develop/docker/ds-minimal by running the command docker compose up and the result was 2 running container: redis and delivery service.

image

However, the delivery service is always restarting, because it needs the config.yml file:

3) I tried to create config.yml file as follow:

image_2024-06-26_11-03-03

But I faced new error in delivery service container which tell me that config.yml file is not valid:

Node.js v22.2.0
2024-06-26 11:03:06 error Command failed with exit code 1.
2024-06-26 11:04:06 warning package.json: No license field
2024-06-26 11:04:08 Wed, 26 Jun 2024 08:04:08 GMT body-parser deprecated undefined extended: provide extended option at dist/index.js:65:27
2024-06-26 11:04:08 /app/dist/config/getDeliveryServiceProperties.js:39
2024-06-26 11:04:08         throw Error('Invalid config.yml');
2024-06-26 11:04:08               ^
2024-06-26 11:04:08 
2024-06-26 11:04:08 Error: Invalid config.yml
2024-06-26 11:04:08     at getDeliveryServiceProperties (/app/dist/config/getDeliveryServiceProperties.js:39:15)
2024-06-26 11:04:08     at /app/dist/index.js:79:109
2024-06-26 11:04:08     at step (/app/dist/index.js:33:23)
2024-06-26 11:04:08     at Object.next (/app/dist/index.js:14:53)
2024-06-26 11:04:08     at /app/dist/index.js:8:71
2024-06-26 11:04:08     at new Promise (<anonymous>)
2024-06-26 11:04:08     at __awaiter (/app/dist/index.js:4:12)
2024-06-26 11:04:08     at /app/dist/index.js:74:23
2024-06-26 11:04:08     at Object.<anonymous> (/app/dist/index.js:118:7)
2024-06-26 11:04:08     at Module._compile (node:internal/modules/cjs/loader:1434:14)
2024-06-26 11:04:08 
2024-06-26 11:04:08 Node.js v22.2.0
2024-06-26 11:04:08 error Command failed with exit code 1.

image

So, could you, please, provide the format of a valid config.yml that we can use.

Thanks in advance,