We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 16c22a1 commit bec964dCopy full SHA for bec964d
.github/workflows/lint_nginx.yml
@@ -0,0 +1,29 @@
1
+name: Nginx Config Linter
2
+
3
+on:
4
+ push:
5
+ branches:
6
+ - main
7
+ pull_request:
8
9
+jobs:
10
+ nginx-lint:
11
+ name: Validate Nginx Config
12
+ runs-on: ubuntu-latest
13
14
+ steps:
15
+ - name: Checkout repository
16
+ uses: actions/checkout@v4
17
18
+ - name: Install Nginx
19
+ run: |
20
+ sudo apt-get update
21
+ sudo apt-get install -y nginx
22
23
+ - name: Find and Test Nginx Config Files
24
25
+ set -e # Exit on error
26
+ find . -name "reverse-proxy.conf" -print0 | while IFS= read -r -d '' file; do
27
+ echo "Checking $file..."
28
+ sudo nginx -t -c "$(realpath "$file")"
29
+ done
0 commit comments