Skip to content

Commit 7ef9201

Browse files
committed
Move content from install/index to install/index or install/source.
We will decide what to do with it later. For now there is a todo to remind us.
1 parent 0a1590a commit 7ef9201

File tree

2 files changed

+251
-4
lines changed

2 files changed

+251
-4
lines changed

docs/install/index.md

Lines changed: 47 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,15 @@ html_meta:
33
"description": "Install Plone 6"
44
"property=og:description": "Install Plone 6"
55
"property=og:title": "Install Plone 6"
6-
"keywords": "Plone 6, install, installation, installing"
6+
"keywords": "Plone 6, install, overview"
77
---
88

99
(install-index-label)=
1010

1111
# Install Plone 6
1212

1313

14-
14+
(install-index-getting-started-label)=
1515

1616
## Getting started
1717

@@ -21,9 +21,53 @@ html_meta:
2121
* Develop Plone add-ons or contribute to Plone packages → Install Plone from source
2222

2323

24-
## Caveat that Plone is a large project and source installs are non-trivial
24+
(install-index-system-requirements-label)=
25+
26+
## System Requirements
27+
28+
To install Plone 6, you must satisfy system requirements.
29+
30+
```{todo}
31+
Add any missing requirements, including disk space.
32+
```
33+
34+
- 2GB if using a container image, 4GB RAM if installing manually.
35+
- Disk space (TBD).
36+
- Either a UNIX-like operating system—such as Linux, Ubuntu, macOS—or Windows.
37+
For Windows, it is a good idea to use [Windows Subsystem for Linux (WSL)](https://docs.microsoft.com/en-us/windows/wsl/).
38+
We strongly recommend using a recent version of your operating system released within the last 3 years.
39+
Older systems might not be supported.
40+
- Python 3.7, 3.8, or 3.9.
41+
42+
Additional requirements might be needed depending on your choice of installation method.
43+
2544

45+
(install-index-choose-installation-method-label)=
2646

47+
### Choose an installation method
48+
49+
Developers may choose to install Plone from either [the official container images](containers/index) or [source](source).
50+
51+
The Plone 6 container images are compliant with the [Open Container Initiative (OCI)](https://opencontainers.org/).
52+
They should work with any OCI-compliant container engine for developing, managing, and running Plone 6 images.
53+
Two popular options include [podman](https://podman.io/) and [Docker](https://www.docker.com/products/docker-desktop/).
54+
The Plone 6 images have all the system requirements, pre-requisites, and Plone 6 already installed, except those requirements needed for running the container engine itself.
55+
This option is the quickest method to install and develop for Plone 6 and its packages.
56+
57+
There may be some cases where using a Plone 6 image is not practical or desired.
58+
You might want to use an SQL database that is not PostgreSQL, or you might use a deployment workflow that has specific requirements.
59+
For these situations, Plone 6 may be installed manually.
60+
This method takes longer.
61+
It might be a challenge if you bump up against system requirements, or need to resolve conflicts between required packages.
62+
63+
```{todo}
64+
Perhaps merge the subsequent section into this section?
65+
```
66+
67+
68+
(install-index-caveat-label)=
69+
70+
## Caveat that Plone is a large project and source installs are non-trivial
2771

2872

2973
```{toctree}

docs/install/source.md

Lines changed: 204 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,22 +3,225 @@ html_meta:
33
"description": "Install Plone 6 from source"
44
"property=og:description": "Install Plone 6 from source"
55
"property=og:title": "Install Plone 6 from source"
6-
"keywords": "Plone 6, install, installation, installing, buildout, pip, docker, source"
6+
"keywords": "Plone 6, install, buildout, pip, Docker, source"
77
---
88

99

10+
(install-source-1-label)=
11+
1012
# Install from source for development
1113

14+
As an overview, you will perform the following steps in order.
15+
16+
1. Install the Plone backend (which includes the Classic UI) with either [buildout](install-source-install-backend-label) or [pip](install-source-install-backend-pip-label).
17+
1. Create the Plone Site in a web browser, choosing either the new Volto or the Classic UI for a frontend.
18+
1. Install the Plone frontend (Volto) with node.
19+
20+
21+
(install-source-2-label)=
22+
1223
## Backend source / frontend source explanation
1324

25+
26+
(install-source-3-label)=
27+
1428
## Pip install / cookiecutter
1529

30+
31+
(install-source-4-label)=
32+
1633
## Mxdev
1734

35+
36+
(install-source-5-label)=
37+
1838
## Tox
1939

40+
41+
(install-source-5-label)=
42+
2043
## Deprecated installation methods
2144

45+
46+
(install-source-5-a-label)=
47+
2248
### Buildout
2349

50+
51+
(install-source-5-b-label)=
52+
2453
### Universal installer? (based on buildout) -> container
54+
55+
56+
57+
58+
```{todo}
59+
Move parts of the subsequent content into their appropriate section headings above.
60+
```
61+
62+
(install-source-install-backend-label)=
63+
64+
### Install the Plone backend
65+
66+
You can install the Plone backend with either [buildout](install-source-install-backend-label) or [pip](install-source-install-backend-pip-label).
67+
68+
69+
(install-source-install-backend-buildout-label)=
70+
71+
#### Install backend with buildout
72+
73+
Create a new directory to hold your project, make it your current directory, and create a new file inside it called `buildout.cfg`.
74+
This file will refer to the latest version of Plone, and the `user` value that will be used in the next step to create a Plone site.
75+
Paste the following configuration information into it.
76+
77+
```ini
78+
[buildout]
79+
extends = https://dist.plone.org/release/6.0.0a4/versions.cfg
80+
parts = instance
81+
82+
[instance]
83+
recipe = plone.recipe.zope2instance
84+
eggs =
85+
Plone
86+
user = admin:admin
87+
```
88+
89+
Install Plone with the following shell commands.
90+
91+
```shell
92+
# Create a Python virtual environment in the current directory
93+
python3.9 -m venv .
94+
# Install the latest Plone 6 requirements with pip
95+
bin/pip install -r https://dist.plone.org/release/6.0.0a4/requirements.txt
96+
# Run buildout to install Plone 6
97+
bin/buildout
98+
# Start the Plone instance
99+
bin/instance fg
100+
```
101+
102+
103+
(install-source-install-backend-pip-label)=
104+
105+
#### Install backend with pip
106+
107+
Create a new directory to hold your project, make it your current directory, then issue the following commands in a shell session.
108+
109+
```shell
110+
# Create a Python virtual environment in the current directory
111+
python3.9 -m venv .
112+
# Update Python package management tools
113+
bin/pip install -U pip setuptools wheel
114+
# Install Plone 6 with constrained requirements with pip
115+
bin/pip install Plone -c https://dist.plone.org/release/6.0.0a4/constraints.txt
116+
# Create a Plone 6 site with the given username and password in the current directory
117+
bin/mkwsgiinstance -u admin:admin -d .
118+
# Initialize Zope
119+
bin/runwsgi -v etc/zope.ini
120+
```
121+
122+
```{warning}
123+
You might need to edit `etc/zope.conf` to add a `blobstorage` node with a `blob-dir` entry.
124+
See [issue 3345](https://github.com/plone/Products.CMFPlone/issues/3345#issuecomment-953700024).
125+
```
126+
127+
128+
(install-source-create-plone-site-label)=
129+
130+
## Create a Plone site
131+
132+
After you have installed the backend with buildout or pip, open a browser and visit http://localhost:8080/.
133+
134+
Choose either Volto or Classic UI for the frontend.
135+
136+
- For a new Volto frontend, click {guilabel}`Create a new Plone site` to prepare a Plone site and its backend.
137+
138+
```{note}
139+
If this button is not available, then you did not install `plone.volto` with buildout or pip.
140+
```
141+
142+
```{attention}
143+
For Volto, make sure the `Path` identifier is `Plone`.
144+
You can change this, but then you need to change some Volto frontend configuration as well.
145+
```
146+
147+
- For a Plone Classic UI frontend, click {guilabel}`Create Classic Plone site`.
148+
149+
Submit the form and your backend is ready.
150+
151+
If you created a Plone site with a Classic UI frontend, then you have completed installation.
152+
153+
If a created a Plone site with a Volto frontend, continue with the next steps.
154+
155+
156+
(install-source-volto-frontend-node-label)=
157+
158+
## Volto frontend with node
159+
160+
We recommend that you read the chapter {ref}`frontend-getting-started-installing-volto-label` for details.
161+
162+
163+
(install-source-nvm-node-version-manager-label)=
164+
165+
### `nvm`, the Node Version Manager
166+
167+
We recommend that you install [`nvm`, or Node Version Manager](https://github.com/nvm-sh/nvm).
168+
This makes it possible to switch to any version of [`node` (Node.JS)](https://nodejs.org/en/) and [`npm` (Node Package Manager)](https://www.npmjs.com/) for any project on which you might work.
169+
170+
- On Linux: `apt-get install nvm`
171+
- On Mac: `brew install nvm`
172+
- Or use the installation procedure detailed in the [nvm documentation](https://github.com/nvm-sh/nvm)
173+
174+
With `nvm` installed, you can use it to install and use a supported version of `node` and `npm` using the following shell commands.
175+
176+
```shell
177+
nvm install 16
178+
nvm use 16
179+
```
180+
181+
182+
(install-source-install-yarn-label)=
183+
184+
## Install Yarn
185+
186+
Volto requires [Yarn Classic](https://classic.yarnpkg.com/lang/en/), a dependency manager for JavaScript code.
187+
Install Yarn with the following command.
188+
189+
```shell
190+
npm install --global yarn
191+
```
192+
193+
194+
(install-source-create-volto-project-label)=
195+
196+
### Create a Volto project
197+
198+
Create a Volto project using the following shell command.
199+
200+
```shell
201+
npm init yo @plone/volto
202+
```
203+
204+
This will take some time ☕️.
205+
Toward the end of the process, it will ask you for a project name.
206+
Enter the name of your project, using only lowercase letters.
207+
It will create a directory with this name.
208+
Go to that directory and start the frontend with the following command.
209+
210+
```shell
211+
yarn start
212+
```
213+
214+
In your browser, visit [http://localhost:3000](http://localhost:3000/).
215+
216+
Congratulations!
217+
You have completed the installation of Plone 6 with Volto for its frontend.
218+
Welcome to Plone 6!
219+
220+
221+
(install-source-additional-references-label)=
222+
223+
## Additional references
224+
225+
- [Installation instructions from the Mastering Plone 6 training](https://training.plone.org/5/mastering-plone/installation.html)
226+
- {ref}`frontend-getting-started-installing-volto-label`
227+
- [Community post](https://community.plone.org/t/our-pip-based-development-workflow-for-plone/14562) on work in progress with [`plone-kickstarter`](https://github.com/bluedynamics/plone-kickstarter) and [`mxdev`](https://github.com/bluedynamics/mxdev).

0 commit comments

Comments
 (0)