From c4f4452312b338b38dea05bea9af585ae2f26f02 Mon Sep 17 00:00:00 2001 From: AnthonyAxenov Date: Sat, 8 Jan 2022 14:34:20 +0800 Subject: [PATCH] =?UTF-8?q?=D0=9A=D0=BE=D1=80=D1=80=D0=B5=D0=BA=D1=82?= =?UTF-8?q?=D0=B8=D1=80=D0=BE=D0=B2=D0=BA=D0=B0=20pgsql?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- install/810-pgsql.sh | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/install/810-pgsql.sh b/install/810-pgsql.sh index b917073..766af66 100755 --- a/install/810-pgsql.sh +++ b/install/810-pgsql.sh @@ -1,7 +1,14 @@ #!/bin/bash -. "../src/01-common.sh" || exit 5 -title "Installing pgsql..." +echo +echo "===============================================" +echo "Installing postgresql..." +echo "===============================================" +echo -apti postgresql postgresql-contrib +installed() { + command -v "$1" >/dev/null 2>&1 +} + +sudo apt install -y --autoremove postgresql postgresql-contrib sudo service postgresql restart -installed php && apti php-pgsql +installed php && sudo apt install -y --autoremove php-pgsql