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

Unexplainable: "Configuration missing" in the influxdb out node #146

Open
JorisBloemenIXON opened this issue Jul 3, 2024 · 4 comments
Open

Comments

@JorisBloemenIXON
Copy link

Does anyone have any idea why I get "Configuration missing" when everything is configured?
image
image
I did notice the Token to be shorter after deployment then the one I pasted from InfluxDB. `
I can write to InfluxDB via CURL so the issue seems to be in the influxdb node

@simonbuehler
Copy link

hi, I have the same issue after a fresh install with a influxdbV2, did you manage to fix this?

@JorisBloemenIXON
Copy link
Author

JorisBloemenIXON commented Jul 9, 2024

For some reason manually setting up everything works, meaning with my docker compose file:

services:
  nodered:
    platform: linux/arm64/v8
    image: nodered/node-red:latest
    volumes:
      - ./nodered/data:/data
    depends_on:
      - influxdb
    links:
      - influxdb
    ports:
      - '127.0.0.1:1880:1880'
    env_file:
      - configuration.env

  influxdb:
    platform: linux/arm64/v8
    image: influxdb:2.7.5-alpine
    env_file: .env
    ports:
      - '127.0.0.1:8086:8086'
    volumes:
      - ./:/imports
      - influxdb_data:/var/lib/influxdb

  grafana:
    image: grafana/grafana:latest
    depends_on:
      - influxdb
    links:
      - influxdb
    ports:
      - '127.0.0.1:3000:3000'
    env_file: .env
    volumes:
      - grafana-data:/var/lib/grafana
      - ./grafana/provisioning:/etc/grafana/provisioning
      - ./grafana/dashboards:/var/lib/grafana/dashboards

volumes:
  influxdb_data:
  nodered-data:
  grafana-data:

and then installing node-red-contrib-influxdb
via localhost:1880 and setting up my flows manually

but when you create a custom Dockerfile for nodered, like:

FROM nodered/node-red:latest

# Switch back to node-red user
USER node-red

# Install Node-RED InfluxDB nodes
RUN npm install node-red-contrib-influxdb

# Copy the flow configuration
COPY flows.json /data/flows.json

# Expose Node-RED's default port
EXPOSE 1880

# Set the default command
CMD ["npm", "start"]

This results in the Configuration missing errors, even if you fill in all the required fields manually afterwards

@JorisBloemenIXON
Copy link
Author

updating my dockerfile to do npm install as root seems to help

FROM nodered/node-red:latest

# Switch to root user
USER root

# Install Node-RED InfluxDB nodes
RUN npm install node-red-contrib-influxdb

# Switch back to node-red user
USER node-red

# Copy the flow configuration
COPY flows.json /data/flows.json

# Expose Node-RED's default port
EXPOSE 1880

# Set the default command with a wait script
# CMD ["sh", "-c", "while ! nc -z influxdb 8086; do sleep 1; done; npm start"]
CMD ["npm", "start"]

now only the Token has to be filled in manually

@simonbuehler
Copy link

@JorisBloemenIXON thanks for your input, i'm running it on a raspi zero w without docker and the behavior is quite strange, i managed to get it working when first configuring the config node and the out node afterwards , ... quite fishy 😬

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

2 participants