Script d'installation d'un serveur Ubuntu 20.04 à distance
25개 이상의 토픽을 선택하실 수 없습니다.
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
- #!/bin/bash
- sudo apt update
- sudo apt upgrade -y
- sudo apt install -y apache2 php
- sudo chown -R ubuntu:ubuntu /var/www/html
- rm /var/www/html/index.html
- echo "<!DOCTYPE html>
- <html lang='fr'>
- <head>
- <meta charset='UTF-8'>
- <meta name='viewport' content='width=device-width, initial-scale=1.0'>
- <title>PHP Info</title>
- </head>
- <body>
- <?php phpinfo(); ?>
- </body>
- </html>
- " > /var/www/html/index.php
- # Ou bien cp index.php /var/www/html
- # active le prompt en couleur
- sed -i 's/^#force_color_prompt/force_color_prompt/' $HOME/.bashrc
|