Skip to content

Commit

Permalink
inject more env var when start-computer.sh (#115)
Browse files Browse the repository at this point in the history
  • Loading branch information
coderzc committed Oct 14, 2021
1 parent 5f06b65 commit 614d8a0
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
1 change: 1 addition & 0 deletions .gitignore
Expand Up @@ -18,3 +18,4 @@
target
gen-java
build
**/dependency-reduced-pom.xml
2 changes: 1 addition & 1 deletion computer-dist/src/assembly/static/bin/start-computer.sh
Expand Up @@ -175,7 +175,7 @@ if [ ! -a "${COPY_CONF_DIR}" ]; then
fi

NEW_COMPUTER_CONF_PATH="${COPY_CONF_DIR}/$(basename "${COMPUTER_CONF_PATH}")"
envsubst '${POD_IP}' < "${COMPUTER_CONF_PATH}" > "${NEW_COMPUTER_CONF_PATH}"
envsubst '${POD_IP},${HOSTNAME},${POD_NAME},${POD_NAMESPACE}' < "${COMPUTER_CONF_PATH}" > "${NEW_COMPUTER_CONF_PATH}"
chmod 777 "${NEW_COMPUTER_CONF_PATH}"

if [ "${LOG4J_CONF_PATH}" != "" ];then
Expand Down
Expand Up @@ -99,7 +99,7 @@ public static boolean waitUntilReady(Duration initialDelay,
}

public static String crName(String jobId) {
return jobId.toLowerCase();
return jobId.toLowerCase().replaceAll("_", "-");
}

public static String genJobId(String algorithmName) {
Expand Down

0 comments on commit 614d8a0

Please sign in to comment.