Compare commits

...

16 Commits

Author SHA1 Message Date
Yves Dubromelle
9bc50b35dd ajout de la machine pedro 2016-08-12 01:08:32 +02:00
Yves Dubromelle
1c649a9b04 les jeux ne sont plus activés systématiquements 2016-08-11 23:49:17 +02:00
Yves Dubromelle
7cb371510b ajustement des règles d'utilisation du cache 2016-08-11 23:47:50 +02:00
Yves Dubromelle
b38e5a87bb monstre est un client du cache nix 2016-08-11 23:44:05 +02:00
Yves Dubromelle
50326127d3 taeradan: ajout d'un mot de passe initial très compliqué 2016-08-11 23:32:00 +02:00
Yves Dubromelle
02a8b96e61 ajout d'utilisateurs avec mailbox 2016-08-11 23:30:24 +02:00
Yves Dubromelle
5e6586d403 rollo stocke les mails 2016-08-11 23:25:00 +02:00
Yves Dubromelle
b65ffa4d8f ajout option de configuration pour stocker les mails en boite 2016-08-11 23:08:33 +02:00
Yves Dubromelle
744ebec05b activation des comptes jpierre03 et taeradan sur toutes les machines 2016-08-11 22:58:15 +02:00
d1113bec00 script de lancement d'un serveur web pour les fichier munin 2016-08-11 22:09:16 +02:00
ef2733675d radx: désactivation de nix-serve 2016-08-11 21:51:43 +02:00
63902d313c radx n'est plus un serveur 2016-08-11 21:45:47 +02:00
0dc2561017 désactivation addresqse ipv6 temporaires 2016-08-11 21:27:06 +02:00
Yves Dubromelle
953021f306 option pour le proxy-cache nginx du nix store + actif sur monstre 2016-08-11 19:59:30 +02:00
Yves Dubromelle
c2da568c30 template d'un module nix façon r6d 2016-08-11 19:56:15 +02:00
bbfd76a4a1 ajout clef SSH pour root 2016-08-11 19:42:19 +02:00
6 changed files with 73 additions and 23 deletions

View File

@@ -5,20 +5,20 @@ let
profiles = config.r6d.profiles;
cfg = config.r6d.config-generator;
computers = config.r6d.computers;
in {
nix = mkIf config.r6d.config-generator.nix-serve-client {
in
mkIf cfg.nix-serve-client {
nix = {
# Cache http pour le store
requireSignedBinaryCaches = false;
binaryCaches = [
("https://cache.nixos.org/")
(mkIf (profiles.isDubronetwork && (! computers.isMonstre)) "http://192.168.10.169:5000")
(mkIf profiles.isDubronetwork "http://192.168.10.252:5000")
"https://cache.nixos.org/"
(mkIf (profiles.isDubronetwork && (! computers.isRollo)) "http://nix-cache.dubronetwork.fr:5001")
(mkIf (profiles.isPrunetwork && !profiles.isServer) "http://192.168.1.20:5000")
];
extraOptions = ''
connect-timeout = 5
connect-timeout = 5
'';
};
}
};
}

View File

@@ -23,13 +23,13 @@ in {
users.extraUsers.root = {
openssh.authorizedKeys.keys = [
radxJPierre03
radxRoot
phenomTaeradan
];
};
users.extraUsers.jpierre03 = mkIf profiles.isPrunetwork {
users.extraUsers.jpierre03 = {
isNormalUser = true;
createHome = true;
home = "/home/jpierre03";
description = "jpierre03";
extraGroups = [
"docker"
@@ -46,10 +46,10 @@ in {
];
};
users.extraUsers.taeradan = mkIf profiles.isDubronetwork {
users.extraUsers.taeradan = {
description = "Yves Dubromelle";
initialHashedPassword = "$6$yOBwZ.ijA$.eDknYZBxiGie88EUC8fYdpnSchKa8fMmjLglVk8c1gr23oAeb6rSBe8ID07frG5KlVSBqeMTuSoa/aONNp7b1";
isNormalUser = true;
#uid = 1000;
extraGroups = [
"audio"
"docker"
@@ -63,12 +63,33 @@ in {
];
};
users.extraUsers.lothy = mkIf (profiles.isDubronetwork && profiles.isDesktop) {
users.extraUsers.lothy = mkIf ( (cfg.mailboxes && profiles.isDubronetwork)
|| (profiles.isDesktop && profiles.isDubronetwork)
) {
description = "Ophélie Dubromelle-Lacroix";
isNormalUser = true;
extraGroups = [
"audio"
];
hashedPassword = "$6$vcZSVwQFcGg1xt$xuMiCmlozhgyFFGEw3rRnIrhVcglMlWY1lfJG17QoKE4KzrQfc9YAaJYgf.clc3ouFC/yLtEs18Q0DVGixTEt0";
};
}
users.extraUsers.alain = mkIf (cfg.mailboxes && profiles.isDubronetwork) {
description = "Alain Dubromelle";
isNormalUser = true;
hashedPassword = "$6$wGd7Inli$p4Q8BrkUSNCKfqloHtehFKKHQqVKVxul/oHWBY2BdqlFNt7N9MXuvVJZ2BOD747vQvAc2f07N8I8kD0n7x/o61";
uid = 1101;
};
users.extraUsers.dubromelle = mkIf (cfg.mailboxes && profiles.isDubronetwork) {
description = "Alain & Véro Dubromelle";
isNormalUser = true;
hashedPassword = "$6$Aa7rTIL7$M8zhtVsjPhkbNsY571K6bb04Y6cS04Z8RYKTIF3HoslelXplkphckauNep9gnc9mAp0p7o2lnQEVSoPw2UwT7/";
uid = 1102;
};
users.extraUsers.michele = mkIf (cfg.mailboxes && profiles.isDubronetwork) {
description = "Michele Dubromelle";
isNormalUser = true;
hashedPassword = "$6$RuwEVVml$JnSb62qFrtBJY1CfC9uE0YK2qd2TpnNmlXNeQ62ludb3mkV8AMUVEj3R9jTKtOfLt/ap6jGVmakotGtHczBHL/";
uid = 1103;
};
}

View File

@@ -46,9 +46,11 @@ in
jeux = mkEnableOption "Profil pour les jeux vidéos.";
laptop = mkEnableOption "Profil pour les outils spécifiques aux ordinateurs portables..";
locate = mkEnableOption "Profil pour activer la fonction locate.";
mailboxes = mkEnableOption "Profil pour stocker les mails dans des boîtes aux lettres.";
murmur = mkEnableOption "Profil pour activer un serveur Mumble (murmur)";
nix-serve-client= mkEnableOption "Profil pour que la machine soit un client de cache nix.";
nix-serve-server= mkEnableOption "Profil pour que la machine soit un serveur de cache nix.";
nixStoreProxyCache = mkEnableOption "Profil pour activer le proxy cahce nginx pour le nix store";
online-ipv6 = mkEnableOption "Profil pour activer l'IPv6 de online.net";
print = mkEnableOption "Profil pour activer cups & pouvoir imprimer.";
rabbitmq = mkEnableOption "Profil pour activer le service de messagerie AMQP.";
@@ -64,6 +66,7 @@ in
isNeoNomade = mkEnableOption "Identification du nom de machine.";
isNomade = mkEnableOption "Identification du nom de machine.";
isOcean = mkEnableOption "Identification du nom de machine.";
isPedro = mkEnableOption "Identification du nom de machine.";
isPhenom = mkEnableOption "Identification du nom de machine.";
isRadx = mkEnableOption "Identification du nom de machine.";
isRollo = mkEnableOption "Identification du nom de machine.";
@@ -84,6 +87,7 @@ in
isNeoNomade = host == "neo-nomade.dubronetwork.fr";
isNomade = host == "nomade.dubronetwork.fr";
isOcean = host == "ocean.prunetwork.fr";
isPedro = host == "pedro.dubronetwork.fr";
isPhenom = host == "phenom.dubronetwork.fr";
isRadx = host == "radx.prunetwork.fr";
isRollo = host == "rollo.dubronetwork.fr";
@@ -141,9 +145,6 @@ in
print = true;
};
})
(mkIf (pfl.isDubronetwork && pfl.isHome) {
r6d.config-generator.jeux = true;
})
(mkIf (pfl.isDubronetwork && pfl.isServer) {
r6d.config-generator.nix-serve-server = true;
})
@@ -180,12 +181,10 @@ in
r6d.profiles = {
isHome = true;
isPrunetwork = true;
isServer = true;
isWorkstation = true;
};
r6d.config-generator = {
nix-serve-server = true;
virtualbox = true;
};
})
@@ -213,7 +212,11 @@ in
isServer = true;
};
r6d.config-generator.fail2ban = true;
r6d.config-generator = {
fail2ban = true;
nix-serve-client = true;
nixStoreProxyCache = true;
};
})
(mkIf comp.isNeoNomade{
r6d.profiles = {
@@ -232,6 +235,17 @@ in
laptop = true;
};
})
(mkIf comp.isPedro {
r6d.profiles = {
isDubronetwork = true;
isServer = true;
};
r6d.config-generator = {
fail2ban = true;
online-ipv6 = true;
};
})
(mkIf comp.isPhenom {
r6d.profiles = {
isDubronetwork = true;
@@ -252,6 +266,7 @@ in
r6d.config-generator = {
dovecot = true;
fail2ban = true;
mailboxes = true;
murmur = true;
online-ipv6 = true;
znc = true;

11
module-template.nix Normal file
View File

@@ -0,0 +1,11 @@
{ config, lib, pkgs, ... }:
let
inherit (lib) mkIf;
cfg = config.r6d.config-generator;
computers = config.r6d.computers;
profiles = config.r6d.profiles;
in
mkIf true {
}

3
munin-www.sh Executable file
View File

@@ -0,0 +1,3 @@
#!/usr/bin/env bash
pushd /var/www/munin/ && python -m SimpleHTTPServer 8000

View File

@@ -5,7 +5,7 @@
# installées systématiquement
./environment.nix
./localisation.nix
./network-ipv6.nix
#./network-ipv6.nix
./service-haveged.nix
./service-monitoring.nix
./service-ssh.nix