-
Install Docker.
-
Install Docker Compose.
-
Install Rancher CLI
In order to be able to edit source-code on your machine using your favorite editor, without having to do it inside a Docker container, you'll have to create a new user on your laptop with uid=500 and use this user for development:
$ sudo useradd -u 500 zope-www
$ sudo usermod -a -G docker zope-www
$ sudo su - zope-www
-
Get the source code:
$ git clone https://github.com/eea/eea.docker.wise.git $ cd eea.docker.wise/wise-devel -
Update development stack:
$ git pull $ docker-compose -f source-code.yml up $ docker-compose pull -
Start development stack:
$ docker-compose up -d -
Start Plone in foreground:
$ docker-compose exec plone bin/instance fg -
Within your favorite browser head to http://localhost:8080, add a Plone site and install the following add-ons:
EEA Plone buildout profilewise.themewise.content
Go to Home, select the Contents tab and delete all the contents.
Then go to portal_setup and import from wise.content (extra). -
Now you are ready to develop Plone Add-ons within
srcfolder:$ ls -l src/ -
You can do normal Plone development, including setting breakpoints with
ipdb
- Rancher CLI
- Within Rancher UI register min 1 hosts with label:
wise=yes
On your laptop:
$ git clone https://github.com/eea/eea.docker.wise.git
$ cd eea.docker.wise
To enable Rancher CLI to launch services in a Rancher instance, you’ll need to configure it See related Rancher documentation on how to obtain your Rancher API Keys. Thus:
-
Via Rancher UI:
- Go to API Tab add an Account API Key
-
On your laptop configure Rancher CLI:
$ rancher config -
Make sure that you're deploying within the right environment:
$ rancher config -p
$ rancher up -d
$ rancher up -d --upgrade --batch-size 1
...and confirm that the upgrade went well:
$ rancher up -d --confirm-upgrade
...or roll-back:
$ rancher up -d --roll-back