2021-11-07 18:43:45

This commit is contained in:
gbaconni
2021-11-07 18:43:45 +01:00
parent fd7003d61d
commit b59cded3f3

View File

@@ -6,7 +6,7 @@
# By: gbaconni@student.42lausanne.ch +#+ +:+ +#+ # # By: gbaconni@student.42lausanne.ch +#+ +:+ +#+ #
# +#+#+#+#+#+ +#+ # # +#+#+#+#+#+ +#+ #
# Created: 2021/11/07 14:23:18 by gbaconni #+# #+# # # Created: 2021/11/07 14:23:18 by gbaconni #+# #+# #
# Updated: 2021/11/07 18:37:27 by gbaconni ### lausanne.ch # # Updated: 2021/11/07 18:43:43 by gbaconni ### lausanne.ch #
# # # #
# **************************************************************************** # # **************************************************************************** #
@@ -14,7 +14,7 @@ PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"
ft_mariadb () ft_mariadb ()
{ {
if ! dpkg --get-selections | grep -q '^mariadb-server' if ! dpkg --get-selections | grep -qP '^mariadb-server\t+install'
then then
apt-get install -qq -y mariadb-server apt-get install -qq -y mariadb-server
yes y | mysql_secure_installation yes y | mysql_secure_installation
@@ -24,7 +24,7 @@ ft_mariadb ()
ft_apache () ft_apache ()
{ {
if ! dpkg --get-selections | grep -q '^apache2' if ! dpkg --get-selections | grep -qP '^apache2\t+install'
then then
apt-get install -qq -y ssl-cert apache2 apt-get install -qq -y ssl-cert apache2
fi fi
@@ -33,7 +33,7 @@ ft_apache ()
ft_php () ft_php ()
{ {
if ! dpkg --get-selections | grep -q '^libapache2-mod-php' if ! dpkg --get-selections | grep -qP '^libapache2-mod-php\t+install'
then then
apt-get install -qq -y libapache2-mod-php apt-get install -qq -y libapache2-mod-php
fi fi
@@ -43,7 +43,7 @@ ft_php ()
ft_wordpress () ft_wordpress ()
{ {
password=${1-Born2beRoot} password=${1-Born2beRoot}
if ! dpkg --get-selections | grep -q '^wordpress' if ! dpkg --get-selections | grep -qP '^wordpress\tinstall'
then then
apt-get install -qq -y wordpress apt-get install -qq -y wordpress
fi fi