Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
APic
nixos-deployment
Commits
26d8c90a
Commit
26d8c90a
authored
Jan 19, 2022
by
fpletz
🚧
Browse files
adjust nginx config
parent
fe8ef4bc
Changes
2
Hide whitespace changes
Inline
Side-by-side
flake.nix
View file @
26d8c90a
...
...
@@ -27,6 +27,7 @@
time
.
timeZone
=
"UTC"
;
boot
.
kernelPackages
=
pkgs
.
linuxPackages_latest
;
boot
.
tmpOnTmpfs
=
true
;
environment
.
systemPackages
=
with
pkgs
;
[
wget
curl
htop
iftop
tmux
tcpdump
rsync
alacritty
.
terminfo
...
...
@@ -43,6 +44,20 @@
services
.
openssh
.
enable
=
true
;
services
.
fail2ban
.
enable
=
true
;
services
.
nginx
=
{
package
=
pkgs
.
nginxMainline
;
recommendedOptimisation
=
true
;
recommendedTlsSettings
=
true
;
recommendedGzipSettings
=
true
;
recommendedProxySettings
=
true
;
appendHttpConfig
=
''
access_log syslog:server=unix:/dev/log;
''
;
appendConfig
=
''
error_log stderr info;
''
;
};
zramSwap
.
enable
=
true
;
nixpkgs
.
system
=
"x86_64-linux"
;
nixpkgs
.
overlays
=
[
muccc-api
.
overlay
];
...
...
nixbus.nix
View file @
26d8c90a
...
...
@@ -125,9 +125,18 @@
virtualHosts
.
"nixbus.club.muc.ccc.de"
=
{
enableACME
=
true
;
addSSL
=
true
;
locations
.
"/"
.
extraConfig
=
"return 204;"
;
locations
.
"/spaceapi.json"
.
proxyPass
=
"http://[::1]:8020"
;
locations
.
"/schleuse.json"
.
proxyPass
=
"http://[::1]:8020"
;
locations
.
"/"
.
extraConfig
=
"return 404;"
;
locations
.
"/api/"
=
{
proxyPass
=
"http://[::1]:8020/"
;
#extraConfig = ''
# set_real_ip_from 83.133.178.64/26;
# set_real_ip_from 2001:7f0:3003:beef::/64;
# real_ip_header X-Forwarded-For;
#'';
};
};
virtualHosts
.
"api.muc.ccc.de"
=
{
locations
.
"/"
.
proxyPass
=
"http://[::1]:8020"
;
};
};
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment