mirror of
https://github.com/thiloho/nixos-config.git
synced 2025-11-22 11:31:36 +01:00
Add nginx for static websites
This commit is contained in:
53
flake.lock
generated
53
flake.lock
generated
@@ -1,5 +1,23 @@
|
||||
{
|
||||
"nodes": {
|
||||
"aurora-blog-template": {
|
||||
"inputs": {
|
||||
"nixpkgs": "nixpkgs"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1686592676,
|
||||
"narHash": "sha256-rUU3nwKtuQVUopwQ4ZVzfFujMqA9elih6BVugtpKAPQ=",
|
||||
"owner": "thiloho",
|
||||
"repo": "aurora",
|
||||
"rev": "0017fcdfa743a65a5fd4da8871f33425f7c84f28",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "thiloho",
|
||||
"repo": "aurora",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"home-manager": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
@@ -21,6 +39,21 @@
|
||||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1684787197,
|
||||
"narHash": "sha256-tvGDj3zgpW5NGoVKvoTQvkhfFPDgkbzfX+zFUW8NeHw=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "e2614d8ebcdf9a9eae0efe074f4d745d28595886",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1689282004,
|
||||
"narHash": "sha256-VNhuyb10c9SV+3hZOlxwJwzEGytZ31gN9w4nPCnNvdI=",
|
||||
@@ -38,8 +71,26 @@
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"aurora-blog-template": "aurora-blog-template",
|
||||
"home-manager": "home-manager",
|
||||
"nixpkgs": "nixpkgs"
|
||||
"nixpkgs": "nixpkgs_2",
|
||||
"website": "website"
|
||||
}
|
||||
},
|
||||
"website": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1690057185,
|
||||
"narHash": "sha256-Tcpi9P+7pEDC8/mJLOAuFJJf/ddXFjwmksoxRehm9FE=",
|
||||
"owner": "thiloho",
|
||||
"repo": "website",
|
||||
"rev": "993d7e0c7cf62477036b023bac766174e9f39970",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "thiloho",
|
||||
"repo": "website",
|
||||
"type": "github"
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
@@ -5,12 +5,18 @@
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||
home-manager.url = "github:nix-community/home-manager";
|
||||
home-manager.inputs.nixpkgs.follows = "nixpkgs";
|
||||
website = {
|
||||
url = "github:thiloho/website";
|
||||
flake = false;
|
||||
};
|
||||
aurora-blog-template.url = "github:thiloho/aurora";
|
||||
};
|
||||
|
||||
outputs = { nixpkgs, home-manager, ... }: {
|
||||
outputs = inputs@{ nixpkgs, home-manager, ... }: {
|
||||
nixosConfigurations = let
|
||||
mkSystem = entrypoint: nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
specialArgs = { inherit inputs; };
|
||||
modules = [
|
||||
entrypoint
|
||||
home-manager.nixosModules.home-manager
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
{ ... }:
|
||||
{ inputs, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
@@ -8,7 +8,8 @@
|
||||
|
||||
networking.hostName = "server";
|
||||
|
||||
services.minecraft-server = {
|
||||
services = {
|
||||
minecraft-server = {
|
||||
enable = true;
|
||||
eula = true;
|
||||
declarative = true;
|
||||
@@ -23,10 +24,20 @@
|
||||
white-list = true;
|
||||
};
|
||||
};
|
||||
|
||||
services.openssh = {
|
||||
openssh = {
|
||||
enable = true;
|
||||
settings.PasswordAuthentication = false;
|
||||
};
|
||||
nginx = {
|
||||
enable = true;
|
||||
virtualHosts = {
|
||||
"thilohohlt.com" = {
|
||||
root = inputs.website;
|
||||
locations."/" = {
|
||||
proxyPass = "http://localhost:1000";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
users.users.thiloho.openssh.authorizedKeys.keys = [
|
||||
|
||||
Reference in New Issue
Block a user