From 76ddfb8d9ca589353edb3aee1e44f05293fbe6ea Mon Sep 17 00:00:00 2001 From: "e.medina" Date: Thu, 20 Nov 2025 11:59:00 +0100 Subject: [PATCH] SFTP --- apache.md | 62 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ mariadb.md | 12 +++++++++-- ssh.md | 13 ++++++++++++ 3 files changed, 85 insertions(+), 2 deletions(-) create mode 100644 apache.md diff --git a/apache.md b/apache.md new file mode 100644 index 0000000..b830106 --- /dev/null +++ b/apache.md @@ -0,0 +1,62 @@ +# Apache + +Installer le [paquet logiciel](package.md) apache + +```shell +apt install --no-install-recommends apache2 +``` + +> Fondamentalement, le serveur Apache n'exige pas seulement des autorisations de lecture de tous les fichiers qu'il dessert, mais l'autorisation d'exécution de tous les répertoires dans le chemin de votre hôte virtuel. + + +### PHP 8.4 + +```shell +apt install --no-install-recommends php-fpm + +a2enconf php8.4-fpm +a2enmod proxy_fcgi + +a2dismod autoindex +a2enmod rewrite +``` + +## optionnel + + +### Mbstring + +```shell +apt install --no-install-recommends php-bcmath +``` + +apt install --no-install-recommends memcached libmemcached-tools +apt install --no-install-recommends php-memcached +apt install --no-install-recommends php-imagick + + + + + +### Caddy + +gpg: no valid OpenPGP data found +apt install ca-certificates + +apt install --no-install-recommends debian-keyring apt-transport-https ca-certificates +apt install --no-install-recommends curl +apt install --no-install-recommends gpg + +curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/gpg.key' | gpg --dearmor -o /usr/share/keyrings/caddy-stable-archive-keyring.gpg +curl -1sLf 'https://dl.cloudsmith.io/public/caddy/stable/debian.deb.txt' | tee /etc/apt/sources.list.d/caddy-stable.list +chmod o+r /usr/share/keyrings/caddy-stable-archive-keyring.gpg +chmod o+r /etc/apt/sources.list.d/caddy-stable.list +apt update +apt install caddy + +a2enmod remoteip + +### SMTP + +apt install --no-install-recommends msmtp-mta +systemctl enable msmtpd diff --git a/mariadb.md b/mariadb.md index fc10680..63a62b9 100644 --- a/mariadb.md +++ b/mariadb.md @@ -1,5 +1,13 @@ # MariaDB +Installer le [paquet logiciel](package) `mariadb-server`. + +```sh +apt install --no-install-recommends mariadb-server +``` + +## Docker + ```shell $ docker pull mariadb:12.0 ``` @@ -23,8 +31,8 @@ $ docker pull phpmyadmin:5.2-fpm-alpine ``` ```shell -$ docker run --detach --name phpmyadmin +$ docker run --detach --name phpmyadmin --network mariadb_net - -p 8080:80 + -p 8080:80 phpmyadmin:5.2-fpm-alpine ``` diff --git a/ssh.md b/ssh.md index cd280d1..7614779 100644 --- a/ssh.md +++ b/ssh.md @@ -39,3 +39,16 @@ Copier / coller votre clé publique dans le fichier `~/.ssh/authorized_keys` nano .ssh/authorized_keys chmod 600 .ssh/authorized_keys ``` + +## SFTP + +> ***SFTP*** est un protocole de communication fonctionnant au-dessus de `SSH` pour transférer et gérer des fichiers à distance. + +:warning: Il ne faut pas confondre `sftp` avec `ftps`. Les 2 protocoles offrent les mêmes fonctionnalités de transfert de fichiers. Cependant le `ftps` fonctionne sur la base du FTP en l'encapsulant dans une couche SSL/TLS alors que le sftp fonctionne au dessus de SSH. + + +Créer le groupe `sftp`. + +```shell +groupadd --system sftp +```