Compare commits

...

10 Commits

Author SHA1 Message Date
3fb43a4015
disable gitea reg 2024-06-05 18:47:31 +02:00
549c644692
move to stable 2024-06-05 18:32:01 +02:00
4a182da517
update 2024-06-03 12:26:27 +02:00
095295b8ee
timezone 2024-06-03 09:36:47 +02:00
16f603559e enable angie with status monitoring 2024-05-17 14:07:48 +03:00
850bac20e3 remove this - doesn't work with nginx 2024-05-16 17:02:14 +03:00
8b396298db add pic to nginx 2024-04-22 00:09:48 +03:00
d14a5acc47 bingwp on server 2024-04-21 23:54:04 +03:00
ca04cd034d update 2024-04-21 22:27:39 +03:00
0fac9baa38 update 2024-04-18 21:03:50 +03:00
5 changed files with 358 additions and 69 deletions

View File

@ -16,6 +16,30 @@
"type": "gitlab"
}
},
"devshell": {
"inputs": {
"flake-utils": "flake-utils_3",
"nixpkgs": [
"webshite",
"ide",
"nixvim",
"nixpkgs"
]
},
"locked": {
"lastModified": 1713532798,
"narHash": "sha256-wtBhsdMJA3Wa32Wtm1eeo84GejtI43pMrFrmwLXrsEc=",
"owner": "numtide",
"repo": "devshell",
"rev": "12e914740a25ea1891ec619bb53cf5e6ca922e40",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "devshell",
"type": "github"
}
},
"flake-compat": {
"flake": false,
"locked": {
@ -35,11 +59,41 @@
"flake-compat_2": {
"flake": false,
"locked": {
"lastModified": 1673956053,
"narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=",
"lastModified": 1696426674,
"narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
"owner": "edolstra",
"repo": "flake-compat",
"rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9",
"rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
"type": "github"
},
"original": {
"owner": "edolstra",
"repo": "flake-compat",
"type": "github"
}
},
"flake-compat_3": {
"locked": {
"lastModified": 1696426674,
"narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
"rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
"revCount": 57,
"type": "tarball",
"url": "https://api.flakehub.com/f/pinned/edolstra/flake-compat/1.0.1/018afb31-abd1-7bff-a5e4-cff7e18efb7a/source.tar.gz"
},
"original": {
"type": "tarball",
"url": "https://flakehub.com/f/edolstra/flake-compat/1.tar.gz"
}
},
"flake-compat_4": {
"flake": false,
"locked": {
"lastModified": 1696426674,
"narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
"owner": "edolstra",
"repo": "flake-compat",
"rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
"type": "github"
},
"original": {
@ -53,16 +107,16 @@
"nixpkgs-lib": [
"webshite",
"ide",
"nixvim",
"neovim-nightly-overlay",
"nixpkgs"
]
},
"locked": {
"lastModified": 1704152458,
"narHash": "sha256-DS+dGw7SKygIWf9w4eNBUZsK+4Ug27NwEWmn2tnbycg=",
"lastModified": 1714641030,
"narHash": "sha256-yzcRNDoyVP7+SCNX0wmuDju1NUCt8Dz9+lyUXEI0dbI=",
"owner": "hercules-ci",
"repo": "flake-parts",
"rev": "88a2cd8166694ba0b6cb374700799cec53aef527",
"rev": "e5d10a24b66c3ea8f150e47dfdb0416ab7c3390e",
"type": "github"
},
"original": {
@ -71,6 +125,67 @@
"type": "github"
}
},
"flake-parts_2": {
"inputs": {
"nixpkgs-lib": [
"webshite",
"ide",
"neovim-nightly-overlay",
"hercules-ci-effects",
"nixpkgs"
]
},
"locked": {
"lastModified": 1712014858,
"narHash": "sha256-sB4SWl2lX95bExY2gMFG5HIzvva5AVMJd4Igm+GpZNw=",
"owner": "hercules-ci",
"repo": "flake-parts",
"rev": "9126214d0a59633752a136528f5f3b9aa8565b7d",
"type": "github"
},
"original": {
"id": "flake-parts",
"type": "indirect"
}
},
"flake-parts_3": {
"inputs": {
"nixpkgs-lib": [
"webshite",
"ide",
"nixvim",
"nixpkgs"
]
},
"locked": {
"lastModified": 1715865404,
"narHash": "sha256-/GJvTdTpuDjNn84j82cU6bXztE0MSkdnTWClUCRub78=",
"owner": "hercules-ci",
"repo": "flake-parts",
"rev": "8dc45382d5206bd292f9c2768b8058a8fd8311d9",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "flake-parts",
"type": "github"
}
},
"flake-root": {
"locked": {
"lastModified": 1713493429,
"narHash": "sha256-ztz8JQkI08tjKnsTpfLqzWoKFQF4JGu2LRz8bkdnYUk=",
"owner": "srid",
"repo": "flake-root",
"rev": "bc748b93b86ee76e2032eecda33440ceb2532fcd",
"type": "github"
},
"original": {
"owner": "srid",
"repo": "flake-root",
"type": "github"
}
},
"flake-utils": {
"inputs": {
"systems": [
@ -80,11 +195,11 @@
]
},
"locked": {
"lastModified": 1701680307,
"narHash": "sha256-kAuep2h5ajznlPMD9rnQyffWG8EM/C73lejGofXvdM8=",
"lastModified": 1710146030,
"narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "4022d587cbbfd70fe950c1e2083a02621806a725",
"rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a",
"type": "github"
},
"original": {
@ -98,11 +213,29 @@
"systems": "systems_2"
},
"locked": {
"lastModified": 1685518550,
"narHash": "sha256-o2d0KcvaXzTrPRIo0kOLV0/QXHhDQ5DTi+OxcjO8xqY=",
"lastModified": 1710146030,
"narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "a1720a10a6cfe8234c0e93907ffe81be440f4cef",
"rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"flake-utils_3": {
"inputs": {
"systems": "systems_3"
},
"locked": {
"lastModified": 1701680307,
"narHash": "sha256-kAuep2h5ajznlPMD9rnQyffWG8EM/C73lejGofXvdM8=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "4022d587cbbfd70fe950c1e2083a02621806a725",
"type": "github"
},
"original": {
@ -122,11 +255,11 @@
]
},
"locked": {
"lastModified": 1660459072,
"narHash": "sha256-8DFJjXG8zqoONA1vXtgeKXy68KdJL5UaXR8NtVMUbx8=",
"lastModified": 1709087332,
"narHash": "sha256-HG2cCnktfHsKV0s4XW83gU3F57gaTljL9KNSuG6bnQs=",
"owner": "hercules-ci",
"repo": "gitignore.nix",
"rev": "a20de23b925fd8264fd7fad6454652e142fd7f73",
"rev": "637db329424fd7e46cf4185293b9cc8c88c95394",
"type": "github"
},
"original": {
@ -135,6 +268,30 @@
"type": "github"
}
},
"hercules-ci-effects": {
"inputs": {
"flake-parts": "flake-parts_2",
"nixpkgs": [
"webshite",
"ide",
"neovim-nightly-overlay",
"nixpkgs"
]
},
"locked": {
"lastModified": 1713898448,
"narHash": "sha256-6q6ojsp/Z9P2goqnxyfCSzFOD92T3Uobmj8oVAicUOs=",
"owner": "hercules-ci",
"repo": "hercules-ci-effects",
"rev": "c0302ec12d569532a6b6bd218f698bc402e93adc",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "hercules-ci-effects",
"type": "github"
}
},
"home-manager": {
"inputs": {
"nixpkgs": [
@ -145,11 +302,11 @@
]
},
"locked": {
"lastModified": 1704498488,
"narHash": "sha256-yINKdShHrtjdiJhov+q0s3Y3B830ujRoSbHduUNyKag=",
"lastModified": 1715930644,
"narHash": "sha256-W9pyM3/vePxrffHtzlJI6lDS3seANQ+Nqp+i58O46LI=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "51e44a13acea71b36245e8bd8c7db53e0a3e61ee",
"rev": "e3ad5108f54177e6520535768ddbf1e6af54b59d",
"type": "github"
},
"original": {
@ -165,11 +322,11 @@
]
},
"locked": {
"lastModified": 1712248646,
"narHash": "sha256-pEiprVaO6CmIJ1qJMQn/y8vHvRQwiQq7CwbhzlneCOA=",
"lastModified": 1717449440,
"narHash": "sha256-QtSCQFBhyQIsKJhOvcIOi+9EN1kEnNeoLo3PeQ5VbIY=",
"owner": "StevenBlack",
"repo": "hosts",
"rev": "a340ebf0b8e9f81476c0ec0b6a9767858aea325c",
"rev": "e1a7b23e9769607009d741066b5789a99aaf9923",
"type": "github"
},
"original": {
@ -181,19 +338,20 @@
"ide": {
"inputs": {
"flake-utils": "flake-utils",
"neovim-nightly-overlay": "neovim-nightly-overlay",
"nixpkgs": [
"webshite",
"nixpkgs"
],
"nixvim": "nixvim",
"systems": "systems_3"
"systems": "systems_4"
},
"locked": {
"lastModified": 1703277278,
"narHash": "sha256-5jd20XohKDc+GEtNiyIL5C+Hj5g1fhAY/ADkSZrzuEo=",
"lastModified": 1716893760,
"narHash": "sha256-fI3Q8DpkSerjQ37pXBW9ZHKDQQVYfG5stDMw7n9No10=",
"owner": "ivandimitrov8080",
"repo": "flake-ide",
"rev": "5ed5ccc63037342cf9d535ea3f1a814da224ec6a",
"rev": "eb5e62023fcf8ccab169a313a66ccdc7ff8a3319",
"type": "github"
},
"original": {
@ -202,6 +360,58 @@
"type": "github"
}
},
"neovim-flake": {
"inputs": {
"flake-utils": "flake-utils_2",
"nixpkgs": [
"webshite",
"ide",
"neovim-nightly-overlay",
"nixpkgs"
]
},
"locked": {
"dir": "contrib",
"lastModified": 1715815279,
"narHash": "sha256-Pf7ZlqPnr195NZb5ADzMVsXurPMjRZ+JMXf6JxvXArE=",
"owner": "neovim",
"repo": "neovim",
"rev": "9ca81b025990911c2a0dbda92af39ba84983bac3",
"type": "github"
},
"original": {
"dir": "contrib",
"owner": "neovim",
"repo": "neovim",
"type": "github"
}
},
"neovim-nightly-overlay": {
"inputs": {
"flake-compat": "flake-compat_2",
"flake-parts": "flake-parts",
"hercules-ci-effects": "hercules-ci-effects",
"neovim-flake": "neovim-flake",
"nixpkgs": [
"webshite",
"ide",
"nixpkgs"
]
},
"locked": {
"lastModified": 1715817852,
"narHash": "sha256-UH5o7hT72oAavJTG2NxlpMyQe3BQMniQAsgTugWtlc4=",
"owner": "nix-community",
"repo": "neovim-nightly-overlay",
"rev": "7b5ca2486bba58cac80b9229209239740b67cf90",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "neovim-nightly-overlay",
"type": "github"
}
},
"nix-darwin": {
"inputs": {
"nixpkgs": [
@ -212,11 +422,11 @@
]
},
"locked": {
"lastModified": 1704277720,
"narHash": "sha256-meAKNgmh3goankLGWqqpw73pm9IvXjEENJloF0coskE=",
"lastModified": 1715901937,
"narHash": "sha256-eMyvWP56ZOdraC2IOvZo0/RTDcrrsqJ0oJWDC76JTak=",
"owner": "lnl7",
"repo": "nix-darwin",
"rev": "0dd382b70c351f528561f71a0a7df82c9d2be9a4",
"rev": "ffc01182f90118119930bdfc528c1ee9a39ecef8",
"type": "github"
},
"original": {
@ -227,19 +437,26 @@
},
"nixpkgs": {
"locked": {
"lastModified": 0,
"narHash": "sha256-ER6N232jucnqu4+AK80RdmgBDuk61FAqmp36EMqkQns=",
"path": "/nix/store/8dlqxmnbaz3kgk8j5l7zz0zkz2h9x18b-source",
"type": "path"
"lastModified": 1717281328,
"narHash": "sha256-evZPzpf59oNcDUXxh2GHcxHkTEG4fjae2ytWP85jXRo=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "b3b2b28c1daa04fe2ae47c21bb76fd226eac4ca1",
"type": "github"
},
"original": {
"id": "nixpkgs",
"type": "indirect"
"owner": "NixOS",
"ref": "nixos-24.05",
"repo": "nixpkgs",
"type": "github"
}
},
"nixvim": {
"inputs": {
"flake-parts": "flake-parts",
"devshell": "devshell",
"flake-compat": "flake-compat_3",
"flake-parts": "flake-parts_3",
"flake-root": "flake-root",
"home-manager": "home-manager",
"nix-darwin": "nix-darwin",
"nixpkgs": [
@ -247,14 +464,15 @@
"ide",
"nixpkgs"
],
"pre-commit-hooks": "pre-commit-hooks"
"pre-commit-hooks": "pre-commit-hooks",
"treefmt-nix": "treefmt-nix"
},
"locked": {
"lastModified": 1704716895,
"narHash": "sha256-j3MwWzaOX32v5RIYu2zSSnWFc6NheWNN1p6ngEDu0sA=",
"lastModified": 1716326274,
"narHash": "sha256-1LyTvpjb8Cmlg3TRnP56rvqK1WSNa518pD6F0tjgM+U=",
"owner": "nix-community",
"repo": "nixvim",
"rev": "0f1c0bda6dad29b2609cafcea512866b86aa2be5",
"rev": "5d2e01495944dcf7cf7ee53a7074c4010165d756",
"type": "github"
},
"original": {
@ -265,8 +483,7 @@
},
"pre-commit-hooks": {
"inputs": {
"flake-compat": "flake-compat_2",
"flake-utils": "flake-utils_2",
"flake-compat": "flake-compat_4",
"gitignore": "gitignore",
"nixpkgs": [
"webshite",
@ -282,11 +499,11 @@
]
},
"locked": {
"lastModified": 1704668415,
"narHash": "sha256-BMzNHFod53iiU4lkR5WHwqQCFmaCLq85sUCskXneXlA=",
"lastModified": 1715870890,
"narHash": "sha256-nacSOeXtUEM77Gn0G4bTdEOeFIrkCBXiyyFZtdGwuH0=",
"owner": "cachix",
"repo": "pre-commit-hooks.nix",
"rev": "44493e2b3c3ebcd39a9947e9ed9f2c2af164ec4c",
"rev": "fa606cccd7b0ccebe2880051208e4a0f61bfc8c1",
"type": "github"
},
"original": {
@ -314,11 +531,11 @@
"utils": "utils"
},
"locked": {
"lastModified": 1710449465,
"narHash": "sha256-2orO8nfplp6uQJBFqKkj1iyNMC6TysmwbWwbb4osTag=",
"lastModified": 1717515088,
"narHash": "sha256-nWOLpPA7+k7V1OjXTuxdsVd5jeeI0b13Di57wvnqkic=",
"owner": "simple-nixos-mailserver",
"repo": "nixos-mailserver",
"rev": "79c8cfcd5873a85559da6201b116fb38b490d030",
"rev": "0d51a32e4799d081f260eb4db37145f5f4ee7456",
"type": "gitlab"
},
"original": {
@ -358,6 +575,21 @@
}
},
"systems_3": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
},
"systems_4": {
"locked": {
"lastModified": 1680978846,
"narHash": "sha256-Gtqg8b/v49BFDpDetjclCYXm8mAnTrUzR0JnE2nv5aw=",
@ -372,6 +604,29 @@
"type": "github"
}
},
"treefmt-nix": {
"inputs": {
"nixpkgs": [
"webshite",
"ide",
"nixvim",
"nixpkgs"
]
},
"locked": {
"lastModified": 1715940852,
"narHash": "sha256-wJqHMg/K6X3JGAE9YLM0LsuKrKb4XiBeVaoeMNlReZg=",
"owner": "numtide",
"repo": "treefmt-nix",
"rev": "2fba33a182602b9d49f0b2440513e5ee091d838b",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "treefmt-nix",
"type": "github"
}
},
"utils": {
"inputs": {
"systems": "systems"
@ -392,11 +647,11 @@
},
"vpsadminos": {
"locked": {
"lastModified": 1710939796,
"narHash": "sha256-orqxOKTrTaidPcbrhcK+xFsr4Atk/VwgpxiotIH9nK8=",
"lastModified": 1717573966,
"narHash": "sha256-HexNxrosL7s5QLDwHjPC1EbZLXLicBkPR7CLZJ98MF8=",
"owner": "vpsfreecz",
"repo": "vpsadminos",
"rev": "a6146289ad8a157cf3c728a6891a544358ca77d0",
"rev": "13f3c04e6a936c68028d452088e2041604818eac",
"type": "github"
},
"original": {
@ -413,17 +668,17 @@
]
},
"locked": {
"lastModified": 1709751090,
"narHash": "sha256-+q2tYFeKLkENu3ewkKTDRBe8eA7ypLBcdVNae8uNwIc=",
"ref": "refs/heads/nextjs",
"rev": "8653fd926b7fe2fc8932f0ec48d197a555c4e8e1",
"revCount": 74,
"type": "git",
"url": "https://src.idimitrov.dev/ivan/idimitrov.dev"
"lastModified": 1717409503,
"narHash": "sha256-6I44fydcPN8Z6U3jE10cmtB6IvWX0gFe1nC4YFFOuig=",
"owner": "ivandimitrov8080",
"repo": "idimitrov.dev",
"rev": "5680cf73164b2b0189a9d607de99566acac205d0",
"type": "github"
},
"original": {
"type": "git",
"url": "https://src.idimitrov.dev/ivan/idimitrov.dev"
"owner": "ivandimitrov8080",
"repo": "idimitrov.dev",
"type": "github"
}
}
},

View File

@ -1,12 +1,12 @@
{
inputs = {
nixpkgs.url = "nixpkgs";
nixpkgs.url = "github:NixOS/nixpkgs/nixos-24.05";
simple-nixos-mailserver = {
url = "gitlab:simple-nixos-mailserver/nixos-mailserver";
inputs.nixpkgs.follows = "nixpkgs";
};
webshite = {
url = "git+https://src.idimitrov.dev/ivan/idimitrov.dev";
url = "github:ivandimitrov8080/idimitrov.dev";
inputs.nixpkgs.follows = "nixpkgs";
};
vpsadminos.url = "github:vpsfreecz/vpsadminos";
@ -17,8 +17,7 @@
};
outputs =
{ self
, nixpkgs
{ nixpkgs
, simple-nixos-mailserver
, vpsadminos
, webshite
@ -36,7 +35,7 @@
{
nixosConfigurations = {
inherit system;
mailserver = nixpkgs.lib.nixosSystem rec {
mailserver = nixpkgs.lib.nixosSystem {
modules = [
vpsadminos.nixosConfigurations.container
simple-nixos-mailserver.nixosModule

View File

@ -1,6 +1,6 @@
{ config, pkgs, lib, ... }:
{ pkgs, ... }:
{
time.timeZone = "Europe/Sofia";
time.timeZone = "Europe/Prague";
system.stateVersion = "23.11";
nix = {
@ -56,4 +56,23 @@
};
};
};
systemd = {
timers = {
bingwp = {
wantedBy = [ "timers.target" ];
timerConfig = {
OnCalendar = "*-*-* 10:00:00";
Persistent = true;
};
};
};
services = {
bingwp = {
description = "Download bing image of the day";
script = ''
${pkgs.nushell}/bin/nu -c "http get ('https://bing.com' + ((http get https://www.bing.com/HPImageArchive.aspx?format=js&n=1).images.0.url)) | save ('/var/pic' | path join ( [ (date now | format date '%Y-%m-%d'), '.png' ] | str join ))"
'';
};
};
};
}

View File

@ -1,8 +1,8 @@
{ config, pkgs, ... }:
{ ... }:
{
services.gitea = {
enable = true;
appName = "idimitrov: Gitea";
appName = "src";
database = {
type = "postgres";
};
@ -15,6 +15,9 @@
repository = {
DEFAULT_BRANCH = "master";
};
service = {
DISABLE_REGISTRATION = true;
};
};
};
}

View File

@ -16,6 +16,7 @@ in
services = {
nginx = {
enable = true;
package = pkgs.angieQuic;
recommendedGzipSettings = true;
recommendedOptimisation = true;
recommendedProxySettings = true;
@ -48,6 +49,18 @@ in
proxyPass = "http://127.0.0.1:3001";
};
};
"status.idimitrov.dev" = {
enableACME = true;
forceSSL = true;
root = "${pkgs.angie-console-light}/share/angie-console-light/html";
extraConfig = restrictToVpn;
locations."/" = { };
locations."/api/" = {
extraConfig = ''
api /status/;
'';
};
};
};
};
};