undo if/else
This commit is contained in:
parent
f06d174012
commit
c373fd500f
|
@ -1,20 +1,12 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
# if a command was specified, we run that command. E.g. helpful when we do
|
/opt/fahclient/FAHClient \
|
||||||
# docker run -it <container> /bin/bash
|
--user="${USER}" \
|
||||||
if [ "${1}" ]
|
--team="${TEAM}" \
|
||||||
then
|
--passkey="${PASSKEY}" \
|
||||||
exec "$@"
|
--gpu="${ENABLE_GPU}" \
|
||||||
# otherwise we attempt to run fahclient.
|
--smp="${ENABLE_SMP}" \
|
||||||
else
|
--power=full \
|
||||||
/opt/fahclient/FAHClient \
|
--gui-enabled=false \
|
||||||
--user="${USER}" \
|
"${@}"
|
||||||
--team="${TEAM}" \
|
|
||||||
--passkey="${PASSKEY}" \
|
|
||||||
--gpu="${ENABLE_GPU}" \
|
|
||||||
--smp="${ENABLE_SMP}" \
|
|
||||||
--power=full \
|
|
||||||
--gui-enabled=false \
|
|
||||||
"${@}"
|
|
||||||
fi
|
|
||||||
|
|
Loading…
Reference in a new issue