mirror of
https://git.meshkee.com/cssd/cssd-back.git
synced 2026-10-10 20:01:07 +03:30
feat: redirect to www
This commit is contained in:
+15
-7
@@ -392,13 +392,15 @@ ingress:
|
||||
|
||||
# List of host addresses to be exposed by this Ingress
|
||||
hosts:
|
||||
- host: cssd-doc.ir
|
||||
- host: cssd-doc.com
|
||||
- host: www.cssd-doc.ir
|
||||
- host: www.cssd-doc.com
|
||||
# Additional labels for this Ingress
|
||||
additionalLabels:
|
||||
|
||||
# Add annotations to this Ingress
|
||||
annotations:
|
||||
ingress.kubernetes.io/force-ssl-redirect: "true"
|
||||
nginx.ingress.kubernetes.io/from-to-www-redirect: "true"
|
||||
# kubernetes.io/ingress.class: external-ingress
|
||||
# ingress.kubernetes.io/rewrite-target: /
|
||||
# ingress.kubernetes.io/force-ssl-redirect: true
|
||||
@@ -408,10 +410,10 @@ ingress:
|
||||
# Secrets must be manually created in the namespace.
|
||||
- secretName: cssd-doc-ir-certificate
|
||||
hosts:
|
||||
- cssd-doc.ir
|
||||
- www.cssd-doc.ir
|
||||
- secretName: cssd-doc-com-certificate
|
||||
hosts:
|
||||
- cssd-doc.com
|
||||
- www.cssd-doc.com
|
||||
|
||||
##########################################################
|
||||
# Route object for exposing services (OpenShift)
|
||||
@@ -574,13 +576,19 @@ configMap:
|
||||
listen 80;
|
||||
server_name cssd-doc.ir www.cssd-doc.ir;
|
||||
|
||||
return 301 https://cssd-doc.com$request_uri;
|
||||
return 301 https://www.cssd-doc.com$request_uri;
|
||||
}
|
||||
|
||||
|
||||
server {
|
||||
listen 80;
|
||||
server_name cssd-doc.com www.cssd-doc.com;
|
||||
server_name cssd-doc.com;
|
||||
|
||||
return 301 https://www.cssd-doc.com$request_uri;
|
||||
}
|
||||
|
||||
server {
|
||||
listen 80;
|
||||
server_name www.cssd-doc.com;
|
||||
|
||||
access_log /var/log/nginx/access.log main;
|
||||
error_log /var/log/nginx/error.log;
|
||||
|
||||
Reference in New Issue
Block a user