iam_production_deployment_guide
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| iam_production_deployment_guide [2026/02/26 11:33] – [Proxy through NGINX] pradnya | iam_production_deployment_guide [2026/02/26 12:47] (current) – [cPanel's userdata include] pradnya | ||
|---|---|---|---|
| Line 454: | Line 454: | ||
| Stop docker and NginX and start again. | Stop docker and NginX and start again. | ||
| + | |||
| + | ===== cPanel' | ||
| + | |||
| + | **Step 1: Create the userdata directories** | ||
| + | |||
| + | bash | ||
| + | |||
| + | < | ||
| + | mkdir -p / | ||
| + | mkdir -p / | ||
| + | |||
| + | </ | ||
| + | |||
| + | **Step 2: Create HTTP proxy config** | ||
| + | |||
| + | bash | ||
| + | |||
| + | < | ||
| + | nano / | ||
| + | |||
| + | </ | ||
| + | |||
| + | Add: | ||
| + | |||
| + | < | ||
| + | RewriteEngine On RewriteRule ^(.*)$ https:// | ||
| + | |||
| + | **Step 3: Create HTTPS proxy config** | ||
| + | |||
| + | bash | ||
| + | |||
| + | < | ||
| + | |||
| + | </ | ||
| + | |||
| + | Add: | ||
| + | |||
| + | < | ||
| + | ProxyPreserveHost On\ | ||
| + | ProxyPass / http:// | ||
| + | ProxyPassReverse / http:// | ||
| + | RequestHeader set X-Forwarded-Proto " | ||
| + | RequestHeader set X-Forwarded-Port " | ||
| + | |||
| + | </ | ||
| + | |||
| + | **Step 4: Rebuild Apache config and restart** | ||
| + | |||
| + | bash | ||
| + | |||
| + | < | ||
| + | / | ||
| + | httpd -t | ||
| + | systemctl restart httpd | ||
| + | |||
| + | </ | ||
| + | |||
| + | Then test: | ||
| + | |||
| + | bash | ||
| + | |||
| + | < | ||
| + | curl -I https:// | ||
| + | |||
| + | </ | ||
| + | |||
| + | Expected result: | ||
| + | |||
| + | < | ||
| + | curl -I [[https:// | ||
| + | |||
| + | HTTP/1.1 302 Found Date: Thu, 26 Feb 2026 11:22:25 GMT | ||
| + | |||
| + | Server: Apache | ||
| + | |||
| + | Location: [[https:// | ||
| + | |||
| + | Referrer-Policy: | ||
| + | |||
| + | Strict-Transport-Security: | ||
| + | |||
| + | X-Content-Type-Options: | ||
| + | |||
| + | X-XSS-Protection: | ||
| + | |||
| + | mode=block | ||
| + | |||
| + | </ | ||
| + | |||
| + | Check for **Location: https:// | ||
| + | |||
| + | This is poining to correct directory and not apache direcoty with cgi folder. | ||
iam_production_deployment_guide.1772105622.txt.gz · Last modified: by pradnya
