feat: integrate mintel gatekeeper into testing environment
This commit is contained in:
@@ -266,8 +266,17 @@ jobs:
|
||||
ENV_FILE=$ENV_FILE
|
||||
EOF
|
||||
|
||||
# AUTH_MIDDLEWARE logic
|
||||
printf "AUTH_MIDDLEWARE=%s\n" "$( [[ "$TARGET" == "production" ]] && echo "${PROJECT_NAME}-compress" || echo "${PROJECT_NAME}-auth,${PROJECT_NAME}-compress" )" >> .env.deploy
|
||||
# Middleware Selection Logic
|
||||
# Regular app routes get auth on non-production
|
||||
# Unprotected routes (/stats, /errors) never get auth
|
||||
STD_MW="${PROJECT_NAME}-ratelimit,${PROJECT_NAME}-forward,${PROJECT_NAME}-compress"
|
||||
|
||||
if [[ "$TARGET" == "production" ]]; then
|
||||
printf "AUTH_MIDDLEWARE=%s\n" "$STD_MW" >> .env.deploy
|
||||
else
|
||||
printf "AUTH_MIDDLEWARE=%s\n" "${PROJECT_NAME}-auth,$STD_MW" >> .env.deploy
|
||||
fi
|
||||
printf "AUTH_MIDDLEWARE_UNPROTECTED=%s\n" "$STD_MW" >> .env.deploy
|
||||
|
||||
- name: 🚀 SSH Deploy
|
||||
shell: bash
|
||||
|
||||
Reference in New Issue
Block a user