Try to fix apache not starting
This commit is contained in:
parent
0b8d0f0e6b
commit
388650205d
5 changed files with 47 additions and 8 deletions
|
@ -3,6 +3,36 @@ kind: ConfigMap
|
||||||
metadata:
|
metadata:
|
||||||
name: nextcloud-configmap
|
name: nextcloud-configmap
|
||||||
data:
|
data:
|
||||||
|
000-default.conf: |
|
||||||
|
Listen 8080
|
||||||
|
<VirtualHost *:8080>
|
||||||
|
ServerAdmin webmaster@localhost
|
||||||
|
DocumentRoot /var/www/html
|
||||||
|
# Log format config
|
||||||
|
LogFormat "%{X-Forwarded-For}i %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" common
|
||||||
|
SetEnvIf X-Forwarded-For "^.*\..*\..*\..*" forwarded
|
||||||
|
|
||||||
|
# Header config
|
||||||
|
RemoteIPHeader X-Forwarded-For
|
||||||
|
RemoteIPInternalProxy 37.156.195.11
|
||||||
|
RemoteIPInternalProxy 37.156.195.12
|
||||||
|
RemoteIPInternalProxy 37.156.195.21
|
||||||
|
RemoteIPInternalProxy 37.156.195.22
|
||||||
|
# TODO: Package 404 for k8s
|
||||||
|
# ErrorDocument 404 /404.html
|
||||||
|
ErrorLog /dev/stderr
|
||||||
|
TransferLog /dev/stdout
|
||||||
|
<Directory /var/www/html/>
|
||||||
|
LimitRequestBody 0
|
||||||
|
Require all granted
|
||||||
|
AllowOverride All
|
||||||
|
Options FollowSymLinks MultiViews
|
||||||
|
|
||||||
|
<IfModule mod_dav.c>
|
||||||
|
Dav off
|
||||||
|
</IfModule>
|
||||||
|
</Directory>
|
||||||
|
</VirtualHost>
|
||||||
config.php: |
|
config.php: |
|
||||||
<?php
|
<?php
|
||||||
$CONFIG = array (
|
$CONFIG = array (
|
||||||
|
|
|
@ -34,10 +34,13 @@ spec:
|
||||||
- name: nextcloud-data
|
- name: nextcloud-data
|
||||||
mountPath: /var/www/html/config
|
mountPath: /var/www/html/config
|
||||||
subPath: config
|
subPath: config
|
||||||
|
- name: apache-config
|
||||||
|
mountPath: /etc/apache2/sites-enabled/000-default.conf
|
||||||
|
subPath: 000-default.conf
|
||||||
ports:
|
ports:
|
||||||
- containerPort: 443
|
- containerPort: 8080
|
||||||
name: nextcloud-https
|
name: nextcloud-http
|
||||||
command: ['/bin/sh', '-c', '. /etc/apache2/envvars; apache2 -k start; tail -f /var/log/apache2/access.log /var/log/apache2/error.log /var/log/apache2/other_vhosts_access.log']
|
command: ['/bin/sh', '-c', '. /etc/apache2/envvars; apache2 -k start -DFORGROUND']
|
||||||
initContainers:
|
initContainers:
|
||||||
- image: docker.sunet.se/sunet/docker-jinja:latest
|
- image: docker.sunet.se/sunet/docker-jinja:latest
|
||||||
name: init-config
|
name: init-config
|
||||||
|
@ -149,3 +152,9 @@ spec:
|
||||||
items:
|
items:
|
||||||
- key: "config.php"
|
- key: "config.php"
|
||||||
path: "config.php"
|
path: "config.php"
|
||||||
|
- name: apache-config
|
||||||
|
configMap:
|
||||||
|
name: nextcloud-configmap
|
||||||
|
items:
|
||||||
|
- key: "000-default.conf"
|
||||||
|
path: "000-default.conf"
|
||||||
|
|
|
@ -12,7 +12,7 @@ spec:
|
||||||
service:
|
service:
|
||||||
name: customer-node
|
name: customer-node
|
||||||
port:
|
port:
|
||||||
number: 443
|
number: 8443
|
||||||
tls:
|
tls:
|
||||||
- hosts:
|
- hosts:
|
||||||
- customer.drive.test.sunet.se
|
- customer.drive.test.sunet.se
|
||||||
|
@ -28,4 +28,4 @@ spec:
|
||||||
service:
|
service:
|
||||||
name: customer-node
|
name: customer-node
|
||||||
port:
|
port:
|
||||||
number: 443
|
number: 8080
|
||||||
|
|
|
@ -9,9 +9,9 @@ items:
|
||||||
name: customer-node
|
name: customer-node
|
||||||
spec:
|
spec:
|
||||||
ports:
|
ports:
|
||||||
- port: 443
|
- port: 8080
|
||||||
protocol: TCP
|
protocol: TCP
|
||||||
targetPort: 443
|
targetPort: 8080
|
||||||
selector:
|
selector:
|
||||||
app: customer-node
|
app: customer-node
|
||||||
sessionAffinity: None
|
sessionAffinity: None
|
||||||
|
|
|
@ -23,4 +23,4 @@ spec:
|
||||||
service:
|
service:
|
||||||
name: customer-node
|
name: customer-node
|
||||||
port:
|
port:
|
||||||
number: 443
|
number: 8080
|
||||||
|
|
Loading…
Add table
Reference in a new issue