Skip to content

Commit

Permalink
fix plugin specific installation
Browse files Browse the repository at this point in the history
  • Loading branch information
nyxnor committed Feb 19, 2022
1 parent eac7967 commit 3930f2f
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 3 deletions.
4 changes: 4 additions & 0 deletions auto-generated-man-pages/onionjuggler.conf.5
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,10 @@ Variables set to and empty string, either \f[I]var=\f[R] or
.SH OPTIONS
.SS SYSTEM
.TP
\f[B]onionjuggler_plugin\f[R]
Only install specified plugins, else install everything.
(Default: all plugins).
.TP
\f[B]su_cmd\f[R]
Command to run as another user, use to run as the root and the tor user.
Compatible with \f[I]doas\f[R] and \f[I]sudo\f[R].
Expand Down
4 changes: 3 additions & 1 deletion configure.sh
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,9 @@ case "${command}" in
man_extension="${man##*.}"
cp "${man}" "${man_dir}/man${man_extension}"
done
if [ -n "${plugin}" ]; then
if [ -n "${plugin}" ] || [ -n "${pnionjuggler_plugin}" ]; then
## overwrite default plugins with the ones specified on the cli, else use conf
{ [ -n "${pnionjuggler_plugin}" ] && [ -z "${plugin}" ]; } && plugin="${onionjuggler_plugin}"
cp "${topdir}"/usr/bin/onionjuggler-tui "${topdir}"/usr/bin/onionjuggler-cli "${bin_dir}"
for pg in $(printf '%s\n' "${plugin}" | tr "," " "); do
pg="${pg##*onionjuggler-cli-}"
Expand Down
2 changes: 1 addition & 1 deletion etc/onionjuggler/whonix-gateway.conf
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
# shellcheck disable=SC2034

########## System ##########
onionjuggler_plugins="auth-server,auth-client"
onionjuggler_plugin="auth-server,auth-client"
su_cmd="sudo"
pkg_mngr_install="apt install -y"
openssl_cmd="openssl"
Expand Down
2 changes: 1 addition & 1 deletion etc/onionjuggler/whonix-workstation.conf
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
# shellcheck disable=SC2034

########## System ##########
onionjuggler_plugins="web"
onionjuggler_plugin="web"
su_cmd="sudo"
pkg_mngr_install="apt install -y"
webserver="nginx"
Expand Down
4 changes: 4 additions & 0 deletions man/onionjuggler.conf.5.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,10 @@ Variables set to and empty string, either *var=* or *var=""*, will run with defa

## SYSTEM

**onionjuggler_plugin**

: Only install specified plugins, else install everything. (Default: all plugins).

**su_cmd**

: Command to run as another user, use to run as the root and the tor user. Compatible with *doas* and *sudo*. (Default: sudo).
Expand Down

0 comments on commit 3930f2f

Please sign in to comment.