Skip to content
This repository has been archived by the owner on Jan 23, 2020. It is now read-only.

move /etc/default/sensu sourcing to a different line to keep PATH persistence. #136

Closed
wants to merge 1 commit into from

Conversation

kaushiksriram100
Copy link

sourcing the /etc/default/sensu file may need to happen at a later stage as the any path variable ($PATH) set in the /etc/default/sensu file gets overwritten in subsequent functions. If I set plugin paths or handler paths in the /etc/default/sensu the server doesn't pick that up as PATH variable gets reset when the
. /etc/init.d/functions file is called (in redhat).

@portertech
Copy link
Contributor

@kaushiksriram100 it looks like this move may override valid platform specific options tho, e.g https://github.com/kaushiksriram100/sensu-build/blob/master/sensu_configs/init.d/sensu-service#L69

@kaushiksriram100
Copy link
Author

@portertech : I see that. What options do I have if I need to add some path variables? Specifically, for plugins (if I choose to run from a different directory other than /etc/sensu/plugins).

Currently, I am modifying the sensu-service init file like this ->
PLUGINS_DIR=find <%= @sensu_community_directory %> -type d | sort | tr '\n' ':'

Is this the only option?

@portertech
Copy link
Contributor

@kaushiksriram100 perhaps we just move the default source'n into the platform specific bits?

@cwjohnston cwjohnston closed this Apr 7, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
4 participants