Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Next revisionBoth sides next revision
docker_notes:docker-dokuwiki [2023-05-20 Sat wk20 16:28] – [Nextcloud Container] baumkpdocker_notes:docker-dokuwiki [2023-05-30 Tue wk22 19:46] – [Deluge] baumkp
Line 96: Line 96:
     * Nginxproxymanager.com [[https://nginxproxymanager.com/advanced-config/#best-practice-use-a-docker-network|Best Practice: Use a Docker network]]     * Nginxproxymanager.com [[https://nginxproxymanager.com/advanced-config/#best-practice-use-a-docker-network|Best Practice: Use a Docker network]]
  
 +====ssl certificates====
 +  *''openssl x509 -in (path to certificate and certificate filename) -text -noout''
 +  *''openssl s_client -connect localhost:443 2>/dev/null | openssl x509 -noout -dates''
 +  *[[https://www.techrepublic.com/article/how-to-utilize-openssl-in-linux-to-check-ssl-certificate-details/|How to utilize openssl in Linux to check SSL certificate details]]
 +
 +====Export Traefik certificates====
 +
 +  *[[https://r4uch.com/export-traefik-certificates/|Export Traefik Certificates]]
 +  *Need to install the jq package
 +<code bash>#!/bin/bash
 +
 +# Requirements: you will need to install jq and maybe openssl
 +
 +# creates a directory for all of your certificates
 +mkdir -p certificates/
 +
 +# reads the acme.json file, please put this file in the same directory as your script
 +json=$(cat acme.json)
 +
 +export_cer_key () {
 +    echo $json | jq -r '.[].Certificates[] | select(.domain.main == "'$1'") | .certificate' | base64 -d > certificates/$1.cer
 +    echo $json | jq -r '.[].Certificates[] | select(.domain.main == "'$1'") | .key' | base64 -d > certificates/$1.key
 +}
 +
 +export_pfx () {
 +        openssl pkcs12 -export -out certificates/$domain.pfx -inkey certificates/$domain.key -in certificates/$domain.cer -passout pass: 
 +}
 +
 +read -p "Do you want to export as .pfx file as well [y]?" REPLY
 +
 +# iterates through all of your domains
 +for domain in $(echo $json | jq -r '.[].Certificates[].domain.main')
 +do
 +    if [[ $REPLY =~ ^[Yy]$ ]]
 +    then
 +        export_cer_key "$domain"
 +        export_pfx "$domain"
 +    else
 +        export_cer_key "$domain"
 +    fi
 +done</code>
 +There is also [[https://techoverflow.net/2021/07/18/how-to-export-certificates-from-traefik-certificate-store/|How to export certificates from Traefik certificate store]] in python.
  
 =====Dokuwiki===== =====Dokuwiki=====
Line 147: Line 189:
  
 Refer to Nextcloud's [[https://docs.nextcloud.com/server/latest/admin_manual/maintenance/index.html|Maintenace]] section on instructions to backup, restore and migrate Nextcloud.  Also as I am using the official Nextcloud container it has additional instructions to [[https://github.com/docker-library/docs/blob/master/nextcloud/README.md#migrating-an-existing-installation:migrate]] Nextcloud to Docker. Refer to Nextcloud's [[https://docs.nextcloud.com/server/latest/admin_manual/maintenance/index.html|Maintenace]] section on instructions to backup, restore and migrate Nextcloud.  Also as I am using the official Nextcloud container it has additional instructions to [[https://github.com/docker-library/docs/blob/master/nextcloud/README.md#migrating-an-existing-installation:migrate]] Nextcloud to Docker.
 +  * uid: www-data / 33, gid: www-data / 33.  This seems to be Debian standard. Alpine linux seems to use 82 for www-data.  Just stick with uid/gid as per the image supplied, 82 for Alpine and ignore the names.
 +  * ''docker exec -u www-data nextcloud-app-1 php /var/www/html/cron.php'' runs the cron.php
 +  * ''docker exec -u www-data nextcloud-app-1 php occ maintenance:mode --off|on'' to turn maintenance mode off or on from the containers host shell
 +
 +====RedirectRegex====
 +I get a redirect error in Nextcloud that I have not been able to track down to date.  Does not seem much info in this on the net, and the little there is also indicates a problem without and easy solution.  Nextcloud main support looks Apache web server based with little Nginx support and even less Traefik support.
 +Some resources related to this:
 +  *Traefik: 
 +    *[[https://doc.traefik.io/traefik/middlewares/http/redirectregex/#permanent|RedirectRegex]]
 +    *[[https://doc.traefik.io/traefik/middlewares/http/replacepathregex/|ReplacePathRegex]]
 +    *[[https://github.com/traefik/traefik/issues/723|Multiple entry regex redirects #723 ]
 +====References====
 +  *docs nextcloud
 +    * [[https://docs.nextcloud.com/server/stable/admin_manual/configuration_server/config_sample_php_parameters.html#default-parameters|Configuration Parameters]]
 +    *[[https://help.nextcloud.com/t/is-there-a-safe-and-reliable-way-to-move-data-directory-out-of-web-root/3642|is-there-a-safe-and-reliable-way-to-move-data-directory-out-of-web-root]]
 +    *[[https://help.nextcloud.com/t/howto-change-move-data-directory-after-installation/17170|help.nextcloud.com/t/howto-change-move-data-directory-after-installation]]
 +    *[[https://github.com/nextcloud|github.com/nextcloud]]
 +    *[[https://hub.docker.com/_/nextcloud/| Docker Hub Nextcloud]]
 +    *[[https://github.com/docker-library/docs/blob/master/nextcloud/README.md|Github Docker Hub Nextcloud]]
 +
 +====Installing and Using MariaDB via Docker====
 +[[https://mariadb.com/kb/en/installing-and-using-mariadb-via-docker/|Installing and Using MariaDB via Docker]]
 +[[]]
 +
 +====logging====
 +[[https://docs.nextcloud.com/server/latest/admin_manual/configuration_server/logging_configuration.html|Nextcloud configuration Logging]]
 +====backup====
 +[[https://docs.nextcloud.com/server/stable/admin_manual/maintenance/backup.html|Backup]]
 +
 +====NGINX configuration====
 +[[https://docs.nextcloud.com/server/25/admin_manual/installation/nginx.html|NGINX configuration]]
 +
 +====cron====
 +''docker-compose exec -u www-data nextcloud php cron.php'' to run cron in Nextcloud Docker
 +[[https://help.nextcloud.com/t/nextcloud-docker-container-best-way-to-run-cron-job/157734|https://help.nextcloud.com/t/nextcloud-docker-container-best-way-to-run-cron-job/157734]]
 +
  
 =====Calibre===== =====Calibre=====
Line 250: Line 328:
   *Christain Lempa [[https://github.com/ChristianLempa/boilerplates/blob/main/docker-compose/nextcloud/nextcloud.yaml| boilerplates/docker-compose/nextcloud/nextcloud.yaml]]   *Christain Lempa [[https://github.com/ChristianLempa/boilerplates/blob/main/docker-compose/nextcloud/nextcloud.yaml| boilerplates/docker-compose/nextcloud/nextcloud.yaml]]
  
-=====Deluge===== 
-A torrent application with a web based server.  I will probably need to fully build this one myself as I use a VPN with fire wall that only allows communication on LAN or using firewall tunnel for WAN. 
  
 =====Other Possible Apps/Images===== =====Other Possible Apps/Images=====