add: nextcloud

This commit is contained in:
eneller
2023-09-28 12:30:56 +02:00
commit 2e2ca46c0d
5 changed files with 107 additions and 0 deletions

View File

@@ -0,0 +1,40 @@
This footer comes on public shares (share-links) and consists of
the simple signup link that can be disabled with the config variable
'simpleSignUpLink.shown' => false,
in config.php
and
the part that you can manipulate yourself with the theming app.
If you want to remove the footer COMPLETELY, you must manipulate the file:
lib/public/AppFramework/Http/Template/PublicTemplateResponse.php
where you have to change the line 39:
private $footerVisible = true;
in
private $footerVisible = false;
You can do that with this sed command, where variable NC_DIR must be assigned to the path of your installation first:
NC_DIR="/var/www/nextcloud"
Completely remove footer:
sudo sed -i 's/private \$footerVisible = true;$/private \$footerVisible = false;/1' $NC_DIR/lib/public/AppFramework/Http/Template/PublicTemplateResponse.php
Make footer visible (default):
sudo sed -i 's/private \$footerVisible = false;$/private \$footerVisible = true;/1' $NC_DIR/lib/public/AppFramework/Http/Template/PublicTemplateResponse.php
You need both, to reset it to the default, when you want to run intigrety checks. After that you can switch it back.
Hope that helps,
much luck!

View File

@@ -0,0 +1,21 @@
services:
db:
image: mariadb:10.6
restart: always
command: --transaction-isolation=READ-COMMITTED --binlog-format=ROW
volumes:
- ./db:/var/lib/mysql
env_file:
- env
app:
image: nextcloud:27
restart: always
ports:
- 50000:80
links:
- db
volumes:
- ./nextcloud:/var/www/html
env_file:
- env

6
nextcloud/env.example Normal file
View File

@@ -0,0 +1,6 @@
MYSQL_DATABASE=nextcloud
MYSQL_USER=nextcloud
MYSQL_HOST=db
# set these
MARIADB_ROOT_PASSWORD=
MYSQL_PASSWORD=

38
nextcloud/nextcloud.conf Normal file
View File

@@ -0,0 +1,38 @@
server {
server_name cloud.example.com;
add_header Strict-Transport-Security "max-age=15552000; includeSubDomains; preload";
location / {
proxy_pass "http://127.0.0.1:50000/";
proxy_set_header Host $http_host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Scheme $scheme;
proxy_set_header X-Forwarded-Proto $scheme;
client_max_body_size 0;
}
listen [::]:443 ssl ipv6only=on; # managed by Certbot
listen 443 ssl; # managed by Certbot
ssl_certificate /etc/letsencrypt/live/cloud.example.com/fullchain.pem; # managed by Certbot
ssl_certificate_key /etc/letsencrypt/live/cloud.example.com/privkey.pem; # managed by Certbot
include /etc/letsencrypt/options-ssl-nginx.conf; # managed by Certbot
ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; # managed by Certbot
}
server {
if ($host = cloud.example.com) {
return 301 https://$host$request_uri;
} # managed by Certbot
server_name cloud.example.com;
listen [::]:80;
listen 80 ;
return 404; # managed by Certbot
}
~

2
nextcloud/nextcloud.cron Normal file
View File

@@ -0,0 +1,2 @@
*/5 * * * * docker exec -u www-data nextcloud-app-1 php -f /var/www/html/cron.php