diff --git a/dietpi/dietpi-software b/dietpi/dietpi-software index 9981da9a91..0bdd691d30 100755 --- a/dietpi/dietpi-software +++ b/dietpi/dietpi-software @@ -6556,7 +6556,7 @@ StartLimitBurst=3 [Service] User=frp AmbientCapabilities=CAP_NET_BIND_SERVICE -ExecStart=/usr/local/bin/frps -c /etc/frp/frps.ini +ExecStart=/usr/local/bin/frps -c /etc/frp/frps.toml Restart=on-failure RestartSec=5s @@ -6565,19 +6565,19 @@ WantedBy=multi-user.target _EOF_ # Pre-create config file to turn on dashboard token=$(openssl rand -hex 15) - [[ -f '/etc/frp/frps.ini' ]] || cat << _EOF_ > /etc/frp/frps.ini -[common] -bind_port = 7000 + [[ -f '/etc/frp/frps.toml' ]] || cat << _EOF_ > /etc/frp/frps.toml +bindPort = 7000 -dashboard_port = 7500 -dashboard_user = admin -dashboard_pwd = $GLOBAL_PW +webServer.addr = "0.0.0.0" +webServer.port = 7500 +webServer.user = "admin" +webServer.password = "$GLOBAL_PW" -authentication_method = token -token = $token +auth.method = "token" +auth.token = "$token" _EOF_ - G_EXEC chmod 0640 /etc/frp/frps.ini - G_EXEC chown root:frp /etc/frp/frps.ini + G_EXEC chmod 0640 /etc/frp/frps.toml + G_EXEC chown root:frp /etc/frp/frps.toml aENABLE_SERVICES+=('frps') fi @@ -6594,8 +6594,8 @@ StartLimitBurst=3 [Service] User=frp -ExecStart=/usr/local/bin/frpc -c /etc/frp/frpc.ini -ExecReload=/usr/local/bin/frpc reload -c /etc/frp/frpc.ini +ExecStart=/usr/local/bin/frpc -c /etc/frp/frpc.toml +ExecReload=/usr/local/bin/frpc reload -c /etc/frp/frpc.toml Restart=on-failure RestartSec=5s @@ -6632,20 +6632,20 @@ _EOF_ fi # Pre-create config file to turn on admin UI - [[ -f '/etc/frp/frpc.ini' ]] || cat << _EOF_ > /etc/frp/frpc.ini -[common] -server_addr = $server_addr -server_port = $server_port + [[ -f '/etc/frp/frpc.toml' ]] || cat << _EOF_ > /etc/frp/frpc.toml +serverAddr = "$server_addr" +serverPort = $server_port -admin_addr = 0.0.0.0 -admin_port = 7400 -admin_user = admin -admin_pwd = $GLOBAL_PW +webServer.addr = "0.0.0.0" +webServer.port = 7400 +webServer.user = "admin" +webServer.password = "$GLOBAL_PW" -token = $token +auth.method = "token" +auth.token = "$token" _EOF_ - G_EXEC chmod 0660 /etc/frp/frpc.ini - G_EXEC chown root:frp /etc/frp/frpc.ini + G_EXEC chmod 0660 /etc/frp/frpc.toml + G_EXEC chown root:frp /etc/frp/frpc.toml aENABLE_SERVICES+=('frpc') fi