Debian Package Structure

This commit is contained in:
2026-01-13 09:51:11 +01:00
commit f79d3a8c46
4 changed files with 32 additions and 0 deletions

8
DEBIAN/control Normal file
View File

@@ -0,0 +1,8 @@
Package: oqtaneabsolventenverein
Version: 1.0
Architecture: amd64
Essential: no
Priority: optional
Depends: aspnetcore-runtime-10.0,nginx,postgresql-18
Maintainer: kocoder
Description: Our production oqtane setup

2
DEBIAN/postinst Normal file
View File

@@ -0,0 +1,2 @@
#!/bin/bash
systemctl deamon-reload

2
DEBIAN/preinst Normal file
View File

@@ -0,0 +1,2 @@
#!/bin/bash
useradd oqtane

View File

@@ -0,0 +1,20 @@
[Unit]
Description=Alumnihub Webservice
[Service]
WorkingDirectory=/opt/oqtane
ExecStart=/usr/bin/dotnet /opt/oqtane/Oqtane.Server.dll
Restart=always
# Restart service after 10 seconds if the dotnet service crashes:
RestartSec=5
KillSignal=SIGINT
SyslogIdentifier=alumnihub
User=oqtane
Environment=ASPNETCORE_ENVIRONMENT=Production
Environment=ASPNETCORE_URLS="http://127.0.0.1:5000"
Environment=ASPNETCORE_FORWARDEDHEADERS_ENABLED=true
Environment=ASPNETCORE_FORWARDEDHEADERS_PROXIES=127.0.0.1
Environment=DOTNET_NOLOGO=true
[Install]
WantedBy=multi-user.target