From 9f96f8d62c386c7afe9d269ecdfd7ced4beb29e1 Mon Sep 17 00:00:00 2001 From: Alexandre LUCAZEAU Date: Thu, 9 Mar 2023 22:11:40 +0100 Subject: [PATCH] =?UTF-8?q?=09modifi=C3=A9=C2=A0:=20=20=20=20=20=20=20=20?= =?UTF-8?q?=20../dell-5590/nixos/vpn.nix=20=09modifi=C3=A9=C2=A0:=20=20=20?= =?UTF-8?q?=20=20=20=20=20=20../dell-5590/nixpkgs/configs/init.el=20=09mod?= =?UTF-8?q?ifi=C3=A9=C2=A0:=20=20=20=20=20=20=20=20=20../dell-5590/nixpkgs?= =?UTF-8?q?/emacs.nix=20=09modifi=C3=A9=C2=A0:=20=20=20=20=20=20=20=20=20n?= =?UTF-8?q?extcloud.nix?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- hosts/dell-5590/nixos/vpn.nix | 20 +++++++++++++------- hosts/dell-5590/nixpkgs/configs/init.el | 10 ++++++++++ hosts/dell-5590/nixpkgs/emacs.nix | 5 ++++- hosts/next/nextcloud.nix | 7 +++++++ 4 files changed, 34 insertions(+), 8 deletions(-) diff --git a/hosts/dell-5590/nixos/vpn.nix b/hosts/dell-5590/nixos/vpn.nix index 14e694a..f58e218 100644 --- a/hosts/dell-5590/nixos/vpn.nix +++ b/hosts/dell-5590/nixos/vpn.nix @@ -1,9 +1,15 @@ -{ pkgs, ... }: { - services.openvpn.servers = { - DRI = { config = '' config /home/alexandre/git/nixos-config/hosts/dell-5590/nixpkgs/VPN.conf ''; }; +{ pkgs, lib, config, ... }: +{ +environment.systemPackages = [ pkgs.openvpn_24 ]; + services.openvpn = { + servers = { + DRI = { + config = "config /home/alexandre/VPN/Serveur_VPN_pour_le_SI_DRI_alexandre_admin.ovpn"; + updateResolvConf = true; + up = "ip route add default gw 192.168.248.73\nroute add -host 185.86.178.201 dev wlp2s0 gw 192.168.1.1\necho nameserver $nameserver | ${pkgs.openresolv}/sbin/resolvconf -m 0 -a $dev"; + down = "ip route del default gw 192.168.248.73\nroute del -host 185.86.178.201 dev wlp2s0 gw 192.168.1.1\n${pkgs.openresolv}/sbin/resolvconf -d $dev"; + }; + }; }; -nixpkgs.config.allowUnfree = true; - virtualisation.virtualbox.host.enable = true; - virtualisation.virtualbox.host.enableExtensionPack = true; - users.extraGroups.vboxusers.members = [ "alexandre" ]; } + diff --git a/hosts/dell-5590/nixpkgs/configs/init.el b/hosts/dell-5590/nixpkgs/configs/init.el index c82c560..8056942 100644 --- a/hosts/dell-5590/nixpkgs/configs/init.el +++ b/hosts/dell-5590/nixpkgs/configs/init.el @@ -212,3 +212,13 @@ (setq org-journal-dir "~/Nextcloud/PRIVE/13_Org/journal/") (global-set-key "\C-cnj" 'org-journal-new-entry) (require 'org-journal) + +;; tab bar +(when (< 26 emacs-major-version) + (tab-bar-mode 1) ;; enable tab bar + (setq tab-bar-show 1) ;; hide bar if <= 1 tabs open + (setq tab-bar-close-button-show nil) ;; hide tab close / X button + (setq tab-bar-new-tab-choice "*dashboard*");; buffer to show in new tabs + (setq tab-bar-tab-hints t) ;; show tab numbers + (setq tab-bar-format '(tab-bar-format-tabs tab-bar-separator))) + ;; elements to include in bar diff --git a/hosts/dell-5590/nixpkgs/emacs.nix b/hosts/dell-5590/nixpkgs/emacs.nix index 5dafe00..83fb028 100644 --- a/hosts/dell-5590/nixpkgs/emacs.nix +++ b/hosts/dell-5590/nixpkgs/emacs.nix @@ -1,6 +1,9 @@ -{ ... }: +{ pkgs, ... }: { +home.packages = with pkgs; [ + multimarkdown + ]; services.emacs.enable = true; programs.emacs = { enable = true; diff --git a/hosts/next/nextcloud.nix b/hosts/next/nextcloud.nix index 8204c14..440b42a 100644 --- a/hosts/next/nextcloud.nix +++ b/hosts/next/nextcloud.nix @@ -30,6 +30,13 @@ services.nginx = { proxyPass = "http://127.0.0.1:${toString config.services.navidrome.settings.Port}/"; proxyWebsockets = true; }; + "bookmark.atlanticaweb.fr" = { + forceSSL = true; + enableACME = true; + locations."/" = { + proxyPass = "http://127.0.0.1:8080/"; + proxyWebsockets = true; + }; }; }; };