An open API service indexing awesome lists of open source software.

https://github.com/kitconcept/kitconcept.intranet


https://github.com/kitconcept/kitconcept.intranet

Last synced: 5 months ago
JSON representation

Awesome Lists containing this project

README

          

# kitconcept Intranet ๐Ÿš€

[![Built with Cookieplone](https://img.shields.io/badge/built%20with-Cookieplone-0083be.svg?logo=cookiecutter)](https://github.com/plone/cookiecutter-plone/)
[![Tests](https://github.com/kitconcept/kitconcept.intranet/actions/workflows/main.yml/badge.svg)](https://github.com/kitconcept/kitconcept.intranet/actions/workflows/main.yml)

A Plone distribution for Intranets with Plone. Created by kitconcept.

## Quick Start ๐Ÿ

### Prerequisites

- Docker (https://www.docker.com/)
- Git (https://git-scm.com/downloads)

### Set up local demo instance

- Clone repository with `git clone https://github.com/kitconcept/kitconcept.intranet.git`
- Change directory to "kitconcept.intranet" with `cd kitconcept.intranet`
- Start Docker containers with `docker-compose up`
- Open kitconcept.intranet in your browser by typing `http://kitconcept-intranet.localhost/` into your browser URL field

## Development

### Prerequisites โœ…

Ensure you have the following installed:

- Python 3.12 ๐Ÿ
- Node 22 ๐ŸŸฉ
- pnpm ๐Ÿงถ
- Docker ๐Ÿณ
- UV (See [https://docs.astral.sh/uv/getting-started/installation/#standalone-installer])

### Installation ๐Ÿ”ง

1. Clone the repository:

```shell
git clone git@github.com:kitconcept/kitconcept.intranet.git
cd kitconcept.intranet
```

2. Install both Backend and Frontend:

```shell
make install
```

### Fire Up the Servers ๐Ÿ”ฅ

1. Create a new Plone site on your first run:

```shell
make backend-create-site
```

or create the site manually by visiting [http://localhost:8080/](http://localhost:8080/).

2. Start the Backend at [http://localhost:8080/](http://localhost:8080/):

```shell
make backend-start
```

3. In a new terminal, start the Frontend at [http://localhost:3000/](http://localhost:3000/):

```shell
make frontend-start
```

Voila! Your Plone site should be live and kicking! ๐ŸŽ‰

### Manual site creation ๐Ÿ”ฅ

Point your browser at [http://localhost:8080/](http://localhost:8080/) and you will be greated with the site creation page:

first step

After selecting **kitconcept Intranet** you will see a form:

first step

### Amend Example Content

First, make sure that you do not have the backend process running.

Delete existing site and all its content and re-create a new Plone site:

````
make backend-delete-and-create-site
````

Start the backend with:

````
make backend-start
````

and amend the content on the site.

Stop the backend by killing the `make backend-start` process (CTRL+C).

Export the content of the Plone site to your local repository (make sure the backend is stopped for this):

````
make backend-update-example-content
````

Show the diff in your local repository:

````
git diff
````

Commit your changes:

````
git add .
git checkout -b
git commit . -m""
git push
````

Go to [github.com/kitconcept/kitconcept.intranet](https://github.com/kitconcept/kitconcept.intranet/pulls) and click on the banner that shows your PR. Click on "Compare & pull request".

#### Authentication

Choosing **Keycloak** for user authentication will present configuration options:

first step

Choosing **OIDC / OAuth2** for user authentication will present configuration options:

first step

Choosing **Google** for user authentication will present configuration options:

first step

Choosing **GitHub** for user authentication will present configuration options:

first step

### Local Stack Deployment ๐Ÿ“ฆ

Deploy a local `Docker Compose` environment that includes:

- Docker images for Backend and Frontend ๐Ÿ–ผ๏ธ
- A stack with a Traefik router and a Postgres database ๐Ÿ—ƒ๏ธ
- Accessible at [http://kitconcept.intranet.localhost](http://kitconcept.intranet.localhost) ๐ŸŒ

Execute the following:

```shell
make stack-start
make stack-create-site
```

And... you're all set! Your Plone site is up and running locally! ๐Ÿš€

## Project Structure ๐Ÿ—๏ธ

This monorepo consists of three distinct sections: `backend`, `frontend`, and `devops`.

- **backend**: Houses the API and Plone installation, utilizing pip instead of buildout, and includes a policy package named kitconcept.intranet.
- **frontend**: Contains the React (Volto) package.
- **devops**: Encompasses Docker Stack, Ansible playbooks, and Cache settings.

### Why This Structure? ๐Ÿค”

- All necessary codebases to run the site are contained within the repo (excluding existing addons for Plone and React).
- Specific GitHub Workflows are triggered based on changes in each codebase (refer to .github/workflows).
- Simplifies the creation of Docker images for each codebase.
- Demonstrates Plone installation/setup without buildout.

## Code Quality Assurance ๐Ÿง

To automatically format your code and ensure it adheres to quality standards, execute:

```shell
make check
```

Linters can be run individually within the `backend` or `frontend` folders.

## Internationalization ๐ŸŒ

Generate translation files for Plone and Volto with ease:

```shell
make i18n
```

## Credits and Acknowledgements ๐Ÿ™

Crafted with care by **Generated using [Cookieplone (0.7.0)](https://github.com/plone/cookieplone) and [cookiecutter-plone (9937161)](https://github.com/plone/cookiecutter-plone/commit/993716123f0616eea9074ae4bd82eb3fcd48c4f1) on 2024-05-28 19:04:49.900739**. A special thanks to all contributors and supporters!