Skip to content
This repository has been archived by the owner on Apr 27, 2022. It is now read-only.

compile-time configurable paths. #19

Closed
zenhack opened this issue Dec 7, 2018 · 0 comments
Closed

compile-time configurable paths. #19

zenhack opened this issue Dec 7, 2018 · 0 comments

Comments

@zenhack
Copy link
Contributor

zenhack commented Dec 7, 2018

Right now we /usr/local/libexec hard-coded in the source, and we're relying on a few things being in $PATH to avoid this hard-coding. It would be nice if we were able to configure where the executables goes at compile time, so we can still customize for different distributions that have different conventions, while keeping the nice property that by hard-coding the path, privop has fewer moving parts at run time.

I linked to this from a commit message:

https://github.com/Ropes/go-linker-vars-example

...which we could build on-top of. Alternatively, we could have a build-time script spit out a config.go with the constants defined.

zenhack added a commit to zenhack/hil-vpn that referenced this issue Dec 7, 2018
hil-vpnd tries to invoke privop via sudo, which resets the PATH to the
defaults. In the centos 7 vagrant image, root does not have
/usr/local/bin in its path, so this was failing.

We should make these things configurable; see CCI-MOC#19.
zenhack added a commit to zenhack/hil-vpn that referenced this issue Dec 7, 2018
hil-vpnd tries to invoke privop via sudo, which resets the PATH to the
defaults. In the centos 7 vagrant image, root does not have
/usr/local/bin in its path, so this was failing.

We should make these things configurable; see CCI-MOC#19.
zenhack added a commit to zenhack/hil-vpn that referenced this issue Dec 8, 2018
hil-vpnd tries to invoke privop via sudo, which resets the PATH to the
defaults. In the centos 7 vagrant image, root does not have
/usr/local/bin in its path, so this was failing.

We should make these things configurable; see CCI-MOC#19.
zenhack added a commit to zenhack/hil-vpn that referenced this issue Dec 8, 2018
See the comments in the Makefile.

Note that a couple things are still hard-coded:

* /etc/openvpn/server when creating configs
* /sbin/brctl in the up hook

This mostly addresses CCI-MOC#19.
zenhack added a commit to zenhack/hil-vpn that referenced this issue Dec 11, 2018
See the comments in the Makefile.

Note that a couple things are still hard-coded:

* /etc/openvpn/server when creating configs
* /sbin/brctl in the up hook

This mostly addresses CCI-MOC#19.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants