HI, I recently installed my own OpenhabCloud on a VPS. It’s running just fine and has greatly improved the overall experience of OpenHAB
I would very much like to configure my own account as staff/admin so i can view stats and perhaps for other stuff i noticed various script for.
Could someone please tell me how to configure someone as admin.
I have a script called “makeadmin.js” in /var/www/openhab-cloud but upon execution is throws the following error: openHAB-cloud: mongo connection error: MongoError: field missing/wrong type in received authenticate command
thats not a bug ;-).
So please check the code and make yourself staff (do it yourself )
There is a script that you can find if you look into the project sources.
BR Mehmet
I have gotten the dockerized openhab-cloud image up and running. I have successfully registered myself as a user. I would now like to remove the register option before I expose the openhab-cloud instance to the internet. How should I achieve this without removing the registration I have already set up?
In config.json, I set "registration_enabled": false
And then I rebuild the app-1 docker image only via sudo docker-compose build app-1
?
Thanks!
Edit: Is there any way to avoid having to rebuild the entire app after changing some setting in the config file?
@ScheissSchiesser could you help me set up my dockerized openhab-cloud? I cloned the repo and I am trying to follow the instructions. So far, the only edit I made in config.json is on the line for host…
“system”: {
“host”: “<my_dns_url.com>”…
The result is 502 Bad Gateway at my_dns_url.com. I’m having trouble understanding the required configuration edits. I would be grateful for an assist. Thx
Here is an update: I confirmed the database name for mongodb is the same in docker-compose.yml and config.json i.e. “openhab”. However, the logs below show a problem with mongo and redis. I’m not sure where to go from here.
app-1 | Option polling duration is not valid. Please refer to the README.
app-1 | 2018-03-11T23:44:51.884Z - info: openHAB-cloud: express server listening on port 3000
app-1 | 2018-03-11T23:44:51.889Z - error: openHAB-cloud: Redis error: Error: Redis connection to 127.0.0.1:6379 failed - connect ECONNREFUSED 127.0.0.1:6379
app-1 | Warning: connect-redis reported a client error: Error: Redis connection to 127.0.0.1:6379 failed - connect ECONNREFUSED 127.0.0.1:6379
app-1 | 2018-03-11T23:44:51.890Z - error: openHAB-cloud: Redis error: connection is closed
app-1 | 2018-03-11T23:44:51.893Z - error: code=UNCERTAIN_STATE, command=AUTH, args=[password], code=ECONNREFUSED, errno=ECONNREFUSED, syscall=connect, address=127.0.0.1, port=6379
app-1 | 2018-03-11T23:44:51.906Z - error: openHAB-cloud: Error while connecting from openHAB-cloud to mongodb: MongoError: connect ECONNREFUSED 127.0.0.1:27017
app-1 | 2018-03-11T23:44:51.906Z - error: openHAB-cloud: Stopping openHAB-cloud due to error with mongodb
you need to rename the name of mongo and redis in the config.json from localhost to mongo and redis (see readme for docker).
There will be some major updates regarding docker and docker compose soon.
Also regarding changes:
You can easily rebuild e.g. app-1 by calling the proper docker-compose command:
docker-compose build app-1.
The app config.json is read as system config and you might (in normal cases) restart the app to reload it. But with the docker build the conf is copied into the container and you can connect to that container and modify config.json and restart app.