Files
bus-capacitor-calculator/deploy/bus-capacitor-deploy.service
gaochengyu 73ab36f7ff feat: 开源母线电容计算器并接入独立自动部署
整理 Buck 与 PMSM 完整源码、离线构建、校核测试和使用说明,采用 MIT 许可。
增加页首开源链接,支持推送 main 后自动测试、构建并发布到原计算器网址。
2026-11-27 04:38:28 +08:00

24 lines
686 B
Desktop File

[Unit]
Description=Test, build and publish the latest bus capacitor calculator
After=network-online.target
Wants=network-online.target
[Service]
Type=oneshot
User=codex
Group=codex
UMask=0077
WorkingDirectory=/srv/bus-capacitor/automation
ExecStart=/usr/bin/python3 -B /srv/bus-capacitor/automation/worker.py /srv/bus-capacitor/automation/config.json
TimeoutStartSec=5min
NoNewPrivileges=true
PrivateTmp=true
ProtectSystem=strict
ProtectHome=read-only
ReadWritePaths=/srv/bus-capacitor/automation /var/www/bus-capacitor
InaccessiblePaths=-/run/docker.sock -/var/run/docker.sock -/home/codex/.ssh
RestrictAddressFamilies=AF_INET AF_INET6 AF_UNIX
MemoryMax=1G
MemorySwapMax=512M
Nice=10