FIWARE OPC-UA - iotagent4fiware/iotagent-opcua:latest NOT RUNNING

Viewed 30

I am going through the OPC UA Agent Tutorial https://github.com/Engineering-Research-and-Development/iotagent-opcua/blob/master/docs/opc_ua_agent_tutorial.md

But after running the docker-compose one of the containers is not working and keeps giving errors. I have tried to delete every image and container and then run it again but still not working

***********************************************

WARNING: It is recommended to enable authentication for secure connection


INFO: IoT Agent running standalone

{"time":"2022-06-16T13:14:06.962Z","lvl":"ERROR","err":{"errno":-2,"syscall":"open","code":"ENOENT","path":"./conf/config.properties","message":"ENOENT: no such file or directory, open './conf/config.properties'","name":"Error","constructor":"Error","stack":"Error: ENOENT: no such file or directory, open './conf/config.properties'\n at Object.openSync (fs.js:462:3)\n at readFileSync (fs.js:364:35)\n at PropertiesReader.append (/opt/iotagent-opcua/node_modules/properties-reader/src/properties-reader.js:100:17)\n at new PropertiesReader (/opt/iotagent-opcua/node_modules/properties-reader/src/properties-reader.js:16:9)\n at propertiesReaderFactory (/opt/iotagent-opcua/node_modules/properties-reader/src/properties-reader-factory.js:6:11)\n at Object.checkproperties (/opt/iotagent-opcua/iot_agent_modules/check_properties.js:4:26)\n at Object. (/opt/iotagent-opcua/index.js:12:20)\n at Module._compile (internal/modules/cjs/loader.js:999:30)\n at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)\n at Module.load (internal/modules/cjs/loader.js:863:32)"},"msg":"Error: ENOENT: no such file or directory, open './conf/config.properties'"}

{"comp":"iotAgent-OPCUA","op":"Index","srv":"","subsrv":"","time":"2022-06-16T13:14:06.965Z","lvl":"ERROR","msg":"undefined"} `

1 Answers

There was some issue for me in docker-compose.yml, volumes for iotagent4fiware/opcuacarsrv:latest were not correct. So, I have changed them according to the position of config.properties file location.

Before: volumes: - ./AGECONF:/opt/iotagent-opcua/conf

After volumes: - ./AGECONF/config:/opt/iotagent-opcua/conf/config

Related