Skip to content

Commit

Permalink
Use existing rancher-system-agent.env for repopulating environment va…
Browse files Browse the repository at this point in the history
…riables for install script when SUC is in action (#56)

Signed-off-by: Chris Kim <[email protected]>
  • Loading branch information
Oats87 authored Aug 26, 2021
1 parent 399d76a commit 68d4108
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions package/suc/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,9 @@ fi

export CATTLE_AGENT_BINARY_LOCAL=true
export CATTLE_AGENT_BINARY_LOCAL_LOCATION=${TMPDIR}/rancher-system-agent
if [ -s /host/etc/systemd/system/rancher-system-agent.env ]; then
export $(grep -v '^#' /host/etc/systemd/system/rancher-system-agent.env | xargs)
fi
chroot /host ${TMPDIR}/install.sh "$@"

cleanup

0 comments on commit 68d4108

Please sign in to comment.