From 876d0a6ff596f2507424375a57ed55cb3f7bc6a1 Mon Sep 17 00:00:00 2001 From: Djeex Date: Sun, 10 Aug 2025 22:59:47 +0000 Subject: [PATCH] Better sh hl --- README.md | 8 ++-- assets/css/extra.css | 16 +++++++ content/2.general/1.networking/3.samba.md | 44 +++++++++---------- content/3.serveex/2.core/1.installation.md | 10 ++--- content/3.serveex/2.core/2.docker.md | 14 +++--- content/3.serveex/2.core/3.swag.md | 12 ++--- content/3.serveex/3.security/1.wireguard.md | 14 +++--- content/3.serveex/3.security/2.authentik.md | 36 +++++++-------- content/3.serveex/3.security/3.cloudflare.md | 4 +- .../3.serveex/4.monitoring/1.uptime-kuma.md | 4 +- content/3.serveex/4.monitoring/2.dozzle.md | 4 +- .../4.monitoring/3.speedtest-tracker.md | 8 ++-- content/3.serveex/4.monitoring/4.beszel.md | 4 +- content/3.serveex/4.monitoring/5.upsnap.md | 4 +- content/3.serveex/5.media/1.plex.md | 6 +-- content/3.serveex/5.media/2.qbittorrent.md | 10 ++--- content/3.serveex/5.media/3.servarr.md | 4 +- content/3.serveex/6.cloud/1.immich.md | 4 +- content/3.serveex/6.cloud/2.nextcloud.md | 8 ++-- content/3.serveex/7.files/1.file-browser.md | 2 +- content/3.serveex/7.files/2.pingvin.md | 2 +- .../3.serveex/8.development/1.code-server.md | 8 ++-- content/3.serveex/8.development/2.gitea.md | 6 +-- content/3.serveex/8.development/3.it-tools.md | 2 +- content/3.serveex/9.apps/1.adguard.md | 4 +- content/3.serveex/9.apps/2.vaultwarden.md | 6 +-- .../5.nonsense/2.bash/1.servarr-duplicates.md | 6 +-- content/5.nonsense/2.bash/2.luks- backup.md | 2 +- 28 files changed, 134 insertions(+), 118 deletions(-) diff --git a/README.md b/README.md index a5a37be..1b7dd48 100755 --- a/README.md +++ b/README.md @@ -16,19 +16,19 @@ This repository contains everything you need to edit pages, apply your changes, Install dependencies: -```bash +```sh npm install ``` ## Development Environment (port 3000) -```bash +```sh npm run dev ``` ## Generate Static Pages -```bash +```sh npm run generate ``` @@ -38,6 +38,6 @@ The HTML files will be generated in the `.output/public` folder and are ready to If you'd like to immediately see the result of your static site build, you can launch a preview server: -```bash +```sh npm run preview ``` diff --git a/assets/css/extra.css b/assets/css/extra.css index d3ce8f0..3c72c23 100644 --- a/assets/css/extra.css +++ b/assets/css/extra.css @@ -68,4 +68,20 @@ p img { .card-grid { padding-bottom: 80px !important; } +} + +.prose-code.highlight-sh code .line { + padding-inline-start: 0 !important; +} + +.prose-code.highlight-sh code .line:before { + display:none !important; +} + +.prose-code.highlight-bash code .line { + padding-inline-start: 0 !important; +} + +.prose-code.highlight-bash code .line:before { + display:none !important; } \ No newline at end of file diff --git a/content/2.general/1.networking/3.samba.md b/content/2.general/1.networking/3.samba.md index 3539da9..857830b 100644 --- a/content/2.general/1.networking/3.samba.md +++ b/content/2.general/1.networking/3.samba.md @@ -29,14 +29,14 @@ There are many tutorials for setting up Samba on Windows or on NAS systems like ### Install Samba Server -```shell +```sh sudo apt update && sudo apt upgrade sudo apt install samba smbclient cifs-utils ``` ### Create the `/video` Folder -```shell +```sh sudo mkdir /video ``` @@ -47,7 +47,7 @@ Now, edit the file `/etc/samba/smb.conf`. ✨ **Tip:** You can use [File Browser](/serveex/files/file-browser) to navigate and edit your files instead of using terminal commands. \:: -```shell +```sh sudo vim /etc/samba/smb.conf ``` @@ -75,47 +75,47 @@ Since we're using a secured share, we need to create a user and group to access Create the group: -```shell +```sh sudo groupadd smbshare ``` Give the group control over the `/video` folder: -```shell +```sh sudo chgrp -R smbshare /video ``` Set inherited permissions: -```shell +```sh sudo chmod 2775 /video ``` Now add a no-login user — this user cannot log into the server but can access Samba. -```shell +```sh sudo useradd -M -s /sbin/nologin sambauser ``` Add the user to the `smbshare` group: -```shell +```sh sudo usermod -aG smbshare sambauser ``` Set a Samba password: -```shell +```sh sudo smbpasswd -a sambauser ``` Enable the Samba account: -```shell +```sh sudo smbpasswd -e sambauser ``` -```shell +```sh sudo ufw allow from remote-ip to any app Samba :: ``` @@ -128,7 +128,7 @@ sudo ufw allow from remote-ip to any app Samba ### Install Required Packages -```shell +```sh sudo apt update && sudo apt upgrade sudo apt install cifs-utils ``` @@ -137,7 +137,7 @@ sudo apt install cifs-utils We will create a folder on our local machine where the remote `/video` folder will be mounted — e.g., `/mnt/video`. -```shell +```sh sudo mkdir /mnt/video ``` @@ -147,7 +147,7 @@ To avoid typing our username and password every time, create a `.credentials` fi Create it in the `/smb` folder: -```shell +```sh sudo mkdir /smb sudo vi /smb/.credentials ``` @@ -166,7 +166,7 @@ Press `Esc`, then `:x` and `Enter` to save and exit. Set proper file permissions: -```shell +```sh sudo chmod 600 /smb/.credentials ``` @@ -174,7 +174,7 @@ sudo chmod 600 /smb/.credentials Now mount the folder: -```shell +```sh sudo mount -t cifs -o credentials=/smb/.credentials //remote-ip/video /mnt/video ``` @@ -182,7 +182,7 @@ Replace `remote-ip` with your `remote-machine`'s IP address. Verify the mount: -```shell +```sh sudo mount -t cifs ``` @@ -196,25 +196,25 @@ By default, shares aren't auto-mounted after reboot. To automate this, edit the First, back it up: -```shell +```sh sudo cp /etc/fstab /etc/fstab.bak ``` Then add the mount configuration line: -```shell +```sh sudo echo //remote-ip/video /mnt/video cifs _netdev,nofail,credentials=/smb/.credentials,x-systemd.automount,x-systemd.device-timeout=15 0 0 >> /etc/fstab ``` Reboot the machine: -```shell +```sh sudo reboot ``` After rebooting, verify the mount: -```shell +```sh sudo mount -t cifs ``` @@ -222,6 +222,6 @@ And done! ### Unmount the Shared Folder -```shell +```sh sudo umount -t cifs /mnt/video ``` \ No newline at end of file diff --git a/content/3.serveex/2.core/1.installation.md b/content/3.serveex/2.core/1.installation.md index 0a0266e..8fe6f04 100644 --- a/content/3.serveex/2.core/1.installation.md +++ b/content/3.serveex/2.core/1.installation.md @@ -20,15 +20,15 @@ main: 4. [Install Debian and Set Up SSH](https://www.howtoforge.com/tutorial/debian-minimal-server/) 5. Install sudo and add a user to the sudo group for administrative privileges. Log in as root: - ```shell + ```sh su - ``` Enter your password, then type: - ```shell + ```sh apt install sudo ``` Add the user to the sudo group: - ```shell + ```sh adduser sudo ``` @@ -42,7 +42,7 @@ main: ## Must-Have CLI Apps --- Some essential apps you’ll likely need at some point, so might as well install them early: -```shell +```sh sudo apt update sudo apt upgrade sudo apt install vim btop ranger git duf neofetch samba cifs-utils tree unzip ufw @@ -65,7 +65,7 @@ Additionally: ### File Transfer via rsync -```shell +```sh sudo rsync -avhHSP /source /destination ``` ::alert{type="info" icon="exclamation-circle"} diff --git a/content/3.serveex/2.core/2.docker.md b/content/3.serveex/2.core/2.docker.md index 5431441..aa8a2f8 100644 --- a/content/3.serveex/2.core/2.docker.md +++ b/content/3.serveex/2.core/2.docker.md @@ -22,7 +22,7 @@ Docker, to install deployable services in seconds and manage them with just a fe --- Add the Docker repositories and GPG key: -```shell +```sh # Add Docker's official GPG key: sudo apt-get update sudo apt-get install ca-certificates curl @@ -37,7 +37,7 @@ sudo apt-get update Install the packages: -```shell +```sh sudo apt-get install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin ``` @@ -49,7 +49,7 @@ That's it! :::list{type="info"} - From here on, we assume the stacks are installed in the `/docker` folder, created using the command: ::: - ```shell + ```sh sudo mkdir /docker :: @@ -63,7 +63,7 @@ That's it! File structure we will create: -```console +```sh root └── docker └── dockge @@ -72,14 +72,14 @@ root Create the stack folder: -```shell +```sh cd /docker sudo mkdir dockge ``` Then create the `compose.yml` file in this folder using `vim`: -```shell +```sh cd /docker/dockge sudo vi compose.yml ``` @@ -107,7 +107,7 @@ Press `Esc` and type `:x` to save and exit. To launch the container: -```shell +```sh cd /docker/dockge sudo docker compose up -d ``` diff --git a/content/3.serveex/2.core/3.swag.md b/content/3.serveex/2.core/3.swag.md index 51134ac..cc0c841 100644 --- a/content/3.serveex/2.core/3.swag.md +++ b/content/3.serveex/2.core/3.swag.md @@ -41,7 +41,7 @@ Below is an example exposing Dockge. We will install SWAG along with the dbip mo File structure to be modified: -```console +```sh root └── docker └── swag @@ -133,7 +133,7 @@ In CLI, go to the dns-conf folder and edit the `ovh.ini` file: You can use [File Browser](/serveex/files/file-browser) to browse and edit files instead of using terminal commands. :: -```shell +```sh sudo vi /docker/swag/config/dns-conf/ovh.ini ``` @@ -163,7 +163,7 @@ Save and exit the file. Now configure swag to access DBIP, the geolocation-based access control module. Open the `nginx.conf` file: -```shell +```sh sudo vi /docker/swag/config/nginx/nginx.conf ``` @@ -193,7 +193,7 @@ This configuration can be enabled or disabled per service (see the Dockge exampl Open `dbip.conf`: -```shell +```sh sudo vi /docker/swag/config/nginx/dbip.conf ``` @@ -278,7 +278,7 @@ Now it's time to expose Dockge on the internet so you can access and manage your Open the `dockge.subdomain.conf` file: -```shell +```sh sudo vi /docker/swag/config/nginx/proxy-confs/dockge.subdomain.conf ``` @@ -363,7 +363,7 @@ Wait a moment, then visit `https://dockge.mydomain.com` in your browser — you --- SWAG includes templates for most known services, named `servicename.subdomain.conf.sample`. Just create the subdomain in your registrar's DNS zone (like OVH), point it to your main domain via a CNAME, then copy and rename the sample file: -```shell +```sh cd /docker/swag/config/proxy-confs sudo cp servicename.subdomain.conf.sample servicename.subdomain.conf ``` diff --git a/content/3.serveex/3.security/1.wireguard.md b/content/3.serveex/3.security/1.wireguard.md index 0a5b3c4..c7872b6 100644 --- a/content/3.serveex/3.security/1.wireguard.md +++ b/content/3.serveex/3.security/1.wireguard.md @@ -63,7 +63,7 @@ So only VPN-connected devices can communicate with each other on the VPN, not wi Folder structure: -```console +```sh root └── docker └── wg-easy @@ -142,7 +142,7 @@ Deploy the stack. To allow communication between VPN clients, enable: -```shell +```sh sudo sysctl net.ipv4.ip_forward=1 sudo sysctl net.ipv4.conf.all.src_valid_mark=1 ``` @@ -172,7 +172,7 @@ To configure clients, download the config files from the server: Folder structure: -```console +```sh root └── docker └── wireguard @@ -187,7 +187,7 @@ Create the folder `/docker/wireguard/config/wg_confs`: ✨ __Tip:__ Use [File Browser](/serveex/files/file-browser) to browse and edit files without terminal :: -```shell +```sh sudo mkdir -p /docker/wireguard/config/wg_confs ``` @@ -196,14 +196,14 @@ Copy the `wg0.conf` file downloaded earlier: ::alert{type="success"} ✨ __Tip:__ Easiest way is to transfer the file via SFTP to `/home/youruser`, then move it: -```shell +```sh sudo cp ~/wg0.conf /docker/wireguard/config/wg_confs ``` :: Create `compose.yaml` in `/docker/wireguard`: -```shell +```sh sudo vi /docker/wireguard/compose.yaml ``` @@ -230,7 +230,7 @@ Press `Esc` then type `:x` to save and exit. Start the container: -```shell +```sh cd /docker/wireguard sudo docker compose up -d ``` diff --git a/content/3.serveex/3.security/2.authentik.md b/content/3.serveex/3.security/2.authentik.md index d5c2b46..1836ac0 100644 --- a/content/3.serveex/3.security/2.authentik.md +++ b/content/3.serveex/3.security/2.authentik.md @@ -39,7 +39,7 @@ Both modes can be configured on a per-application basis. ## Installation --- Folder structure: -```console +```sh root └── docker └── authentik @@ -53,13 +53,13 @@ root Create the folders: -```shell +```sh sudo mkdir -p /docker/authentik/media /docker/authentik/certs /docker/authentik/custom-template /docker/authentik/ssh ``` Navigate to the `authentik` folder and generate a password and secret key to include in the `.env` file: -```shell +```sh sudo echo "PG_PASS=$(openssl rand 36 | base64)" >> .env sudo echo "AUTHENTIK_SECRET_KEY=$(openssl rand 60 | base64)" >> .env ``` @@ -68,7 +68,7 @@ sudo echo "AUTHENTIK_SECRET_KEY=$(openssl rand 60 | base64)" >> .env :::list{type="info"} - To generate the keys, we created the folders ahead of deployment using Dockge. Dockge will prevent you from creating a stack with the same name in these folders unless a `compose.yml` file exists. So, create an empty `compose.yml` so it appears as an inactive stack: ::: - ```shell + ```sh sudo vi /docker/authentik/compose.yml :: @@ -205,7 +205,7 @@ Open the `authentik-server.conf` file: You can use [File Browser](/serveex/files/file-browser) to navigate and edit files instead of using terminal commands. :: -```shell +```sh sudo vi /docker/swag/config/nginx/authentik-server.conf ``` @@ -220,7 +220,7 @@ If not, press `i` to enter edit mode, make the necessary changes, then save and Create the `auth.subdomain.conf` file: -```shell +```sh sudo vi /docker/swag/config/nginx/proxy-confs/auth.subdomain.conf ``` @@ -335,7 +335,7 @@ Why do this when Dockge already has authentication? Because Dockge uses weak HTT Edit the file `dockge.mydomain.com`: -```shell +```sh sudo vi /docker/swag/config/nginx/proxy-confs/dockge.subdomain.conf ``` @@ -417,7 +417,7 @@ On your remote machine, use [Dockge](/serveex/core/docker/#installer-dockge-pour If you haven’t installed [Dockge](/serveex/core/docker/#installer-dockge-pour-gérer-et-déployer-les-conteneurs), create a folder `/docker/authentik-outpost`, or directly via command line: -```shell +```sh sudo mkdir -P /docker/authentik-outpost ``` @@ -430,7 +430,7 @@ Create the `compose.yaml` file or paste the configuration directly into Dockge i Via command line: -```shell +```sh sudo vi /docker/authentik-outpost/compose.yaml ``` Enter edit mode by pressing `i` and paste the following configuration, updating the version in `{AUTHENTIK_TAG:proxy:2024.2.3}`{lang=properties} to match your Authentik server version. @@ -457,7 +457,7 @@ services: Go to the SWAG stack on the remote machine (or edit directly using Dockge) and add the authentik-outpost network in the configuration file like this (see `networks` section): -```shell +```sh sudo vi /docker/swag/compose.yaml ``` @@ -488,7 +488,7 @@ If using [Dockge](/serveex/core/docker/#installer-dockge-pour-gérer-et-déploye Otherwise, via terminal: -```shell +```sh cd /docker/swag/ sudo docker compose up -d ``` @@ -497,7 +497,7 @@ Create (or fill using Dockge) the `.env` file in the `authentik-outpost` directo Via command line: -```shell +```sh sudo vi /docker/authentik-outpost/.env ``` @@ -521,7 +521,7 @@ If using Dockge, deploy the stack. Otherwise, via terminal: -```shell +```sh cd /docker/authentik-outpost/ sudo docker compose up -d ``` @@ -532,7 +532,7 @@ Now, let’s configure SWAG. Open the `authentik-server.conf` file: -```shell +```sh sudo vi /docker/swag/config/nginx/authentik-server.conf ``` @@ -551,24 +551,24 @@ Then configure the applications to protect as you did on your main server, wheth --- On the source machine, dump the database: -```shell +```sh sudo docker exec authentik-postgres pg_dump -U authentik -F t authentik > /path/to/mydb.tar ``` Then transfer it to the target machine. On the target machine, copy the file into the Docker container: -```shell +```sh cp /path/to/mydb.tar authentik-postgres:/path/to/wherever ``` (Optional) Purge existing tables: -```shell +```sh sudo docker exec -i authentik-postgres psql -U authentik -c "SELECT pg_terminate_backend(pg_stat_activity.pid) FROM pg_stat_activity WHERE pg_stat_activity.datname = 'authentik' AND pid <> pg_backend_pid();" && sudo docker exec -i authentik-postgres psql -U authentik -d postgres -c "DROP DATABASE IF EXISTS authentik;" && sudo docker exec -i authentik-postgres psql -U authentik -d postgres -c "CREATE DATABASE authentik;" ``` Restore the database: -```shell +```sh sudo docker exec authentik-postgresql pg_restore -U authentik -d authentik /path/to/wherever/mydb.tar ``` \ No newline at end of file diff --git a/content/3.serveex/3.security/3.cloudflare.md b/content/3.serveex/3.security/3.cloudflare.md index d19e93b..63f1edc 100644 --- a/content/3.serveex/3.security/3.cloudflare.md +++ b/content/3.serveex/3.security/3.cloudflare.md @@ -97,7 +97,7 @@ Create a file `tunnelconfig.yml` to reference in your SWAG `compose.yaml`. ✨ __Tip:__ Use [File Browser](/serveex/files/file-browser) to navigate and edit files instead of using the terminal. :: -```shell +```sh sudo vi /docker/swag/config/tunnelconfig.yml ``` @@ -120,7 +120,7 @@ Now configure _Cloudflare Real IP_. Open the `nginx.conf` file: -```shell +```sh sudo vi /docker/swag/config/nginx/nginx.conf ``` diff --git a/content/3.serveex/4.monitoring/1.uptime-kuma.md b/content/3.serveex/4.monitoring/1.uptime-kuma.md index d208048..6934a19 100644 --- a/content/3.serveex/4.monitoring/1.uptime-kuma.md +++ b/content/3.serveex/4.monitoring/1.uptime-kuma.md @@ -22,7 +22,7 @@ main: --- Folder structure -```console +```sh root └── docker └── uptime-kuma @@ -84,7 +84,7 @@ In the Swag folders, create the `stats.subdomain.conf` file. you can use [File Browser](/serveex/files/file-browser) to browse and edit your files instead of using terminal commands. :: -```shell +```sh sudo vi /docker/swag/config/nginx/proxy-confs/stats.subdomain.conf ``` Enter insert mode with `i` and paste the following config: diff --git a/content/3.serveex/4.monitoring/2.dozzle.md b/content/3.serveex/4.monitoring/2.dozzle.md index d314b5d..6ab4bd7 100644 --- a/content/3.serveex/4.monitoring/2.dozzle.md +++ b/content/3.serveex/4.monitoring/2.dozzle.md @@ -21,7 +21,7 @@ main: --- Folder structure -```console +```sh root └── docker └── dozzle @@ -114,7 +114,7 @@ In the Swag folder, create the `dozzle.subdomain.conf` file. ✨ __Tip:__ You can use [File Browser](/serveex/files/file-browser) to browse and edit files instead of using terminal commands. :: -```shell +```sh sudo vi /docker/swag/config/nginx/proxy-confs/dozzle.subdomain.conf ``` Enter edit mode by pressing `i` and paste the configuration below: diff --git a/content/3.serveex/4.monitoring/3.speedtest-tracker.md b/content/3.serveex/4.monitoring/3.speedtest-tracker.md index db7e903..ec1fd0d 100644 --- a/content/3.serveex/4.monitoring/3.speedtest-tracker.md +++ b/content/3.serveex/4.monitoring/3.speedtest-tracker.md @@ -27,7 +27,7 @@ main: File structure: -```console +```sh root └── docker └── speedtest-tracker @@ -37,7 +37,7 @@ root In a terminal, generate a key using the following command: -```shell +```sh echo -n 'base64:'; openssl rand -base64 32; ``` @@ -67,7 +67,7 @@ services: Find your `PUID` and `GUID` by running the following command: -```shell +```sh id yourusername ``` @@ -104,7 +104,7 @@ Now we want to expose Speedtest Tracker to the internet so you can access it rem Open the `speedtest.subdomain.conf` file: -```shell +```sh sudo vi /docker/swag/config/nginx/proxy-confs/speedtest.subdomain.conf ``` diff --git a/content/3.serveex/4.monitoring/4.beszel.md b/content/3.serveex/4.monitoring/4.beszel.md index 0b7e8a9..1556bc1 100644 --- a/content/3.serveex/4.monitoring/4.beszel.md +++ b/content/3.serveex/4.monitoring/4.beszel.md @@ -26,7 +26,7 @@ Beszel includes a hub with a web UI and an agent that collects data from your se Folder structure -```console +```sh root └── docker └── beszel @@ -191,7 +191,7 @@ In Swag’s config folders, create `beszel.subdomain.conf`. ✨ __Tip:__ Use [File Browser](/serveex/files/file-browser) to browse and edit files instead of terminal commands. :: -```shell +```sh sudo vi /docker/swag/config/nginx/proxy-confs/beszel.subdomain.conf ``` diff --git a/content/3.serveex/4.monitoring/5.upsnap.md b/content/3.serveex/4.monitoring/5.upsnap.md index a23900c..8f76567 100644 --- a/content/3.serveex/4.monitoring/5.upsnap.md +++ b/content/3.serveex/4.monitoring/5.upsnap.md @@ -22,7 +22,7 @@ main: Folder structure -```console +```sh root └── docker └── upsnap @@ -129,7 +129,7 @@ In the Swag folders, create the file `upsnap.subdomain.conf`. ✨ __Tip:__ You can use [File Browser](/serveex/files/file-browser) to navigate your files and edit documents instead of using terminal commands. :: -```shell +```sh sudo vi /docker/swag/config/nginx/proxy-confs/upsnap.subdomain.conf ``` Enter edit mode by pressing `i`, and paste the following configuration: diff --git a/content/3.serveex/5.media/1.plex.md b/content/3.serveex/5.media/1.plex.md index 0264afd..a80e064 100644 --- a/content/3.serveex/5.media/1.plex.md +++ b/content/3.serveex/5.media/1.plex.md @@ -34,7 +34,7 @@ We'll also install [Tautulli](https://docs.linuxserver.io/images/docker-tautulli ## Install Plex --- Folder structure: -```console +```sh root ├── docker │ ├── plex @@ -114,7 +114,7 @@ services: Find your PUID and GUID by running: -```shell +```sh id username ``` @@ -211,7 +211,7 @@ Copy and rename the file `tautulli.subdomain.conf.sample` to `tautulli.subdomain ✨ **Tip:** Use [File Browser](/serveex/files/file-browser) to navigate and edit files instead of using terminal commands. :: -```shell +```sh sudo cp /docker/swag/config/nginx/proxy-confs/tautulli.subdomain.conf.sample /docker/swag/config/nginx/proxy-confs/tautulli.subdomain.conf sudo vi /docker/swag/config/nginx/proxy-confs/tautulli.subdomain.conf ``` diff --git a/content/3.serveex/5.media/2.qbittorrent.md b/content/3.serveex/5.media/2.qbittorrent.md index 2f62ccd..fdde53d 100644 --- a/content/3.serveex/5.media/2.qbittorrent.md +++ b/content/3.serveex/5.media/2.qbittorrent.md @@ -31,7 +31,7 @@ Here’s the system we’ll set up: --- Folder structure -```console +```sh root ├── docker │ └── seedbox @@ -128,19 +128,19 @@ We now need to allow the mod to fetch info from Gluetun, which only allows encry Open a terminal to generate the authentication key: -```shell +```sh sudo docker run --rm qmcgaw/gluetun genkey ``` Note the key, then create the `/docker/gluetun` folder: -```shell +```sh sudo mkdir /docker/gluetun ``` Create the `config.toml` file: -```shell +```sh sudo vi /docker/gluetun/config.toml ``` @@ -253,7 +253,7 @@ Now create/edit `seedbox.subdomain.conf`. ✨ __Terminal-free tip:__ use [File Browser](/serveex/files/file-browser) to edit files instead of using the terminal. :: -```shell +```sh sudo vi /docker/swag/config/nginx/proxy-confs/seedbox.subdomain.conf ``` diff --git a/content/3.serveex/5.media/3.servarr.md b/content/3.serveex/5.media/3.servarr.md index 8677930..3fe0219 100644 --- a/content/3.serveex/5.media/3.servarr.md +++ b/content/3.serveex/5.media/3.servarr.md @@ -29,7 +29,7 @@ We’ll start by deploying the stack and then proceed to configure each app and Folder structure: -```console +```sh root ├── docker │ ├── plex @@ -430,7 +430,7 @@ Create and edit the file `films.subdomain.conf`: ✨ __Tip:__ you can use [File Browser](/serveex/files/file-browser) to browse and edit files instead of using terminal commands. :: -```shell +```sh sudo vi /docker/swag/config/nginx/proxy-confs/films.subdomain.conf ``` diff --git a/content/3.serveex/6.cloud/1.immich.md b/content/3.serveex/6.cloud/1.immich.md index a9c8a76..8ed4b1d 100644 --- a/content/3.serveex/6.cloud/1.immich.md +++ b/content/3.serveex/6.cloud/1.immich.md @@ -19,7 +19,7 @@ main: --- Folder structure -```console +```sh root └── docker └── immich @@ -96,7 +96,7 @@ In the SWAG folders, create a file named `immich.subdomain.conf`. ::: :: -```shell +```sh sudo vi /docker/swag/config/nginx/proxy-confs/immich.subdomain.conf ``` Press `i` to enter insert mode, then paste the following configuration: diff --git a/content/3.serveex/6.cloud/2.nextcloud.md b/content/3.serveex/6.cloud/2.nextcloud.md index 692056f..6b13e9d 100644 --- a/content/3.serveex/6.cloud/2.nextcloud.md +++ b/content/3.serveex/6.cloud/2.nextcloud.md @@ -25,7 +25,7 @@ main: File structure: -```console +```sh root └── docker └── nextcloud @@ -63,7 +63,7 @@ services: Find your `PUID` and `GUID` by running the following command: -```shell +```sh id username ``` @@ -125,7 +125,7 @@ In Nextcloud’s files, edit the `config.php` file: ✨ __Tip:__ You can use [File Browser](/serveex/files/file-browser) to navigate and edit files instead of using terminal commands. :: -```shell +```sh sudo vi /docker/nextcloud/config/www/nextcloud/config/config.php ``` @@ -151,7 +151,7 @@ Press `Esc`, then save and exit by typing `:x` and hitting Enter. In Swag’s folders, create the file `nextcloud.subdomain.conf`: -```shell +```sh sudo vi /docker/swag/config/nginx/proxy-confs/nextcloud.subdomain.conf ``` diff --git a/content/3.serveex/7.files/1.file-browser.md b/content/3.serveex/7.files/1.file-browser.md index 00292d5..2b8f7e8 100644 --- a/content/3.serveex/7.files/1.file-browser.md +++ b/content/3.serveex/7.files/1.file-browser.md @@ -98,7 +98,7 @@ Restart the stack by clicking "deploy" and wait for SWAG to fully initialize. In the Swag folders, create the file `files.subdomain.conf`. -```shell +```sh sudo vi /docker/swag/config/nginx/proxy-confs/files.subdomain.conf ``` diff --git a/content/3.serveex/7.files/2.pingvin.md b/content/3.serveex/7.files/2.pingvin.md index a80633d..78d2a46 100644 --- a/content/3.serveex/7.files/2.pingvin.md +++ b/content/3.serveex/7.files/2.pingvin.md @@ -118,7 +118,7 @@ Dans les dossiers de Swag, créez le fichier `pingvin.subdomain.conf`. ::: :: -```shell +```sh sudo vi /docker/swag/config/nginx/proxy-confs/pingvin.subdomain.conf ``` Entrez en modification avec la touche `i` et collez la configuration ci-dessous : diff --git a/content/3.serveex/8.development/1.code-server.md b/content/3.serveex/8.development/1.code-server.md index d533470..b138d68 100644 --- a/content/3.serveex/8.development/1.code-server.md +++ b/content/3.serveex/8.development/1.code-server.md @@ -28,7 +28,7 @@ main: Folder structure -```console +```sh root ├── docker │ └── code-server @@ -71,13 +71,13 @@ services: Choose a password and generate its hash: -```shell +```sh echo -n "yourpassword" | npx argon2-cli -e ``` Save the result carefully. Find your PUID and GUID with: -```shell +```sh id yourusername ``` @@ -158,7 +158,7 @@ Inside the Swag config folders, create the file `code.subdomain.conf`. ✨ __Tip:__ You can use [File Browser](/serveex/files/file-browser) to navigate and edit your files instead of using terminal commands. :: -```shell +```sh sudo vi /docker/swag/config/nginx/proxy-confs/code.subdomain.conf ``` diff --git a/content/3.serveex/8.development/2.gitea.md b/content/3.serveex/8.development/2.gitea.md index d110df9..ff14cbd 100644 --- a/content/3.serveex/8.development/2.gitea.md +++ b/content/3.serveex/8.development/2.gitea.md @@ -21,7 +21,7 @@ main: --- Folder structure -```console +```sh root └── docker └── gitea @@ -110,7 +110,7 @@ Inside the Swag folders, create the file `gitea.subdomain.conf`. ✨ __Tip:__ You can use [File Browser](/serveex/files/file-browser) to navigate and edit your files instead of using terminal commands. :: -```shell +```sh sudo vi /docker/swag/config/nginx/proxy-confs/gitea.subdomain.conf ``` Press `i` to enter edit mode and paste the configuration below: @@ -176,7 +176,7 @@ Press `Esc`, then save and exit by typing `:x` and hitting `Enter`. Now open the `app.ini` file from the container's file system: -```shell +```sh sudo vi /docker/gitea/data/gitea/conf/app.ini ``` diff --git a/content/3.serveex/8.development/3.it-tools.md b/content/3.serveex/8.development/3.it-tools.md index 98efd78..104255c 100644 --- a/content/3.serveex/8.development/3.it-tools.md +++ b/content/3.serveex/8.development/3.it-tools.md @@ -100,7 +100,7 @@ Inside the Swag folders, create the file `tools.subdomain.conf`. ✨ __Tip:__ You can use [File Browser](/serveex/files/file-browser) to navigate and edit your files instead of using terminal commands. :: -```shell +```sh sudo vi /docker/swag/config/nginx/proxy-confs/tools.subdomain.conf ``` diff --git a/content/3.serveex/9.apps/1.adguard.md b/content/3.serveex/9.apps/1.adguard.md index 3264963..503d2b4 100644 --- a/content/3.serveex/9.apps/1.adguard.md +++ b/content/3.serveex/9.apps/1.adguard.md @@ -40,7 +40,7 @@ This is how ads and malicious domains are blocked—Adguard blocks only the bad --- Folder structure: -```console +```sh root └── docker └── adguard @@ -147,7 +147,7 @@ Create and open the file `adguard.subdomain.conf` You can use [File Browser](/serveex/files/file-browser) to browse and edit files instead of using terminal commands. :: -```shell +```sh sudo vi /docker/swag/config/nginx/proxy-confs/adguard.subdomain.conf ``` diff --git a/content/3.serveex/9.apps/2.vaultwarden.md b/content/3.serveex/9.apps/2.vaultwarden.md index a17e3ec..5ba8037 100644 --- a/content/3.serveex/9.apps/2.vaultwarden.md +++ b/content/3.serveex/9.apps/2.vaultwarden.md @@ -21,7 +21,7 @@ Vaultwarden is a fork of [Bitwarden](https://bitwarden.com/fr-fr/help/). --- Folder structure: -```console +```sh root └── docker └── vaultwarden @@ -75,7 +75,7 @@ services: Next, generate a password hash to put in the `TOKEN` variable in `.env`: -```shell +```sh echo -n 'yourpassword' | argon2 "$(openssl rand -base64 32)" -e -id -k 65540 -t 3 -p 4 ``` @@ -143,7 +143,7 @@ In SWAG's config folder, create the file `vault.subdomain.conf`: ✨ __Tip:__ Use [File Browser](/serveex/files/file-browser) to navigate and edit files instead of using terminal commands. :: -```shell +```sh sudo vi /docker/swag/config/nginx/proxy-confs/vault.subdomain.conf ``` diff --git a/content/5.nonsense/2.bash/1.servarr-duplicates.md b/content/5.nonsense/2.bash/1.servarr-duplicates.md index d7a08c7..bf59f86 100644 --- a/content/5.nonsense/2.bash/1.servarr-duplicates.md +++ b/content/5.nonsense/2.bash/1.servarr-duplicates.md @@ -14,7 +14,7 @@ So I restructured my directories, manually updated every path in Qbittorrent, Pl My directory structure: -```console +```sh . └── media ├── seedbox @@ -42,7 +42,7 @@ Spare you the endless Q&A with ChatGPT—I was disappointed. Qwen3 was much clea To test, I first asked for a script that only lists and compares: -```bash +```sh #!/bin/bash # Create an associative array to store duplicates @@ -88,7 +88,7 @@ Again, ChatGPT disappointed. Despite my requests, it created hardlinks *before* Quick stopover to Qwen3, RTX 5090 in overdrive, and bam—much better result. Yes, it kept ChatGPT-style emojis, but here it is: -```bash +```sh #!/bin/bash echo "🔍 Step 1: Indexing original files in /media/seedbox..." diff --git a/content/5.nonsense/2.bash/2.luks- backup.md b/content/5.nonsense/2.bash/2.luks- backup.md index 92e96bc..64da0f3 100644 --- a/content/5.nonsense/2.bash/2.luks- backup.md +++ b/content/5.nonsense/2.bash/2.luks- backup.md @@ -22,7 +22,7 @@ This script: * Encrypts the archive with that password * Deletes the unencrypted archive -```bash +```sh #!/bin/bash # Directory where LUKS headers will be backed up