Skip to content

Commit

Permalink
Merge pull request #135 from xenit-eu/fix-nginx-config
Browse files Browse the repository at this point in the history
fix nginx config
  • Loading branch information
hechmi-dammak-xenit authored Jan 23, 2024
2 parents 0888686 + 45a6f8a commit cc6cf6b
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 25 deletions.
12 changes: 11 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -283,12 +283,22 @@ For more information take a look at
* Default: 30000
* Description: the default service port that ingress will point to

#### `ingress.blockAcsSolrApi`
#### `ingress.blockAcsSolrApi.enabled`

* Required: false
* Default: `true`
* Description: Enable 403 handler for alfresco api solr endpoints
#### `ingress.blockAcsSolrApi.paths`

* Required: false
* Default:
```yaml
- /alfresco/s/api/solr
- /alfresco/service/api/solr
- /alfresco/service/api/solr
- /alfresco/wcservice/api/solr
```
* Description: List of paths that are blocked
### ACS
#### `acs.replicas`
Expand Down
27 changes: 4 additions & 23 deletions xenit-alfresco/templates/ingress/alfresco-ingress.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -63,36 +63,17 @@ spec:
port:
number: 30500
{{- end }}
{{- if .Values.ingress.blockAcsSolrApi }}
- path: /alfresco/s/api/solr
pathType: Prefix
backend:
service:
name: nginx-403-service
port:
number: 30403
- path: /alfresco/service/api/solr
pathType: Prefix
backend:
service:
name: nginx-403-service
port:
number: 30403
- path: /alfresco/wcs/api/solr
pathType: Prefix
backend:
service:
name: nginx-403-service
port:
number: 30403
- path: /alfresco/wcservice/api/solr
{{- if .Values.ingress.blockAcsSolrApi.enabled }}
{{- range .Values.ingress.blockAcsSolrApi.paths }}
- path: {{ . }}
pathType: Prefix
backend:
service:
name: nginx-403-service
port:
number: 30403
{{- end }}
{{- end }}
{{- if .Values.ingress.additionalPaths }}
{{ toYaml .Values.ingress.additionalPaths | nindent 6 }}
{{- end }}
Expand Down
8 changes: 7 additions & 1 deletion xenit-alfresco/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,13 @@ ingress:
defaultBackend:
service: acs-service
port: 30000
blockAcsSolrApi: true
blockAcsSolrApi:
enabled: true
paths:
- /alfresco/s/api/solr
- /alfresco/service/api/solr
- /alfresco/service/api/solr
- /alfresco/wcservice/api/solr
acs:
replicas: 1
image:
Expand Down

0 comments on commit cc6cf6b

Please sign in to comment.