🔖 installer v0.8.3 [skip ci]
				
					
				
			This commit is contained in:
		
							parent
							
								
									e8871253db
								
							
						
					
					
						commit
						a75b19922a
					
				@ -4,7 +4,7 @@
 | 
			
		||||
  <br>
 | 
			
		||||
  <small><i>LOGO designed by <a href="https://xio.ng" target="_blank">熊大</a> .</i></small>
 | 
			
		||||
  <br><br>
 | 
			
		||||
<img src="https://img.shields.io/github/workflow/status/naiba/nezha/Dashboard%20image?label=Dash%20v0.12.28&logo=github&style=for-the-badge"> <img src="https://img.shields.io/github/v/release/naiba/nezha?color=brightgreen&label=Agent&style=for-the-badge&logo=github"> <img src="https://img.shields.io/github/workflow/status/naiba/nezha/Agent%20release?label=Agent%20CI&logo=github&style=for-the-badge"> <img src="https://img.shields.io/badge/Installer-v0.8.2-brightgreen?style=for-the-badge&logo=linux">
 | 
			
		||||
<img src="https://img.shields.io/github/workflow/status/naiba/nezha/Dashboard%20image?label=Dash%20v0.12.28&logo=github&style=for-the-badge"> <img src="https://img.shields.io/github/v/release/naiba/nezha?color=brightgreen&label=Agent&style=for-the-badge&logo=github"> <img src="https://img.shields.io/github/workflow/status/naiba/nezha/Agent%20release?label=Agent%20CI&logo=github&style=for-the-badge"> <img src="https://img.shields.io/badge/Installer-v0.8.3-brightgreen?style=for-the-badge&logo=linux">
 | 
			
		||||
  <br>
 | 
			
		||||
  <br>
 | 
			
		||||
  <p>:trollface: <b>哪吒监控</b> 一站式轻监控轻运维系统。支持系统状态、HTTP(SSL 证书变更、即将到期、到期)、TCP、Ping 监控报警,计划任务和在线终端。</p>
 | 
			
		||||
@ -260,7 +260,7 @@ URL 里面也可放置占位符,请求时会进行简单的字符串替换。
 | 
			
		||||
<details>
 | 
			
		||||
    <summary>如何使 新版OpenWRT 自启动?来自 @艾斯德斯</summary>
 | 
			
		||||
 | 
			
		||||
首先在 release 下载对应的二进制解压 tar.gz 包后放置到 `/root`,然后 `chmod +x /root/nezha-agent` 赋予执行权限,然后创建 `/etc/init.d/nezha-service`:
 | 
			
		||||
首先在 release 下载对应的二进制解压 zip 包后放置到 `/root`,然后 `chmod +x /root/nezha-agent` 赋予执行权限,然后创建 `/etc/init.d/nezha-service`:
 | 
			
		||||
 | 
			
		||||
```shell
 | 
			
		||||
#!/bin/sh /etc/rc.common
 | 
			
		||||
 | 
			
		||||
@ -11,7 +11,7 @@ NZ_BASE_PATH="/opt/nezha"
 | 
			
		||||
NZ_DASHBOARD_PATH="${NZ_BASE_PATH}/dashboard"
 | 
			
		||||
NZ_AGENT_PATH="${NZ_BASE_PATH}/agent"
 | 
			
		||||
NZ_AGENT_SERVICE="/etc/systemd/system/nezha-agent.service"
 | 
			
		||||
NZ_VERSION="v0.8.2"
 | 
			
		||||
NZ_VERSION="v0.8.3"
 | 
			
		||||
 | 
			
		||||
red='\033[0;31m'
 | 
			
		||||
green='\033[0;32m'
 | 
			
		||||
@ -200,14 +200,14 @@ install_agent() {
 | 
			
		||||
    chmod 777 -R $NZ_AGENT_PATH
 | 
			
		||||
 | 
			
		||||
    echo -e "正在下载监控端"
 | 
			
		||||
    wget -O nezha-agent_linux_${os_arch}.tar.gz https://${GITHUB_URL}/naiba/nezha/releases/download/${version}/nezha-agent_linux_${os_arch}.tar.gz >/dev/null 2>&1
 | 
			
		||||
    wget -O nezha-agent_linux_${os_arch}.zip https://${GITHUB_URL}/naiba/nezha/releases/download/${version}/nezha-agent_linux_${os_arch}.zip >/dev/null 2>&1
 | 
			
		||||
    if [[ $? != 0 ]]; then
 | 
			
		||||
        echo -e "${red}Release 下载失败,请检查本机能否连接 ${GITHUB_URL}${plain}"
 | 
			
		||||
        return 0
 | 
			
		||||
    fi
 | 
			
		||||
    tar xf nezha-agent_linux_${os_arch}.tar.gz &&
 | 
			
		||||
    tar xf nezha-agent_linux_${os_arch}.zip &&
 | 
			
		||||
        mv nezha-agent $NZ_AGENT_PATH &&
 | 
			
		||||
        rm -rf nezha-agent_linux_${os_arch}.tar.gz README.md
 | 
			
		||||
        rm -rf nezha-agent_linux_${os_arch}.zip README.md
 | 
			
		||||
 | 
			
		||||
    if [ $# -ge 3 ]; then
 | 
			
		||||
        modify_agent_config "$@"
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user