Reputation: 1
I'm trying to set up a Chainlink node with Docker Compose, but I keep running into an issue. My Chainlink node container starts, but it keeps throwing the following error:
...
2024-11-09T15:59:49.588Z [INFO] Nurse service (automatic pprof profiling) is disabled chainlink/application.go:229 version=1.13.3@47c02ec
2024-11-09T15:59:49.588Z [INFO] DatabaseBackup: periodic database backups are disabled. To enable automatic backups, set DATABASE_BACKUP_MODE=lite or DATABASE_BACKUP_MODE=full chainlink/application.go:272 version=1.13.3@47c02ec
2024-11-09T15:59:49.590Z [WARN] P2P_LISTEN_PORT was not set, listening on random port 43519. A new random port will be generated on every boot, for stability it is recommended to set P2P_LISTEN_PORT to a fixed value in your environment config/p2p_v1_config.go:87 logger=GeneralConfig p2pPort=43519 version=1.13.3@47c02ec
error authenticating keystore: no password provided
Here is my setup:
I'm using Docker Compose to run Chainlink Node, Postgres, Grafana, and Prometheus.
pickycamel@chainlink-node:~/chainlink_node_project$ ls -al
total 36
drwxr-xr-x 3 pickycamel pickycamel 4096 Nov 9 15:59 .
drwxr-xr-x 13 pickycamel pickycamel 4096 Nov 9 15:17 ..
-rw-r--r-- 1 pickycamel docker 15 Nov 9 14:58 .chainlink_password
-rw-r--r-- 1 pickycamel docker 1024 Nov 9 15:07 .docker-compose.ymldocker-compose.swp
-rw-r--r-- 1 pickycamel docker 371 Nov 9 15:14 .env
-rw-r--r-- 1 pickycamel docker 1024 Nov 9 15:07 .up.swp
drwxr-xr-x 2 root root 4096 Nov 9 15:52 chainlink_password
-rw-r--r-- 1 pickycamel docker 1357 Nov 9 15:59 docker-compose.yml
-rw-r--r-- 1 pickycamel docker 135 Nov 9 15:11 prometheus.yml
Below is my docker-compose.yml
:
pickycamel@chainlink-node:~/chainlink_node_project$ cat docker-compose.yml
version: '3'
services:
chainlink:
image: smartcontract/chainlink:1.13.3
container_name: chainlink-node
restart: always
environment:
ETH_URL: ${ETH_URL}
ETH_CHAIN_ID: ${ETH_CHAIN_ID}
CHAINLINK_EMAIL: ${CHAINLINK_EMAIL}
CHAINLINK_PASSWORD: ${CHAINLINK_PASSWORD}
DATABASE_URL: postgresql://chainlink:${POSTGRES_PASSWORD}@chainlink-postgres:5432/chainlink
volumes:
- ~/.chainlink-kovan:/chainlink
ports:
- "6688:6688"
networks:
- chainlink_network
chainlink-postgres:
image: postgres:13
container_name: chainlink-postgres
restart: always
environment:
POSTGRES_USER: chainlink
POSTGRES_PASSWORD: MyNewComplexPassword!2024
POSTGRES_DB: chainlink
volumes:
- chainlink_data:/var/lib/postgresql/data
ports:
- "5432:5432"
networks:
- chainlink_network
prometheus:
image: prom/prometheus
container_name: prometheus
restart: always
volumes:
- ./prometheus.yml:/etc/prometheus/prometheus.yml
ports:
- "9090:9090"
networks:
- chainlink_network
grafana:
image: grafana/grafana
container_name: grafana
restart: always
ports:
- "3000:3000"
networks:
- chainlink_network
networks:
chainlink_network:
driver: bridge
volumes:
chainlink_data:
The .env
file looks like this:
pickycamel@chainlink-node:~/chainlink_node_project$ cat .env
ETH_URL=https://rinkeby.infura.io/v3/##########################
ETH_CHAIN_ID=4
[email protected]
CHAINLINK_PASSWORD=MyPassword123@
POSTGRES_PASSWORD=MyNewComplexPassword!2024
The Chainlink container starts, but I always get the error: error authenticating keystore: no password provided
.
The Postgres and other containers are working fine, and I can access the database manually.
The password file .chainlink_password
contains the correct password, and it matches what is in the .env
file.
pickycamel@chainlink-node:~/chainlink_node_project$ cat .chainlink_password
MyPassword123@
pickycamel@chainlink-node:~/chainlink_node_project$ cat prometheus.yml
global:
scrape_interval: 15s
scrape_configs:
- job_name: 'chainlink'
static_configs:
- targets: ['chainlink-node:6688']
pickycamel@chainlink-node:~/chainlink_node_project$
What I have tried:
Verified that the password in .chainlink_password
matches CHAINLINK_PASSWORD
.
Made sure there are no typos or extra whitespace in the .chainlink_password
file.
Updated the database password using psql
inside the container.
Tried removing and re-creating the containers with docker-compose down
followed by docker-compose up -d
.
Questions:
Is there a specific way I need to provide the keystore password to the Chainlink node in Docker Compose?
Has anyone experienced a similar issue and found a solution??
Any help would be greatly appreciated. Thank you in advance!
Upvotes: 0
Views: 30
Reputation: 451
You've to create the config.toml file containing the Secrets Config including the connection URL
of your postgres database and the Keystore
password.
Please refer to the official documentation for the exact steps and configuration.
Upvotes: 1