Skip to content

Commit be9a514

Browse files
committed
Add support for CATTLE_AGENT_VAR_DIR in suc plan
1 parent b2ef254 commit be9a514

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

Diff for: package/Dockerfile.suc

+2
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ RUN /usr/bin/kubectl version --client
1212
ARG ALPINE=alpine:3.18
1313
FROM ${ALPINE}
1414

15+
ENV CATTLE_AGENT_VAR_DIR="/var/lib/rancher/agent"
16+
1517
RUN mkdir /opt/rancher-system-agent-suc
1618
COPY install.sh /opt/rancher-system-agent-suc/install.sh
1719
COPY system-agent-uninstall.sh /opt/rancher-system-agent-suc/system-agent-uninstall.sh

Diff for: package/suc/run.sh

+2-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@
22

33
set -x -e
44

5-
TMPDIRBASE=/var/lib/rancher/agent/tmp
5+
CATTLE_AGENT_VAR_DIR=${CATTLE_AGENT_VAR_DIR:-/var/lib/rancher/agent}
6+
TMPDIRBASE=${CATTLE_AGENT_VAR_DIR}/tmp
67

78
mkdir -p "/host${TMPDIRBASE}"
89

0 commit comments

Comments
 (0)