User Tools

Site Tools


infra:services:hackeriet.no

This is an old revision of the document!


Hackeriet.no

hackeriet.no is the main public website for Hackeriet.

Hosting

The site is served directly by nginx on blade.hackeriet.no.

Active nginx config:

  • /etc/nginx/sites-enabled/hackeriet.no.conf
  • source file: /etc/nginx/sites-available/hackeriet.no.conf

Main site root:

  • /var/www/hackeriet.no/

The document root is a git checkout of:

The site is mostly static HTML/CSS/JS.

DNS and TLS

Authoritative DNS for hackeriet.no is documented at nameserver.

TLS is terminated by nginx on blade using Let's Encrypt certificates.

For hackeriet.no, the active nginx config references:

  • /etc/letsencrypt/live/hackeriet.no-0001/fullchain.pem
  • /etc/letsencrypt/live/hackeriet.no-0001/privkey.pem

Useful checks:

dig +short hackeriet.no A
dig +short hackeriet.no AAAA
dig +short www.hackeriet.no
curl -I https://hackeriet.no/
curl -I https://www.hackeriet.no/
systemctl status certbot.timer
certbot certificates
nginx -t

Deployment

Deployments are handled by webhook.service on blade.

Service:

systemctl status webhook.service
systemctl cat webhook.service

The webhook server reads:

  • /etc/webhook.conf

The hackeriet.no hook:

  • hook id: hackeriet.no
  • trigger: GitHub push to refs/heads/master
  • command: /etc/webhook/pull-hackeriet.no.sh

The deploy script runs:

sudo -uhackerietweb bash -c "cd /var/www/hackeriet.no && git pull"

The webhook secret is in /etc/webhook.conf and should match the GitHub webhook configuration for the repository.

GitHub webhook settings:

Webhook endpoint through nginx:

Website Data Dependencies

The website has a few dynamic-looking parts, but the site itself is still static. These are the website-facing dependencies worth knowing about.

Door status

The frontend reads:

  • /door.json

Nginx handles this route and sends it to the door status service:

Relevant frontend code:

  • js/hackeriet.js
  • function: update_door()

If the website works but the door status is wrong, check the door service separately.

Events

The frontend reads:

  • /events.json

This file is generated on blade and served from:

  • /var/www/hackeriet.no/events.json

Relevant frontend code:

  • js/hackeriet.js
  • function: update_mobilizon()

The event source is events.hackeriet.no, which is documented separately at mobilizon.

Website-side checks:

curl -I https://hackeriet.no/events.json
ls -l /var/www/hackeriet.no/events.json
systemctl status mobilizon-data.timer mobilizon-data.service
journalctl -u mobilizon-data.service --since "1 day ago"

Meetup legacy data

/var/www/hackeriet.no/meetup.json is still generated on blade, but the current frontend has update_meetup() commented out and uses /events.json instead.

Treat meetup.json as legacy, Hackeriet has decided to discontinue meetup because of pricing.

WebSocket path

js/hackeriet.js currently attempts to connect to:

  • wss:hackeriet.no/ws/ As of 2026-06-21, active nginx config did not show a /ws/ proxy and https://hackeriet.no/ws/ returned 404. Treat this as stale or broken until verified. ===== Manual Deploy ===== Normal deployment should happen through the GitHub webhook. If a manual deploy is needed on blade: <code> sudo -uhackerietweb bash -c 'cd /var/www/hackeriet.no && git pull –ff-only' </code> Then verify: <code> curl -I https://hackeriet.no/ </code> If nginx config has changed: <code> nginx -t systemctl reload nginx </code> ===== Troubleshooting ===== ==== Public site is down ==== Check: * DNS for hackeriet.no * nginx status on blade * certificate status * filesystem space on blade * whether the expected files exist under /var/www/hackeriet.no * nginx logs Commands: <code> systemctl status nginx df -h -x tmpfs -x devtmpfs ls -la /var/www/hackeriet.no/ journalctl -u nginx –since “1 hour ago” </code> ==== GitHub push did not deploy ==== Check: * GitHub webhook delivery for https://github.com/hackeriet/hackeriet.no/settings/hooks * webhook.service status * /etc/webhook.conf * /etc/webhook/pull-hackeriet.no.sh * git status in /var/www/hackeriet.no'' * webhook logs Commands: <code> systemctl status webhook.service journalctl -u webhook.service –since “1 hour ago” sudo -uhackerietweb git -C /var/www/hackeriet.no status –short –branch </code> ==== Events are missing or stale ==== Check the website-facing generated file first: <code> ls -l /var/www/hackeriet.no/events.json curl -I https://hackeriet.no/events.json systemctl status mobilizon-data.timer mobilizon-data.service journalctl -u mobilizon-data.service –since “1 day ago” </code> For the event service itself, see mobilizon. ==== Door status is wrong ==== Check the website-facing endpoint first: <code> curl -I https://hackeriet.no/door.json curl -I https://door.hackeriet.no/door.json </code> Then check the door status service separately. ===== Related Pages ===== * Blade * Authoritative name server * Blog * Mobilizon / events.hackeriet.no
/srv/hackeriet-wiki/dokuwiki/data/attic/infra/services/hackeriet.no.1782050332.txt.gz · Last modified: by atluxity_idp.hackeriet.no