Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add "create project" docs for cookieplone #1714

Merged
merged 32 commits into from
Sep 30, 2024
Merged
Show file tree
Hide file tree
Changes from 6 commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
badd795
Add "create project" docs for cookieplone
davisagli Sep 26, 2024
2fabf07
Add overlooked comma
stevepiercy Sep 27, 2024
3f264f6
Rename file
stevepiercy Sep 27, 2024
0f6ef61
Rename file
stevepiercy Sep 27, 2024
5115e86
Remove "the" from Classic UI.
stevepiercy Sep 27, 2024
a70b455
Merge branch '6.0' into cookieplone
stevepiercy Sep 27, 2024
c464ebf
Apply suggestions from code review
davisagli Sep 27, 2024
51dad84
Merge branch '6.0' into cookieplone
stevepiercy Sep 27, 2024
5619a1b
Overhaul the Install index.
stevepiercy Sep 28, 2024
50246bc
Simplify introductions for create-project*
stevepiercy Sep 28, 2024
5f28d42
Update meta information
stevepiercy Sep 28, 2024
946a1c3
Current version of Sphinx does not support replacements in includes, …
stevepiercy Sep 28, 2024
7d0a44f
Hyphenate pre-requisite and tidy
stevepiercy Sep 28, 2024
c524246
Update meta information
stevepiercy Sep 28, 2024
bf580c2
Use narrow terminal to avoid horizontal scrolling of console.
stevepiercy Sep 28, 2024
a99d74f
Add next steps to view the site. Much excite!
stevepiercy Sep 28, 2024
477c496
Update meta information and correct Volto version
stevepiercy Sep 28, 2024
1c0d53c
Correct introduction
stevepiercy Sep 28, 2024
bfc3698
Add terms Cookieplone and cookieplone-templates to Glossary.
stevepiercy Sep 28, 2024
7badeea
Use include for Python prerequisite
stevepiercy Sep 28, 2024
41de6eb
Update docs/glossary.md
stevepiercy Sep 28, 2024
864e9cd
Update docs/install/create-project-cookieplone.md
stevepiercy Sep 28, 2024
e8fee7a
Include corepack enable as an enumerated step, and use shell for syntax
stevepiercy Sep 28, 2024
0c4c79d
Avoid horizontal scrolling and anonymize path to project
stevepiercy Sep 29, 2024
4f2e008
Finalize tidy and update screenshots to 2024
stevepiercy Sep 29, 2024
94cd6f7
Link to correct repo. See https://github.com/plone/cookieplone/pull/41
stevepiercy Sep 29, 2024
f450915
Add plone/generator-volto deprecation to Glossary
stevepiercy Sep 29, 2024
6d197a9
Cannot use `@` at the start of a term in the Glossary
stevepiercy Sep 29, 2024
1013687
Nope, `@` is fine, there was whitespace that broke the glossary.
stevepiercy Sep 29, 2024
d67ac39
Add note about installing Pillow requirements. See https://github.com…
stevepiercy Sep 29, 2024
11e46b9
Merge branch '6.0' into cookieplone
stevepiercy Sep 29, 2024
bc43d3a
Update docs/glossary.md
stevepiercy Sep 29, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions docs/_inc/_hardware-requirements.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
The hardware requirements below give a rough estimate of the minimum hardware setup needed for a Plone server.

A single Plone installation is able to run many Plone sites.

- Installation of the Plone backend and Classic UI frontend requires a minimum of 256 MB of RAM and 2GB of disk swap space.
- Installation of the Volto frontend requires a minimum of 2GB of RAM.
- After installation, running Plone requires a minimum of 256 MB RAM and 512 MB of disk swap space per Plone site.
2 GB or more RAM per Plone site is recommended.
- Minimum 512 MB hard disk space is required.
40 GB or more hard disk space is recommended.


````{warning}
{term}`Add-on` products and caching solutions may also increase RAM and disk swap space requirements.
To avoid RAM and disk swap limitations, we recommend either temporarily resizing your remote machine to accommodate the build, or build your images locally and upload them to an image store, such as [Docker Hub](https://hub.docker.com/) or [GitHub Packages](https://github.com/features/packages).
```{seealso}
[How much RAM is required to build a Volto front end?](https://community.plone.org/t/how-much-ram-is-required-to-build-a-volto-front-end/17949) and [Dealing with heap exhaustion while building Volto 17 on limited-RAM host](https://community.plone.org/t/dealing-with-heap-exhaustion-while-building-volto-17-on-limited-ram-host/18078).
```
````
3 changes: 3 additions & 0 deletions docs/_inc/_install-python.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
Installing Python is beyond the scope of this documentation.
However, it is recommended to use a Python version manager, {term}`pyenv`, that allows you to install multiple versions of Python on your development environment without destroying your system's Python.
Plone requires Python version {SUPPORTED_PYTHON_VERSIONS}.
201 changes: 201 additions & 0 deletions docs/install/create-project-classic-ui.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,201 @@
---
myst:
html_meta:
"description": "Create a Plone project with Classic UI"
"property=og:description": "Create a Plone project with Classic UI"
"property=og:title": "Create a Plone project with Classic UI"
"keywords": "Plone, Plone 6, Classic UI, create, project, install, cookiecutter"
---


(create-a-project-classic-ui-label)=

# Create a project with Classic UI

This chapter describes how you can create a web application project using Plone, while having full control over its development and deployment.

If instead you want to contribute to a Plone package, see {doc}`/contributing/index`.

```{note}
These instructions create a project using Classic UI.
If you'd like to use the Volto frontend instead, see {doc}`/install/create-project`.
```

## System requirements

Plone 6 has both hardware requirements and software pre-requisites.
stevepiercy marked this conversation as resolved.
Show resolved Hide resolved


### Hardware requirements

```{include} /_inc/_hardware-requirements.md
```

### Pre-requisites for installation

```{include} ../volto/contributing/install-operating-system.md
```

- Python {SUPPORTED_PYTHON_VERSIONS}
- {term}`pipx`
- {term}`GNU make`
- {term}`Git`


#### Python

Installing Python is beyond the scope of this documentation.
However, it is recommended to use a Python version manager, {term}`pyenv` that allows you to install multiple versions of Python on your development environment without destroying your system's Python.
Plone requires Python version {SUPPORTED_PYTHON_VERSIONS}.


#### pipx

Install {term}`pipx`.

```shell
pip install pipx
```


#### Make

```{include} ../volto/contributing/install-make.md
```


#### Git

```{include} ../volto/contributing/install-git.md
```


## Generate the project

After satisfying the prerequisites, generate the project.

```shell
pipx run cookieplone backend_addon
```

You will be presented with a series of prompts.
You can accept the default values in square brackets (`[default-option]`) by hitting the {kbd}`Enter` key, or enter your preferred values.
For ease of documentation, we will use the default values.

```{tip}
See the cookiecutter's README for how to [Use options to avoid prompts](https://github.com/collective/cookiecutter-plone-starter/?tab=readme-ov-file#use-options-to-avoid-prompts).
```

```{important}
For {guilabel}`Project Slug`, you must not use any of the Plone core package names listed in [`constraints.txt`](https://dist.plone.org/release/6.0-latest/constraints.txt).
Note that pip normalizes these names, so `plone.volto` and `plone-volto` are the same package.
```

```console
% pipx run cookieplone backend_addon
╭─────────────────────────────────────────────────────── cookieplone ───────────────────────────────────────────────────────╮
│ │
│ .xxxxxxxxxxxxxx. │
│ ;xxxxxxxxxxxxxxxxxxxxxx; │
│ ;xxxxxxxxxxxxxxxxxxxxxxxxxxxx; │
│ xxxxxxxxxx xxxxxxxxxx │
│ xxxxxxxx. .xxxxxxxx │
│ xxxxxxx xxxxxxx: xxxxxxx │
│ :xxxxxx xxxxxxxxxx xxxxxx: │
│ :xxxxx+ xxxxxxxxxxx +xxxxx: │
│ .xxxxx. :xxxxxxxxxx .xxxxx. │
│ xxxxx+ ;xxxxxxxx +xxxxx │
│ xxxxx +xx. xxxxx. │
│ xxxxx: .xxxxxxxx :xxxxx │
│ xxxxx .xxxxxxxxxx xxxxx │
│ xxxxx xxxxxxxxxxx xxxxx │
│ xxxxx .xxxxxxxxxx xxxxx │
│ xxxxx: .xxxxxxxx :xxxxx │
│ .xxxxx ;xx. ... xxxxx. │
│ xxxxx+ :xxxxxxxx +xxxxx │
│ .xxxxx. :xxxxxxxxxx .xxxxx. │
│ :xxxxx+ xxxxxxxxxxx ;xxxxx: │
│ :xxxxxx xxxxxxxxxx xxxxxx: │
│ xxxxxxx xxxxxxx; xxxxxxx │
│ xxxxxxxx. .xxxxxxxx │
│ xxxxxxxxxx xxxxxxxxxx │
│ ;xxxxxxxxxxxxxxxxxxxxxxxxxxxx+ │
│ ;xxxxxxxxxxxxxxxxxxxxxx; │
│ .xxxxxxxxxxxxxx. │
│ │
╰───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
╭─────────────────────────────────────────────────────── Plone Addon ───────────────────────────────────────────────────────╮
│ Creating a new Plone Addon │
╰───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
[1/7] Addon Title (Addon): Classic UI Project
[2/7] A short description of your addon (A new addon for Plone): A Plone Classic UI project
[3/7] Author (Plone Community):
[4/7] Author E-mail ([email protected]):
[5/7] GitHub Username or Organization (collective):
[6/7] Python package name (collective.classicuiproject):
[7/7] Support headless Plone?
1 - Yes
2 - No
Choose from [1/2] (1):
-> Initialize Git repository
╭───────────────────────────────────────────────── New addon was generated ─────────────────────────────────────────────────╮
│ │
│ Classic UI Project │
│ │
│ Now, enter the repository run the code formatter with: │
│ │
│ make format │
│ │
│ start coding, and push to your organization. │
│ │
│ Sorry for the convenience, │
│ The Plone Community. │
│ │
│ https://plone.org/ │
╰───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
```

## Install the project

Change to your project directory.

```shell
cd collective.classicuiproject
```

To install the project's dependencies, use the following command.

```shell
make install
```

This will take a few minutes.
When the process completes successfully, it will exit with no message.


## Start Plone

To start Plone, issue the following command.

```shell
make start
```

The Plone backend server starts up and emits messages to the console.

```console
2024-09-25 16:47:15,699 INFO [chameleon.config:39][MainThread] directory cache: /<path-to-project>/instance/var/cache.
2024-09-25 16:47:16,387 WARNING [ZODB.FileStorage:412][MainThread] Ignoring index for /<path-to-project>/instance/var/filestorage/Data.fs
2024-09-25 16:47:16,508 INFO [plone.restapi.patches:16][MainThread] PATCH: Disabled ZPublisher.HTTPRequest.ZopeFieldStorage.VALUE_LIMIT. This enables file uploads larger than 1MB.
2024-09-25 16:47:17,018 INFO [plone.volto:23][MainThread] Aliasing collective.folderish classes to plone.volto classes.
2024-09-25 16:47:17,760 INFO [Zope:42][MainThread] Ready to handle requests
Starting server in PID 20912.
2024-09-25 16:47:17,772 INFO [waitress:486][MainThread] Serving on http://[::1]:8080
2024-09-25 16:47:17,772 INFO [waitress:486][MainThread] Serving on http://127.0.0.1:8080
```

Open a browser at the following URL to visit your Plone site.

http://localhost:8080

You can stop the site with {kbd}`ctrl-c`.
Loading