tkimnguyen
(T. Kim Nguyen)
January 31, 2020, 10:15pm
1
@Adomy you might find it easier and faster to run Plone on Windows via the Plone Docker image.
Once you install Docker Desktop for Windows (do not check the box that offers to assume using Windows containers):
docker run -p 8080:8080 plone
Then browse to http://localhost:8080
tkimnguyen
(T. Kim Nguyen)
January 31, 2020, 10:17pm
2
You can add add-ons too. See
Adomy
February 1, 2020, 2:48pm
3
Thanks Kim!
This is for all the information about Docker Desktop.
I will explore this area completely new to me.
Thanks again.
tkimnguyen
(T. Kim Nguyen)
February 3, 2020, 10:21pm
4
This is what I did to get the Plone Docker image working on a new PC:
Install Docker Desktop
Make sure not to check the box "Use Windows containers"
Make sure to allow the installer to enable Hyper-V
Open a CMD or PowerShell window
Type: docker run -p 8080:8080 plone fg
Wait a minute, then when things stop scrolling by, browse to http://localhost:8080
This is great for trying Plone, and even adding add-ons, and you can essentially ssh into the running Docker image and mess with buildout directly.
It is not how you should deploy for production, however, though others here have more experience deploying Plone via Docker containers.
1 Like
Adomy
February 4, 2020, 3:31pm
5
Thanks Kim,
Seen like this it is not the installation that should be a problem.
This is the daily use of Docker in the presence of other software due to incompatibility.
By the way, can you please give me directions, on deploying Plone via Docker containers?
Thanks in advance.
tkimnguyen
(T. Kim Nguyen)
February 4, 2020, 5:31pm
6
What I suggested Plone in Docker for was to:
try Plone locally if you have only a Windows machine available
try Plone add-ons locally
changing your buildout.cfg to try local development
What is the incompatibility you mention?
I don't know how to use the Plone Docker for deployment.
Most Plone deployment is done on Linux or Unix machines. In the past there were Windows Server deployments of Plone but very, very few Plone developers and integrators use Windows.
ericof
(Ericof)
February 4, 2020, 5:35pm
7
Does Docker Desktop runs on Windows 10 Home?
tkimnguyen
(T. Kim Nguyen)
February 4, 2020, 5:42pm
8
System Requirements
Windows 10 64-bit: Pro, Enterprise, or Education (Build 15063 or later).
Hyper-V and Containers Windows features must be enabled.
The following hardware prerequisites are required to successfully run Client Hyper-V on Windows 10:
64 bit processor with Second Level Address Translation (SLAT)
4GB system RAM
BIOS-level hardware virtualization support must be enabled in the BIOS settings. For more information, see Virtualization.
README for Docker Toolbox and Docker Machine users: Microsoft Hyper-V is required to run Docker Desktop. The Docker Desktop Windows installer enables Hyper-V if required, and restarts your machine. When Hyper-V is enabled, VirtualBox no longer works. However, any existing VirtualBox VM images are retained.
1 Like
espenmn
(Espen)
February 5, 2020, 4:55pm
9
Is there a way to 'get access' to the var folder?
(in other words: to copy Data.fs and blobs from another plone to docker)
is there a way to 'get access' to the var folder?
I did not manage to ssh into the container - that said - I never used docker before.
~/Tests/plone
β― sudo docker inspect -f "{{ .NetworkSettings.IPAddress }}" ppp
172.17.0.2
~/Tests/plone
β― ssh 172.17.0.2
ssh: connect to host 172.17.0.2 port 22: Connection refused
tkimnguyen
(T. Kim Nguyen)
February 5, 2020, 10:24pm
11
This explains how to get a shell into the running Docker image (sorry, I shouldn't have said ssh
before):
https://docs.plone.org/manage/docker/docs/usage/debug_mode.html#debugging-with-pdp
espenmn
(Espen)
February 5, 2020, 11:21pm
12
For my wordpress docker images I map the themes and plugins folders (which I find better).
In the docker.compose.yml I specify and map folders with
volumes:
But I could not find any docs saying similar 'things' are possible with Plone
tkimnguyen
(T. Kim Nguyen)
February 6, 2020, 8:20am
13
I have only started using this so maybe itβs mentioned in the repo docs or in https://docs.plone.org/manage/docker/docs/index.html (the Docker image is covered)
ericof
(Ericof)
February 6, 2020, 11:17am
14
A quick -- not complete or detailed -- recipe would be to start docker with:
docker run -v "$(pwd)/data":/data -p 8080:8080 plone
Important points here:
This starts a Plone instance and export the container port 8080 to the host (http://localhost:8080 )
You need to create the local ./data folder before -- add filestorage, blobstorage and logs subfolders
Move your Data.fs* and blobstorage inside ./data
1 Like
espenmn
(Espen)
February 6, 2020, 11:33am
15
Thanks.
That worked
PS: I never got the mapping in docker-compose to work ( https://docs.plone.org/manage/docker/docs/data/index.html )
1 Like
ericof
(Ericof)
February 6, 2020, 11:59am
16
I have one working example:
version: '3'
services:
haproxy:
image: eeacms/haproxy
ports:
- 8080:5000
- 1936:1936
depends_on:
- plone
environment:
STATS_AUTH: "admin:not_really"
BACKENDS: "plone"
BACKENDS_PORT: "8080"
DNS_ENABLED: "True"
HTTPCHK: "GET /"
plone:
image: plone
ports:
- "8090:8080"
depends_on:
- zeo
environment:
- ZEO_ADDRESS=zeo:8080
zeo:
image: plone
command: zeo
volumes:
- ./data:/data
Look I do not have the named volumes at the end of the file.
espenmn
(Espen)
February 6, 2020, 12:59pm
17
Do you mean that you do not specify volumes 'as a separate entry' ?
I tried this on OS X (no windows at work) and that did not work (it starts and runs, but the folder is not where Data.fs is present)
ericof
(Ericof)
February 6, 2020, 2:13pm
18
Double check if you do not have containers already created with those names. I remember getting a message of "reusing existing volume".
tkimnguyen
(T. Kim Nguyen)
February 6, 2020, 3:13pm
19
Maybe you should make a PR for the docs @ericof ?
ericof
(Ericof)
February 6, 2020, 4:24pm
20
This is high on my todo list