2
启动时启动stunnel服务
我有自制服务。只需通过运行命令即可启动此服务 sudo stunnel 我需要这个命令在启动时运行,所以我创建了一个LaunchDaemon但它无法正常工作。这是launchd文件: <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple$ <plist version="1.0"> <dict> <key>Label</key> <string>com.stunnel.stunnelstartup.plist</string> <key>ProgramArguments</key> <array> <string>/bin/sh</string> <string>/usr/local/etc/stunnel/startup.sh</string> </array> <key>UserName</key> <string>ROOT</string> <key>RunAtLoad</key> <true/> <key>KeepAlive</key> <false/> </dict> </plist> 这是shell脚本: #!/bin/bash #stunnel startup sleep 30 #Delay added for the system to boot properly sudo stunnel 我究竟做错了什么??? …