Add GitHub Actions deployment workflow
- Add deployment workflow with test, build, and deploy jobs - Add testing workflow for PRs - Add deployment scripts (deploy, healthcheck, rollback) - Add systemd service configuration - Update Makefile with CI/CD targets - Add comprehensive deployment documentation
This commit is contained in:
@@ -0,0 +1,45 @@
|
||||
[Unit]
|
||||
Description=CV Website Service
|
||||
After=network.target
|
||||
Wants=network-online.target
|
||||
|
||||
[Service]
|
||||
Type=simple
|
||||
User=txeo
|
||||
Group=txeo
|
||||
WorkingDirectory=/home/txeo/Git/yo/cv
|
||||
ExecStart=/home/txeo/Git/yo/cv/cv-server
|
||||
|
||||
# Environment variables
|
||||
Environment="GO_ENV=production"
|
||||
Environment="PORT=1999"
|
||||
Environment="HOST=0.0.0.0"
|
||||
Environment="BASE_URL=https://juan.andres.morenorub.io"
|
||||
Environment="TEMPLATE_HOT_RELOAD=false"
|
||||
EnvironmentFile=-/home/txeo/Git/yo/cv/.env
|
||||
|
||||
# Security hardening
|
||||
NoNewPrivileges=true
|
||||
PrivateTmp=true
|
||||
ProtectSystem=strict
|
||||
ProtectHome=false
|
||||
ReadWritePaths=/home/txeo/Git/yo/cv/data
|
||||
ReadOnlyPaths=/home/txeo/Git/yo/cv
|
||||
|
||||
# Resource limits
|
||||
LimitNOFILE=65536
|
||||
MemoryMax=512M
|
||||
|
||||
# Restart policy
|
||||
Restart=always
|
||||
RestartSec=5
|
||||
StartLimitInterval=60
|
||||
StartLimitBurst=3
|
||||
|
||||
# Logging
|
||||
StandardOutput=journal
|
||||
StandardError=journal
|
||||
SyslogIdentifier=cv
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
||||
Reference in New Issue
Block a user