Skip to content

Commit

Permalink
Repo-sync
Browse files Browse the repository at this point in the history
  • Loading branch information
GitHub Workflow committed Dec 6, 2023
1 parent 32f56fd commit 68134e6
Show file tree
Hide file tree
Showing 40 changed files with 258 additions and 96 deletions.
3 changes: 3 additions & 0 deletions Containers/apache/nextcloud.conf
Original file line number Diff line number Diff line change
Expand Up @@ -49,4 +49,7 @@ Listen 8000

# See https://httpd.apache.org/docs/current/mod/mod_proxy.html#proxytimeout
ProxyTimeout ${APACHE_MAX_TIME}

# See https://httpd.apache.org/docs/trunk/mod/core.html#traceenable
TraceEnable Off
</VirtualHost>
2 changes: 1 addition & 1 deletion Containers/borgbackup/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM alpine:3.18.4
FROM alpine:3.18.5

RUN set -ex; \
\
Expand Down
2 changes: 1 addition & 1 deletion Containers/clamav/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Probably from this file: https://github.com/Cisco-Talos/clamav-docker/blob/main/clamav/1.1/alpine/Dockerfile
FROM clamav/clamav:1.2.1-16
FROM clamav/clamav:1.2.1-20

COPY clamav.conf /tmp/clamav.conf

Expand Down
2 changes: 1 addition & 1 deletion Containers/docker-socket-proxy/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM haproxy:2.8.4-alpine3.18
FROM haproxy:2.9.0-alpine3.18

# hadolint ignore=DL3002
USER root
Expand Down
2 changes: 1 addition & 1 deletion Containers/domaincheck/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM alpine:3.18.4
FROM alpine:3.18.5
RUN set -ex; \
apk add --no-cache bash lighttpd netcat-openbsd; \
adduser -S www-data -G www-data; \
Expand Down
6 changes: 3 additions & 3 deletions Containers/imaginary/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
FROM golang:1.21.4-alpine3.18 as go
FROM golang:1.21.5-alpine3.18 as go

ENV IMAGINARY_HASH 7efb66c243056e5b3b65215e101be7915983e364
ENV IMAGINARY_HASH 6cd9edd1d3fb151eb773c14552886e4fc8e50138

RUN set -ex; \
apk add --no-cache \
Expand All @@ -12,7 +12,7 @@ RUN set -ex; \
build-base; \
go install github.com/h2non/imaginary@"$IMAGINARY_HASH";

FROM alpine:3.18.4
FROM alpine:3.18.5
RUN set -ex; \
apk add --no-cache \
tzdata \
Expand Down
2 changes: 1 addition & 1 deletion Containers/mastercontainer/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ FROM docker:24.0.7-cli as docker
FROM caddy:2.7.5-alpine as caddy

# From https://github.com/docker-library/php/blob/master/8.2/alpine3.18/fpm/Dockerfile
FROM php:8.2.12-fpm-alpine3.18
FROM php:8.2.13-fpm-alpine3.18

EXPOSE 80
EXPOSE 8080
Expand Down
6 changes: 6 additions & 0 deletions Containers/mastercontainer/mastercontainer.conf
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,14 @@ Listen 8080
SSLCertificateFile /etc/apache2/certs/ssl.crt
SSLEngine on
SSLProtocol -all +TLSv1.2 +TLSv1.3
SSLCipherSuite ECDHE-ECDSA-AES128-GCM-SHA256:ECDHE-RSA-AES128-GCM-SHA256:ECDHE-ECDSA-AES256-GCM-SHA384:ECDHE-RSA-AES256-GCM-SHA384:ECDHE-ECDSA-CHACHA20-POLY1305:ECDHE-RSA-CHACHA20-POLY1305:DHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES256-GCM-SHA384:DHE-RSA-CHACHA20-POLY1305
SSLHonorCipherOrder off
SSLSessionTickets off
</VirtualHost>

# Increase timeout in case e.g. the initial download takes a long time
Timeout 7200
ProxyTimeout 7200

# See https://httpd.apache.org/docs/trunk/mod/core.html#traceenable
TraceEnable Off
2 changes: 1 addition & 1 deletion Containers/nextcloud/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM php:8.1.25-fpm-alpine3.18
FROM php:8.1.26-fpm-alpine3.18

ENV PHP_MEMORY_LIMIT 512M
ENV PHP_UPLOAD_LIMIT 10G
Expand Down
15 changes: 14 additions & 1 deletion Containers/nextcloud/cron.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,20 @@
#!/bin/bash
set -eu

wait_for_cron() {
set -x
while [ -n "$(pgrep -f /var/www/html/cron.php)" ]; do
echo "Waiting for cron to stop..."
sleep 5
done
echo "Cronjob successfully exited."
set +x
}

trap wait_for_cron SIGINT SIGTERM

while true; do
php -f /var/www/html/cron.php &
sleep 5m
sleep 5m &
wait $!
done
4 changes: 1 addition & 3 deletions Containers/nextcloud/entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -478,6 +478,7 @@ php /var/www/html/occ config:system:set updatedirectory --value="/nc-updater"

# Apply network settings
echo "Applying network settings..."
php /var/www/html/occ config:system:set allow_local_remote_servers --type=bool --value=true
php /var/www/html/occ config:system:set davstorage.request_timeout --value="$PHP_MAX_TIME" --type=int
php /var/www/html/occ config:system:set trusted_domains 1 --value="$NC_DOMAIN"
php /var/www/html/occ config:system:set overwrite.cli.url --value="https://$NC_DOMAIN/"
Expand Down Expand Up @@ -531,8 +532,6 @@ if [ "$COLLABORA_ENABLED" = 'yes' ]; then
php /var/www/html/occ app:update richdocuments
fi
php /var/www/html/occ config:app:set richdocuments wopi_url --value="https://$NC_DOMAIN/"
# Fix https://github.com/nextcloud/all-in-one/issues/188:
php /var/www/html/occ config:system:set allow_local_remote_servers --type=bool --value=true
# Make collabora more save
COLLABORA_IPv4_ADDRESS="$(dig "$NC_DOMAIN" A +short +search | grep '^[0-9.]\+$' | sort | head -n1)"
COLLABORA_IPv6_ADDRESS="$(dig "$NC_DOMAIN" AAAA +short +search | grep '^[0-9a-f:]\+$' | sort | head -n1)"
Expand Down Expand Up @@ -596,7 +595,6 @@ if [ "$ONLYOFFICE_ENABLED" = 'yes' ]; then
php /var/www/html/occ config:app:set onlyoffice jwt_secret --value="$ONLYOFFICE_SECRET"
php /var/www/html/occ config:system:set onlyoffice jwt_header --value="AuthorizationJwt"
php /var/www/html/occ config:app:set onlyoffice DocumentServerUrl --value="https://$NC_DOMAIN/onlyoffice"
php /var/www/html/occ config:system:set allow_local_remote_servers --type=bool --value=true
else
if [ "$REMOVE_DISABLED_APPS" = yes ] && [ -d "/var/www/html/custom_apps/onlyoffice" ] && [ -n "$ONLYOFFICE_SECRET" ] && [ "$(php /var/www/html/occ config:system:get onlyoffice jwt_secret)" = "$ONLYOFFICE_SECRET" ]; then
php /var/www/html/occ app:remove onlyoffice
Expand Down
6 changes: 2 additions & 4 deletions Containers/nextcloud/run-exec-commands.sh
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
#!/bin/bash

while ! nc -z "$NC_DOMAIN" 443; do
sleep 5
done
sleep 10
# Wait 15s for domain to be reachable
sleep 15

if [ -n "$NEXTCLOUD_EXEC_COMMANDS" ]; then
echo "#!/bin/bash" > /tmp/nextcloud-exec-commands
Expand Down
2 changes: 1 addition & 1 deletion Containers/notify-push/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM alpine:3.18.4
FROM alpine:3.18.5

COPY --chmod=775 start.sh /start.sh
COPY --chmod=775 healthcheck.sh /healthcheck.sh
Expand Down
5 changes: 5 additions & 0 deletions Containers/notify-push/start.sh
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,11 @@ if ! [ -f /nextcloud/custom_apps/notify_push/bin/"$CPU_ARCH"/notify_push ]; then
exit 1
fi

# Add a timeout of 15s to hopefully get rid of the first error that is logged if apache is not there yet
sleep 15

echo "notify-push was started"

# Set sensitive values as env
export DATABASE_URL="postgres://$POSTGRES_USER:$POSTGRES_PASSWORD@$POSTGRES_HOST/$POSTGRES_DB"
export REDIS_URL="redis://:$REDIS_HOST_PASSWORD@$REDIS_HOST"
Expand Down
6 changes: 3 additions & 3 deletions Containers/talk/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
FROM nats:2.10.5-scratch as nats
FROM nats:2.10.6-scratch as nats
FROM eturnal/eturnal:1.12.0 AS eturnal
FROM strukturag/nextcloud-spreed-signaling:1.2.1 as signaling
FROM alpine:3.18.4 as janus
FROM alpine:3.18.5 as janus

ARG JANUS_VERSION=v0.14.0
WORKDIR /src
Expand Down Expand Up @@ -33,7 +33,7 @@ RUN set -ex; \
make configs; \
rename -v ".jcfg.sample" ".jcfg" /usr/local/etc/janus/*.jcfg.sample

FROM alpine:3.18.4
FROM alpine:3.18.5
ENV ETURNAL_ETC_DIR="/conf"
COPY --from=janus --chmod=777 --chown=1000:1000 /usr/local /usr/local
COPY --from=eturnal --chmod=777 --chown=1000:1000 /opt/eturnal /opt/eturnal
Expand Down
2 changes: 1 addition & 1 deletion Containers/watchtower/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
# From https://github.com/containrrr/watchtower/blob/main/dockerfiles/Dockerfile.self-contained
FROM containrrr/watchtower:1.7.1 as watchtower

FROM alpine:3.18.4
FROM alpine:3.18.5

RUN apk add --no-cache bash
COPY --from=watchtower /watchtower /watchtower
Expand Down
3 changes: 2 additions & 1 deletion community-containers/caddy/readme.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
## Caddy with geoblocking
This container bundles caddy and auto-configures it for you. It also covers https://github.com/nextcloud/all-in-one/tree/main/community-containers/vaultwarden by listening on `bw.$NC_DOMAIN`, if installed.
This container bundles caddy and auto-configures it for you. It also covers https://github.com/nextcloud/all-in-one/tree/main/community-containers/vaultwarden by listening on `bw.$NC_DOMAIN`, if installed. It also covers https://github.com/nextcloud/all-in-one/tree/main/community-containers/stalwart by listening on `mail.$NC_DOMAIN`, if installed.

### Notes
- This container is incompatible with the [npmplus](https://github.com/nextcloud/all-in-one/tree/main/community-containers/npmplus) community container. So make sure that you do not enable both at the same time!
- Make sure that no other service is using port 443 on your host as otherwise the containers will fail to start. You can check this with `sudo netstat -tulpn | grep 443` before installing AIO.
- If you want to use this with https://github.com/nextcloud/all-in-one/tree/main/community-containers/vaultwarden, make sure that you point `bw.your-nc-domain.com` to your server using a cname record so that caddy can get a certificate automatically for vaultwarden.
- If you want to use this with https://github.com/nextcloud/all-in-one/tree/main/community-containers/stalwart, make sure that you point `mail.your-nc-domain.com` to your server using a cname record so that caddy can get a certificate automatically for stalwart.
- After the container was started the first time, you should see a new `nextcloud-aio-caddy` folder and inside there an `allowed-countries.txt` file when you open the files app with the default `admin` user. In there you can adjust the allowed country codes for caddy by adding them to the first line, e.g. `IT FR` would allow access from italy and france. Private ip-ranges are always allowed. Additionally, in order to activate this config, you need to get an account at https://dev.maxmind.com/geoip/geolite2-free-geolocation-data and download the `GeoLite2-Country.mmdb` and upload it with this exact name into the `nextcloud-aio-caddy` folder. Afterwards restart all containers from the AIO interface and your new config should be active!
- See https://github.com/nextcloud/all-in-one/tree/main/community-containers#community-containers how to add it to the AIO stack

Expand Down
17 changes: 17 additions & 0 deletions community-containers/stalwart/readme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
## Stalwart mail server
This container bundles stalwart mail server and auto-configures it for you.

### Notes
- This is only intended to run on a VPS with static ip-address.
- Check with `sudo netstat -tulpn` that no other service is using port 25, 143, 465, 578, 993 nor 4190 yet as otherwise the container will fail to start.
- You need to configure a reverse proxy in order to run this container since stalwart needs a dedicated (sub)domain! For that, you might have a look at https://github.com/nextcloud/all-in-one/tree/main/community-containers/caddy.
- Currently, only `mail.$NC_DOMAIN` is supported as subdomain! So if Nextcloud is using `your-domain.com`, vaultwarden will use `mail.your-domain.com`.
- The data of Stalwart will be automatically included in AIOs backup solution!
- After adding and starting the container, you need to run `sudo docker exec -it nextcloud-aio-stalwart configure.sh` and follow https://stalw.art/docs/install/docker/#choose-where-to-store-your-data (1. choose `Local disk`, 2. choose `No, create a new directory for me`, 3. type in your `$NC_DOMAIN` as `domain name` and `mail.$NC_DOMAIN` as `server hostname`. 4. add `DKIM, SPF and DMARC` as advised, 5. Take note of the administrator credentials, 6. skip https://stalw.art/docs/install/docker/#add-your-tls-certificate as this is done automatically for you, 7. Review the configuration file, 8. run `sudo docker restart nextcloud-aio-stalwart` in order restart the container and enable the config).
- See https://github.com/nextcloud/all-in-one/tree/main/community-containers#community-containers how to add it to the AIO stack

### Repository
https://github.com/marcoambrosini/aio-stalwart

### Maintainer
https://github.com/marcoambrosini
64 changes: 64 additions & 0 deletions community-containers/stalwart/stalwart.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
{
"aio_services_v1": [
{
"container_name": "nextcloud-aio-stalwart",
"display_name": "Stalwart",
"documentation": "https://github.com/nextcloud/all-in-one/tree/main/community-containers/stalwart",
"image": "marcoambrosini/aio-stalwart",
"image_tag": "v1",
"internal_port": "587",
"restart": "unless-stopped",
"ports": [
{
"ip_binding": "",
"port_number": "25",
"protocol": "tcp"
},
{
"ip_binding": "",
"port_number": "143",
"protocol": "tcp"
},
{
"ip_binding": "",
"port_number": "465",
"protocol": "tcp"
},
{
"ip_binding": "",
"port_number": "587",
"protocol": "tcp"
},
{
"ip_binding": "",
"port_number": "993",
"protocol": "tcp"
},
{
"ip_binding": "",
"port_number": "4190",
"protocol": "tcp"
}
],
"environment": [
"TZ=%TIMEZONE%",
"NC_DOMAIN=%NC_DOMAIN"
],
"volumes": [
{
"source": "nextcloud_aio_stalwart",
"destination": "/opt/stalwart-mail",
"writeable": true
},
{
"source": "nextcloud_aio_caddy",
"destination": "/caddy",
"writeable": false
}
],
"backup_volumes": [
"nextcloud_aio_stalwart"
]
}
]
}
2 changes: 1 addition & 1 deletion nextcloud-aio-helm-chart/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: nextcloud-aio-helm-chart
description: A generated Helm Chart for Nextcloud AIO from Skippbox Kompose
version: 7.7.1-dev3
version: 7.7.1
apiVersion: v2
keywords:
- latest
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ spec:
value: nextcloud-aio-talk
- name: TZ
value: "{{ .Values.TIMEZONE }}"
image: nextcloud/aio-apache:20231123_084113-latest
image: nextcloud/aio-apache:20231130_081302-latest
name: nextcloud-aio-apache
ports:
- containerPort: {{ .Values.APACHE_PORT }}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ spec:
value: "90"
- name: TZ
value: "{{ .Values.TIMEZONE }}"
image: nextcloud/aio-clamav:20231123_084113-latest
image: nextcloud/aio-clamav:20231130_081302-latest
name: nextcloud-aio-clamav
ports:
- containerPort: 3310
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,13 @@ spec:
value: --o:ssl.enable=false --o:ssl.termination=true --o:mount_jail_tree=false --o:logging.level=warning --o:home_mode.enable=true {{ .Values.COLLABORA_SECCOMP_POLICY }} --o:remote_font_config.url=https://{{ .Values.NC_DOMAIN }}/apps/richdocuments/settings/fonts.json
- name: server_name
value: "{{ .Values.NC_DOMAIN }}"
image: nextcloud/aio-collabora:20231123_084113-latest
image: nextcloud/aio-collabora:20231130_081302-latest
name: nextcloud-aio-collabora
ports:
- containerPort: 9980
protocol: TCP
securityContext:
capabilities:
add:
- MKNOD
{{- end }}
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ spec:
value: nextcloud
- name: TZ
value: "{{ .Values.TIMEZONE }}"
image: nextcloud/aio-postgresql:20231123_084113-latest
image: nextcloud/aio-postgresql:20231130_081302-latest
name: nextcloud-aio-database
ports:
- containerPort: 5432
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ spec:
value: basic
- name: xpack.security.enabled
value: "false"
image: nextcloud/aio-fulltextsearch:20231123_084113-latest
image: nextcloud/aio-fulltextsearch:20231130_081302-latest
name: nextcloud-aio-fulltextsearch
ports:
- containerPort: 9200
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ spec:
- env:
- name: TZ
value: "{{ .Values.TIMEZONE }}"
image: nextcloud/aio-imaginary:20231123_084113-latest
image: nextcloud/aio-imaginary:20231130_081302-latest
name: nextcloud-aio-imaginary
ports:
- containerPort: 9000
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,17 @@ spec:
io.kompose.service: nextcloud-aio-nextcloud
spec:
initContainers:
- name: delete lost+found
image: alpine
command:
- rm
- "-rf"
- /nextcloud-aio-nextcloud/lost+found
volumeMounts:
- name: nextcloud-aio-nextcloud-trusted-cacerts
mountPath: /nextcloud-aio-nextcloud-trusted-cacerts
- name: nextcloud-aio-nextcloud
mountPath: /nextcloud-aio-nextcloud
- name: init-volumes
image: alpine
command:
Expand Down Expand Up @@ -145,8 +156,7 @@ spec:
value: "{{ .Values.TIMEZONE }}"
- name: UPDATE_NEXTCLOUD_APPS
value: "{{ .Values.UPDATE_NEXTCLOUD_APPS }}"
image: nextcloud/aio-nextcloud:develop
imagePullPolicy: Always
image: nextcloud/aio-nextcloud:20231130_081302-latest
name: nextcloud-aio-nextcloud
ports:
- containerPort: 9000
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ spec:
value: nextcloud-aio-redis
- name: REDIS_HOST_PASSWORD
value: "{{ .Values.REDIS_PASSWORD }}"
image: nextcloud/aio-notify-push:20231123_084113-latest
image: nextcloud/aio-notify-push:20231130_081302-latest
name: nextcloud-aio-notify-push
ports:
- containerPort: 7867
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ spec:
value: "{{ .Values.ONLYOFFICE_SECRET }}"
- name: TZ
value: "{{ .Values.TIMEZONE }}"
image: nextcloud/aio-onlyoffice:20231123_084113-latest
image: nextcloud/aio-onlyoffice:20231130_081302-latest
name: nextcloud-aio-onlyoffice
ports:
- containerPort: 80
Expand Down
Loading

0 comments on commit 68134e6

Please sign in to comment.