website/README.md

52 lines
1.6 KiB
Markdown

<div align="center">
<img width="80px" alt="Gna! logo" src="./static/gna-logo-rectangle.png" />
<h1>Gna! Website</h1>
[![status-badge](https://woodpecker.gna.org/api/badges/Gna/website/status.svg)](https://woodpecker.gna.org/Gna/website)
[![AGPL License](https://img.shields.io/badge/license-AGPL-blue.svg?style=flat-square)](http://www.gnu.org/licenses/agpl-3.0)
</div>
## Development environment
This website uses [Zola](https://www.getzola.org/), an easy to use static site generator.
To get started:
1. Install Zola:
```bash
Make env
```
2. Live reload
```bash
make serve
```
3. Make changes and publish
```bash
make
```
Build artifacts should be available in `./public/`
## Deployment
This repository uses [Gna!
Woodpecker-CI](https://woodpecker.gna.org/) to build and
[Librepages](https://librepages.org/) to deploy on each
commit.
To setup the CI:
* `ssh-keygen -b 4096 -f /tmp/pages`
* `xclip -sel clip -in < /tmp/pages.pub`
* use that to add a key in https://forgejo.gna.org/Gna/website/settings/keys (with write access)
* xclip -sel clip -in < /tmp/pages
* use that to add the hostea_write_deploy_key (see [.woodpecker.yml](https://forgejo.gna.org/Gna/website/src/branch/master/.woodpecker.yml#L10)) in https://woodpecker.gna.org/Gna/website/settings#secrets
* get the secret for pages in ~/.enough/gna.org/inventory/group_vars/pages-service-group.yml
* add secret for pages in https://woodpecker.gna.org/Gna/website/settings#secrets under the name **pages_deploy_secret** to match [.woodpecker.yml](https://forgejo.gna.org/Gna/website/src/branch/master/.woodpecker.yml#L10)