Closed drpebcak closed 6 years ago
Configuration should not be stored in /opt/uchiwa
as it's where the omnibus build is contained and changes will only persist until a newer version of Uchiwa is installed.
The uchiwa
user belongs to the sensu
group and should have full access to /etc/sensu/uchiwa.json
.
@amdprophet that's a good point. uchiwa.json should be somewhere else by default, but it still doesn't make sense to keep it in /etc/sensu
.
Where is the uchiwa user added to the sensu group? Default membership is in the uchiwa group, which doesn't seem to line up with the sensu group on my system.
@drpebcak currently, the rpm & deb scripts take care of adding the uchiwa user & adding it to the sensu group. This may be something that changes down the road but will require modification of the uchiwa-build repo for Uchiwa.
https://github.com/sensu/uchiwa-build/blob/master/pkg_scripts/rpm/pre https://github.com/sensu/uchiwa-build/blob/master/pkg_scripts/deb/postinst
I'm fine with storing uchiwa.json
in /etc/uchiwa
but I'd like to hear @palourde & @portertech's opinion.
Just another note - we're currently refactoring the way we build Uchiwa packages. The uchiwa-build repository may be deprecated soon.
Hmm I'll have to look into this. The uchiwa user is not in the sensu group on my system. I'll try to see if I can replicate this.
any progress on this? I think that it should be default stored in /etc/uchiwa
and stuck anywhere you want it (including /etc/sensu
) though I completely agree that /opt/uchiwa
is the wrong place but if someone wants to do something silly we can let them.
closing due to lack of response
In the default location (when sensu and uchiwa are both installed via cookbook), uchiwa.json is unreadable because
/etc/sensu
is owned bysensu:sensu
. This fixes that issue by placing the json file in/opt/uchiwa
by default, and includes an initscript that actually honors this setting.