diff options
| author | shizhendong <[email protected]> | 2023-10-11 18:17:00 +0800 |
|---|---|---|
| committer | shizhendong <[email protected]> | 2023-10-11 18:17:00 +0800 |
| commit | c491be76ac167d5c512b9e05a45801d185f09b6b (patch) | |
| tree | d904bc1f8113972535ee9635684396eb67045e80 | |
| parent | 89b0298733a2d35ed67dce3d5f942296f72f16b8 (diff) | |
fix: NEZ-3218 动态加载 nz-web systemd EnvironmentFile 文件rel-23.10.02
| -rw-r--r-- | tools/afterinstall.sh | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/tools/afterinstall.sh b/tools/afterinstall.sh index 2d2a4a7..54b98f1 100644 --- a/tools/afterinstall.sh +++ b/tools/afterinstall.sh @@ -9,7 +9,7 @@ Description=nz-agent After=network.target [Service] WorkingDirectory=/opt/nezha/nz-agent -EnvironmentFile=/opt/nezha/nz-agent/config/config.conf +EnvironmentFile=-/opt/nezha/nz-agent/config/config.conf ExecStart=/opt/nezha/nz-agent/xjar ${JAVA_EXE} --add-opens java.base/java.net=ALL-UNNAMED --add-opens java.base/jdk.internal.loader=ALL-UNNAMED -Dnz-agent.dir=/opt/nezha/nz-agent -jar /opt/nezha/nz-agent/nz-agent.xjar \$OPTION RestartSec=5s Restart=always @@ -105,9 +105,6 @@ EOF fn_init_config(){ # nz-agent component chmod +x /opt/nezha/nz-agent/xjar - cat > /opt/nezha/nz-agent/config/config.conf <<EOF -OPTION=" " -EOF # prometheus component cat > /opt/nezha/nz-agent/prometheus/config.conf <<EOF |
