https://github.com/drogonframework/drogon-website
Drogon community website.
https://github.com/drogonframework/drogon-website
Last synced: 10 months ago
JSON representation
Drogon community website.
- Host: GitHub
- URL: https://github.com/drogonframework/drogon-website
- Owner: drogonframework
- License: mit
- Created: 2020-07-20T13:11:24.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2025-01-25T14:16:18.000Z (about 1 year ago)
- Last Synced: 2025-03-27T06:05:38.430Z (11 months ago)
- Language: CSS
- Homepage: https://drogon.org
- Size: 4.14 MB
- Stars: 30
- Watchers: 10
- Forks: 10
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Drogon Website
The source code for Drogon's official website.
## Dependencies
* C++ 20 capable compiler
* [Drogon](https://github.com/drogonframework/drogon)
* [nlohmann-json](https://github.com/nlohmann/json)
## How to deploy
### Running in terminal
The backend is designed to be built by CMake like any C++ applications.
```bash
mkdir build
cd build
cmake .. # Add -DCMAKE_CXX_FLAGS="-std=c++20 -fcoroutines" if using GCC10
make -j
./drogon_website
```
It load it's configuration from `drogon_config.json` in the current directory. Which is frequently replaced when building the backend itself. Please edit `drogon_config.json` in the project root to have a permanent effect.
### Arch Linux
If you are using Arch Linux, the PKGBUILD file contains everything you need to build the backend. (NOTE: This PKGBUILD is aimed for making local builds)
Assuming your `pwd` is in the same folder as this README file is.
```bash
# We need to perform some stuff outside of the directory
cd ..
mkdir trunk
# Compress the directory then put PKGBUILD and the archive in the same folder
tar --exclude='build' --exclude="content/uploads" --zstd -cf trunk/drogon-website.tar.zst drogon-website/
cp drogon-website/PKGBUILD trunk
# Build the package
cd trunk
makepkg
```
The generated `drogon-website-0.0.1-x86_64.tar.zst` should be located inside `trunk`. Just use `pacman -U` to install it and start it through systemd.
```bash
sudo pacman -U drogon-website*.pkg.tar.zst
sudo systemctl start drogon-website
```
By default, the service listens on 0.0.0.0 port 8848. To change the IP address that the service is listening on, edit `/usr/share/drogon-website/drogon_config.json` and change `address`.
```json
/*inside the configuration file*/
"listeners": [
{
"address": "0.0.0.0", /* <==== change this*/
"port": 8848,
"https": false
}
],
```
Remeber to restart the service after changing the configuration.