Giter Club home page Giter Club logo

fdbx's Introduction

moodle

Docker scripts that install and run Moodle in a container.

Install

  • First install ds and wsproxy:

  • Then get the moodle scripts from github: ds pull moodle

  • Create a directory for the moodle container: ds init moodle @moodle1-example-org

  • Fix the settings:

    cd /var/ds/moodle1-example-org/
    vim settings.sh
    ds info
    
  • Create the container and install Moodle: ds make

    Note: This will pull the image from DockerHub. To build the image yourself use ds build first, however this is usually slower.

Access the website

If the domain is a real one, tell wsproxy to get a free letsencrypt.org SSL certificate for it:

ds wsproxy ssl-cert --test
ds wsproxy ssl-cert

If the domain is not a real one, add to /etc/hosts the line 127.0.0.1 moodle1.example.org

Now you can access the website at: https://moodle1.example.org

Other commands

ds shell
ds stop
ds start
ds help

Backup and restore

ds backup
ds backup +data
ds restore backup-file.tgz

Clone

ds clone tag
ds clone-del tag

Cloning will create a new installation inside the same container. It will copy /var/www/moodle to /var/www/moodle_tag, moodledata to moodledata_tag, dbname to dbname_tag, etc. and make sure that the new installation can be accessed on https://tag.moodle1.example.org

Update and upgrade

To update the current stable branch (for example from 3.3.1 to 3.3.2) use ds update. This is done quite frequently and usually has no risks of breaking anything.

To upgrade to the next stable branch (for example from 3.2 to 3.3) use ds upgrade moodle MOODLE_33_STABLE. It will try to upgrade the additional plugins as well, if they have a version that matches the latest moodle release. However this does not always work and some plugins may need to be fixed manually.

Since the upgrade process may be faced with some problems to be solved, it is better to try it first on a test site, and after making sure that everything works correctly, apply it to the real site. This can be done like this:

ds clone test
ds upgrade moodle_test MOODLE_33_STABLE

# make sure that everything works and fix any problems

ds upgrade moodle MOODLE_33_STABLE
ds clone-del test

Both update and upgrade make a backup before making any changes, just in case.

Remake

The command ds remake rebuilds everything from scratch, but preserves the existing database and data files.

fdbx's People

Watchers

raden 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.