Update pkgbuild and nginx to serve static

This commit is contained in:
Edgar P. Burkhart 2022-05-21 17:53:07 +02:00
parent 4157e20376
commit ab35d774dc
Signed by: edpibu
GPG key ID: 9833D3C5A25BD227
2 changed files with 9 additions and 0 deletions

View file

@ -24,7 +24,12 @@ package() {
install -Dm644 ${pkgname}.tmpfiles "${pkgdir}"/usr/lib/tmpfiles.d/${pkgname}.conf
install -Dm644 ${pkgname}.sysusers "${pkgdir}"/usr/lib/sysusers.d/${pkgname}.conf
install -Dm644 ${pkgname}.nginx "${pkgdir}"/etc/nginx/sites-enabled/${pkgname}.conf
install -dm644 "${pkgdir}"/srv/${pkgname}
cd ${pkgname}/${pkgname}
find * -type f -exec install -Dm0644 "{}" "${pkgdir}/usr/share/webapps/${pkgname}/{}" \;
cd "${pkgdir}/usr/share/webapps/${pkgname}"
python manage.py migrate
python manage.py collectstatic
}

View file

@ -8,4 +8,8 @@ server {
proxy_pass http://unix:/run/nummi/nummi.socket;
}
location /static {
alias /srv/nummi;
}
}