Update nginx.yml

This commit is contained in:
fab 2025-01-07 19:06:41 +01:00 committed by GitHub
parent c7b9ec7241
commit bae9ce6bb3
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -26,18 +26,18 @@ jobs:
run: |
unzip nginx_waf.zip -d waf_rules
echo "Extracted WAF rules into waf_rules directory"
ls -lh waf_rules
ls -lh waf_rules/waf_patterns/nginx/
- name: Verify WAF rules extraction
run: |
if [ ! -d "waf_rules" ]; then
if [ ! -d "waf_rules/waf_patterns/nginx" ]; then
echo "Error: WAF rules directory not found after extraction!"
exit 1
fi
if [ -z "$(ls -A waf_rules/*.conf 2>/dev/null)" ]; then
echo "Error: No .conf files found in waf_rules!"
echo "Contents of waf_rules:"
ls -l waf_rules
if [ -z "$(ls -A waf_rules/waf_patterns/nginx/*.conf 2>/dev/null)" ]; then
echo "Error: No .conf files found in waf_rules/waf_patterns/nginx/"
echo "Contents of waf_rules/waf_patterns/nginx/:"
ls -l waf_rules/waf_patterns/nginx/
exit 1
fi
@ -50,7 +50,7 @@ jobs:
- name: Combine Nginx configuration
run: |
cat tests/nginx.conf waf_rules/*.conf > combined_nginx.conf
cat tests/nginx.conf waf_rules/waf_patterns/nginx/*.conf > combined_nginx.conf
echo "Combined Nginx configuration:"
cat combined_nginx.conf