0 Votes

Code source wiki de Raspberry Pi

Version 7.1 par john le 2026/09/20 01:08

Masquer les derniers auteurs
john 2.1 1 {{info}}
john 7.1 2 **Pages détaillées**
3
4 Services : [[AdGuard Home>>Wiki Batcave John.Infrastructure.RaspberryPi.AdGuard Home.WebHome]] · [[Meshtastic>>Wiki Batcave John.Infrastructure.RaspberryPi.Meshtastic.WebHome]] · [[Jellyfin>>Wiki Batcave John.Infrastructure.RaspberryPi.Jellyfin.WebHome]] · [[OLED Stats>>Wiki Batcave John.Infrastructure.RaspberryPi.OLEDStats.WebHome]] · [[led-anim>>Wiki Batcave John.Infrastructure.RaspberryPi.led-anim.WebHome]]
5
6 Système : [[SSD de stockage>>Wiki Batcave John.Infrastructure.RaspberryPi.SSD.WebHome]] · [[fail2ban>>Wiki Batcave John.Infrastructure.RaspberryPi.fail2ban.WebHome]] · [[chkrootkit>>Wiki Batcave John.Infrastructure.RaspberryPi.chkrootkit.WebHome]]
john 2.1 7 {{/info}}
8
john 1.1 9 == Système ==
10
11 |=Élément|=Valeur
12 |Machine|Raspberry Pi 4
13 |OS|Debian 13, sans environnement graphique
14 |Cible systemd|##multi-user.target##
15 |Réseau|Wi-Fi
16 |Stockage des sauvegardes|SSD USB
17
18 == Services ==
19
20 === Conteneurs ===
21
22 |=Service|=Rôle
23 |AdGuard Home|DNS local, blocage, réécriture DNS
24 |OLED Stats|Statistiques sur l'écran OLED du boîtier
25 |Portainer + Portainer Agent|Gestion Docker
26 |Watchtower|Mise à jour automatique des images
27
28 === Natifs ===
29
30 |=Service|=Rôle
31 |meshtasticd|Nœud Meshtastic LoRa (HAT SX1262 en SPI)
32 |Jellyfin|Serveur multimédia
33 |fail2ban|Blocage des tentatives SSH
34 |smartmontools|Surveillance du SSD
35 |sysstat, acct|Statistiques système, comptabilité des processus
36 |chkrootkit, Lynis|Audit nocturne par timer
37 |led-anim|Animation du bandeau LED
38
39 == Outils ==
40
41 Plakar (dépôt), uhubctl, yt-dlp et client meshtastic (pipx), outils RTL-SDR.
42
43 == Configuration ==
44
45 === Wi-Fi : désactiver l'économie d'énergie ===
46
47 Le lien décroche sur les gros transferts SFTP quand l'économie d'énergie est active :
48
49 {{code language="bash"}}
50 sudo nmcli connection modify "<SSID>" 802-11-wireless.powersave 2
51 sudo nmcli connection up "<SSID>"
52 {{/code}}
53
54 === SSD USB sur pont ASMedia ===
55
56 Le pont se déconnecte sous forte charge en mode UAS. Forcer le mode usb-storage en ajoutant à la ligne unique de ##/boot/firmware/cmdline.txt## (identifiants donnés par ##lsusb##) :
57
58 {{code}}
59 usb-storage.quirks=<VID>:<PID>:u
60 {{/code}}
61
62 Montage à la demande dans ##/etc/fstab##, sans bloquer le démarrage si le disque est absent :
63
64 {{code}}
65 UUID=<UUID> <POINT_MONTAGE> <FS> defaults,nofail,x-systemd.automount 0 2
66 {{/code}}
67
68 Empêcher l'écriture sur la carte SD quand le SSD n'est pas monté (à faire sur le point de montage vide) :
69
70 {{code language="bash"}}
71 sudo chattr +i <POINT_MONTAGE>
72 {{/code}}
73
74 === SPI pour le module LoRa ===
75
76 Dans ##/boot/firmware/config.txt## :
77
78 {{code language="ini"}}
79 dtparam=spi=on
80 dtoverlay=spi0-0cs
81 {{/code}}
82
83 === meshtasticd ===
84
85 Les réglages vont dans ##/etc/meshtasticd/config.d/## : ces fichiers survivent aux mises à jour du paquet, contrairement à ##config.yaml##.
86
87 ##99-lora.yaml##, valeurs pour le HAT Waveshare SX126X :
88
89 {{code language="yaml"}}
90 Lora:
91 Module: sx1262
92 DIO2_AS_RF_SWITCH: true
93 CS: 21
94 IRQ: 16
95 Busy: 20
96 Reset: 18
97 SX126X_ANT_SW: 6
98 {{/code}}
99
100 ##98-webserver.yaml## :
101
102 {{code language="yaml"}}
103 Webserver:
104 Port: 443
105 RootPath: /usr/share/meshtasticd/web
106 {{/code}}
107
108 === Outils Python ===
109
110 {{code language="bash"}}
111 sudo apt install pipx
112 pipx install meshtastic
113 pipx install yt-dlp
114 pipx ensurepath
115 {{/code}}
116
117 Mise à jour : ##pipx upgrade-all##.
118
119 === led-anim ===
john 6.1 120
john 5.1 121 Voir la page [[led-anim>>Wiki Batcave John.Infrastructure.RaspberryPi.led-anim.WebHome]].
john 1.1 122
123 === Portainer Agent ===
124
125 L'agent doit être à la même version que le Portainer qui le pilote : épingler son tag sur celui du serveur plutôt que ##latest##.
126
127 === Services désactivés ===
128
129 ModemManager (sonde les ports série et peut perturber un nœud Meshtastic en USB), bluetooth, hciuart.