Files
invoiceninja-docker/charts/invoiceninja/templates/serverblock.yaml
Ween Jiann 7238e521e6 Automatically set values for Nginx sub-chart based on install name (#370)
* Automatically set serverblock from IN chart

* Automatically set nginx PVC

* Bump chart version

* Upgrade dependencies

* Updated k8s test versions
2021-07-07 04:19:03 +08:00

40 lines
1.3 KiB
YAML

apiVersion: v1
kind: ConfigMap
metadata:
name: {{ include "invoiceninja.nginx.serverBlockName" . }}
labels:
{{- include "common.labels.standard" $ | nindent 4 }}
{{- if .Values.commonLabels }}
{{- include "common.tplvalues.render" ( dict "value" .Values.commonLabels "context" $ ) | nindent 4 }}
{{- end }}
{{- if .Values.commonAnnotations }}
annotations:
{{- include "common.tplvalues.render" ( dict "value" .Values.commonAnnotations "context" $ ) | nindent 4 }}
{{- end }}
data:
server-block.conf: |-
server {
listen 8080 default_server;
server_name _;
root /app;
index index.php;
location / {
try_files $uri $uri/ /index.php?$query_string;
}
location = /favicon.ico { access_log off; log_not_found off; }
location = /robots.txt { access_log off; log_not_found off; }
location ~ \.php$ {
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_pass {{ include "common.names.fullname" . }}:9000;
fastcgi_index index.php;
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME /var/www/app/public$fastcgi_script_name;
fastcgi_buffer_size 16k;
fastcgi_buffers 4 16k;
}
}