feat: add .gitignore and apps/template for new apps

This commit is contained in:
2026-04-01 16:32:59 +08:00
parent 98cd6b71cb
commit 19342c6821
10 changed files with 292 additions and 0 deletions

15
apps/template/stop.sh Executable file
View File

@@ -0,0 +1,15 @@
#!/usr/bin/env bash
# 用途:停止 {{APP_NAME}}(保留資料)
set -euo pipefail
APP_NAME="{{APP_NAME}}"
echo "🛑 停止 $APP_NAME(保留 PVC 資料)..."
# 只刪除 Deployment 和 ServicePVC 會保留
kubectl delete deployment/$APP_NAME --ignore-not-found
kubectl delete service/$APP_NAME-service --ignore-not-found
kubectl delete ingress/$APP_NAME-ingress --ignore-not-found
echo "$APP_NAME 已停止,資料安全保留"