Hugo source of my personal portfolio & blog. Available at filippo-orru.com.
Before getting started, make sure you have the following installed on your machine:
- Docker
- Docker Compose
-
Set up reverse proxy with traefik: https://github.com/filippo-orru/vps-reverse-proxy. Follow instructions there.
-
Create a deploy key using this script and add it to the Github repository.
-
Clone this repository using the command echoed by the script.
-
Pull the submodule
webhook-listener
(used for automatic deployment).-
Generate a deploy key and add it to the Github repository.
-
Clone the
webhook-listener
repository using the command echoed by the script.
-
-
Create the file
webhook.secret
to store the Github webhook secret used by the webhook-listener. -
Copy the ssh config files to the webhook listener.
cp deploy/shared/ssh/config webhook-listener/shared/ssh/config cp ~/.ssh/id_rsa.personal-site-hugo webhook-listener/shared/ssh/id_rsa.personal-site-hugo cp ~/.ssh/id_rsa.webhook-listener webhook-listener/shared/ssh/id_rsa.webhook-listener
-
Configure Plausible analytics
- Create the plausible env file:
cp plausible/plausible-conf.demo.env plausible/plausible-conf.env
- Create a secret using the following command and copy it to the .env file.
openssl rand -base64 64 | tr -d '\n' ; echo
-
Create systemd service file.
-
Modify
WorkingDirectory
inpersonal-site.service
to point to the root of this repository. -
Copy the file:
sudo cp personal-site.service /etc/systemd/system/personal-site.service sudo systemctl daemon-reload sudo systemctl enable personal-site.service sudo systemctl start personal-site.service
-
-
Check the status:
sudo systemctl status personal-site.service