mirror of
https://github.com/hoellen/docker-nextcloud.git
synced 2025-07-01 07:36:08 +00:00
Compare commits
16 Commits
version-30
...
version-22
Author | SHA1 | Date | |
---|---|---|---|
3715ca5861 | |||
f44824f946 | |||
7e7c77ea75 | |||
5c9c873713 | |||
eeac6d79d9 | |||
c0229eabd6 | |||
7240120ac3 | |||
1a61a40cad | |||
90381a94d0 | |||
0b0a1da864 | |||
2bfc5e0eec | |||
d2861829ac | |||
e72b5f41c7 | |||
a5d934b8a9 | |||
8c9f6b6cb7 | |||
9867cd0938 |
24
.github/workflows/build.yml
vendored
24
.github/workflows/build.yml
vendored
@ -3,10 +3,10 @@ name: build
|
|||||||
on:
|
on:
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
push:
|
push:
|
||||||
branches: [ main ]
|
branches: [ version-22 ]
|
||||||
schedule:
|
schedule:
|
||||||
# Build the image regularly (each Friday)
|
# Build the image regularly (each Friday)
|
||||||
- cron: '13 23 * * 5'
|
- cron: '23 04 * * 5'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
@ -19,25 +19,24 @@ jobs:
|
|||||||
- name: Build an image from Dockerfile
|
- name: Build an image from Dockerfile
|
||||||
run: |
|
run: |
|
||||||
docker build \
|
docker build \
|
||||||
-t ghcr.io/hoellen/nextcloud \
|
-t ghcr.io/${{ github.actor }}/nextcloud:$(grep -oP '(?<=NEXTCLOUD_VERSION=).*' Dockerfile | head -c6) \
|
||||||
-t ghcr.io/hoellen/nextcloud:$(grep -oP '(?<=NEXTCLOUD_VERSION=).*' Dockerfile | head -c6) \
|
-t ghcr.io/${{ github.actor }}/nextcloud:$(grep -oP '(?<=NEXTCLOUD_VERSION=).*' Dockerfile | head -c2) \
|
||||||
-t ghcr.io/hoellen/nextcloud:$(grep -oP '(?<=NEXTCLOUD_VERSION=).*' Dockerfile | head -c2) \
|
|
||||||
.
|
.
|
||||||
|
|
||||||
- name: Run Trivy vulnerability scanner
|
- name: Run Trivy vulnerability scanner
|
||||||
uses: aquasecurity/trivy-action@master
|
uses: aquasecurity/trivy-action@master
|
||||||
with:
|
with:
|
||||||
image-ref: 'ghcr.io/hoellen/nextcloud'
|
image-ref: 'ghcr.io/${{ github.actor }}/nextcloud'
|
||||||
format: 'template'
|
format: 'template'
|
||||||
template: '@/contrib/sarif.tpl'
|
template: '@/contrib/sarif.tpl'
|
||||||
output: 'trivy-results.sarif'
|
output: 'trivy-results.sarif'
|
||||||
severity: 'CRITICAL,HIGH'
|
severity: 'CRITICAL,HIGH'
|
||||||
vuln-type: "os"
|
vuln-type: "os"
|
||||||
|
|
||||||
# - name: Upload Trivy scan results to GitHub Security tab
|
- name: Upload Trivy scan results to GitHub Security tab
|
||||||
# uses: github/codeql-action/upload-sarif@v1
|
uses: github/codeql-action/upload-sarif@v1
|
||||||
# with:
|
with:
|
||||||
# sarif_file: 'trivy-results.sarif'
|
sarif_file: 'trivy-results.sarif'
|
||||||
|
|
||||||
- name: Login to the registry
|
- name: Login to the registry
|
||||||
run: >-
|
run: >-
|
||||||
@ -46,6 +45,5 @@ jobs:
|
|||||||
|
|
||||||
- name: Push image to GitHub
|
- name: Push image to GitHub
|
||||||
run: |
|
run: |
|
||||||
docker push ghcr.io/hoellen/nextcloud
|
docker push ghcr.io/${{ github.actor }}/nextcloud:$(grep -oP '(?<=NEXTCLOUD_VERSION=).*' Dockerfile | head -c6)
|
||||||
docker push ghcr.io/hoellen/nextcloud:$(grep -oP '(?<=NEXTCLOUD_VERSION=).*' Dockerfile | head -c6)
|
docker push ghcr.io/${{ github.actor }}/nextcloud:$(grep -oP '(?<=NEXTCLOUD_VERSION=).*' Dockerfile | head -c2)
|
||||||
docker push ghcr.io/hoellen/nextcloud:$(grep -oP '(?<=NEXTCLOUD_VERSION=).*' Dockerfile | head -c2)
|
|
||||||
|
16
Dockerfile
16
Dockerfile
@ -1,9 +1,9 @@
|
|||||||
# -------------- Build-time variables --------------
|
# -------------- Build-time variables --------------
|
||||||
ARG NEXTCLOUD_VERSION=22.2.3
|
ARG NEXTCLOUD_VERSION=22.2.10
|
||||||
ARG PHP_VERSION=8.0
|
ARG PHP_VERSION=8.0
|
||||||
ARG NGINX_VERSION=1.20
|
ARG NGINX_VERSION=1.20
|
||||||
|
|
||||||
ARG ALPINE_VERSION=3.14
|
ARG ALPINE_VERSION=3.15
|
||||||
ARG HARDENED_MALLOC_VERSION=8
|
ARG HARDENED_MALLOC_VERSION=8
|
||||||
|
|
||||||
ARG UID=1000
|
ARG UID=1000
|
||||||
@ -28,6 +28,8 @@ RUN apk -U upgrade \
|
|||||||
libzip-dev \
|
libzip-dev \
|
||||||
openldap-dev \
|
openldap-dev \
|
||||||
postgresql-dev \
|
postgresql-dev \
|
||||||
|
samba-dev \
|
||||||
|
imagemagick-dev \
|
||||||
zlib-dev \
|
zlib-dev \
|
||||||
&& apk --no-cache add \
|
&& apk --no-cache add \
|
||||||
freetype \
|
freetype \
|
||||||
@ -38,7 +40,10 @@ RUN apk -U upgrade \
|
|||||||
libpq \
|
libpq \
|
||||||
libwebp \
|
libwebp \
|
||||||
libzip \
|
libzip \
|
||||||
|
libsmbclient \
|
||||||
openldap \
|
openldap \
|
||||||
|
libgomp \
|
||||||
|
imagemagick \
|
||||||
zlib \
|
zlib \
|
||||||
&& docker-php-ext-configure gd --with-freetype --with-jpeg --with-webp \
|
&& docker-php-ext-configure gd --with-freetype --with-jpeg --with-webp \
|
||||||
&& docker-php-ext-configure ldap \
|
&& docker-php-ext-configure ldap \
|
||||||
@ -54,9 +59,14 @@ RUN apk -U upgrade \
|
|||||||
pdo_pgsql \
|
pdo_pgsql \
|
||||||
zip \
|
zip \
|
||||||
gmp \
|
gmp \
|
||||||
|
&& pecl install smbclient \
|
||||||
&& pecl install APCu \
|
&& pecl install APCu \
|
||||||
&& pecl install redis \
|
&& pecl install redis \
|
||||||
&& echo "extension=redis.so" > /usr/local/etc/php/conf.d/redis.ini \
|
&& pecl install imagick \
|
||||||
|
&& docker-php-ext-enable \
|
||||||
|
smbclient \
|
||||||
|
redis \
|
||||||
|
imagick \
|
||||||
&& apk del build-deps \
|
&& apk del build-deps \
|
||||||
&& rm -rf /var/cache/apk/*
|
&& rm -rf /var/cache/apk/*
|
||||||
|
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
Nextcloud [official website](https://nextcloud.com/) and [source code](https://github.com/nextcloud).
|
Nextcloud [official website](https://nextcloud.com/) and [source code](https://github.com/nextcloud).
|
||||||
|
|
||||||
## Why this image?
|
## Why this image?
|
||||||
This non-official image is intended as an **all-in-one** (as in monolithic) Nextcloud **production** image. If you're not sure you want this image, you should probably use [the official image](https://hub.docker.com/r/nextcloud).
|
This non-official image is intended as an **all-in-one** (as in monolithic) Nextcloud **production** image. It is based on the [Wondefall/docker-nextcloud](https://github.com/Wonderfall/docker-nextcloud) image. If you're not sure you want this image, you should probably use [the official image](https://hub.docker.com/r/nextcloud).
|
||||||
|
|
||||||
## Security
|
## Security
|
||||||
Don't run random images from random dudes on the Internet. Ideally, you want to maintain and build it yourself.
|
Don't run random images from random dudes on the Internet. Ideally, you want to maintain and build it yourself.
|
||||||
|
@ -30,10 +30,10 @@ server {
|
|||||||
access_log off;
|
access_log off;
|
||||||
}
|
}
|
||||||
|
|
||||||
location /.well-known {
|
location ^~ /.well-known {
|
||||||
location = /.well-known/carddav { return 301 $nc_proto://$host:$nc_port/remote.php/dav; }
|
location = /.well-known/carddav { return 301 $nc_proto://$host/remote.php/dav; }
|
||||||
location = /.well-known/caldav { return 301 $nc_proto://$host:$nc_port/remote.php/dav; }
|
location = /.well-known/caldav { return 301 $nc_proto://$host/remote.php/dav; }
|
||||||
location ^~ /.well-known { return 301 $nc_proto://$host:$nc_port/index.php$uri; }
|
location ^~ /.well-known { return 301 $nc_proto://$host/index.php$uri; }
|
||||||
try_files $uri $uri/ =404;
|
try_files $uri $uri/ =404;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user