Code Monkey home page Code Monkey logo

nextcloud.docker's Introduction

nextcloud.docker

Install Nextcloud in docker with mariadb, redis, cron and caddy.

Create a self signed certificate

  1. Enter the folder caddy/certs

  2. Create a self signed certificate with this command

    openssl req -newkey rsa:4096 -x509 -sha512 -days 365 -nodes -out certificate.pem -keyout privatekey.pem

Edit docker-compose.yml and Caddyfile

  1. Set the port you want to use to access Nextcloud (in this example the port is 1201)

    In the docker-compose.yml file

    ports:
      - 1201:1201

    and in the caddy/Caddyfile

    :1201
    tls /etc/caddy/certificate.pem /etc/caddy/privatekey.pem
    reverse_proxy nextcloud:80
    
  2. Set the database and redis passwords

  3. Change the memory limits to something that suits your needs

    mem_limit: "256M"

  4. Set the local folder you want to use for the Nextcloud data (both in nextcloud and in cron)

    - /mnt/Volume/nextcloud/:/var/www/html/data

  5. Set the domain name from which you'll access nextcloud (if you are using a service like dynds add dyndns.org or the domain you are using)

    - NEXTCLOUD_TRUSTED_DOMAINS=$YOUR_DOMAIN$

    If you want to access Nextcloud only from localhost you can remove the line.

Create and start the containers

Use this command to create and start all the containers

docker compose up -d

Run occ commands

To run occ commands

docker exec -ti --user www-data nextcloud /var/www/html/occ COMMAND

Update Nextcloud

To update Nextcloud to the most recent version:

docker compose down
docker compose pull nextcloud
docker compose up -d

nextcloud.docker's People

Contributors

sakya avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.