Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update func_general.sh #14

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions inc/src/func_general.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ function check_repo() {
deb http://us.archive.ubuntu.com/ubuntu/ xenial-updates universe
deb http://us.archive.ubuntu.com/ubuntu/ xenial main restricted
deb http://us.archive.ubuntu.com/ubuntu/ xenial-updates main restricted
" >> /etc/apt/sources.list
" | sudo tee -a /etc/apt/sources.list
fi
}
function check_php() {
Expand Down Expand Up @@ -66,7 +66,7 @@ function check_packages_list() {
'make' 'gcc' 'openssl' 'apache2' 'lwresd' \
'curl' 'zip' 'unzip' 'libnet-ldap-perl' 'ldap-utils' 'ntp' \
'libapache2-mod-xsendfile' 'libpcre3-dev:amd64' \
'libbind-dev')
'libbind-dev' 'git')

if [[ $1 == 'list' ]]; then
echo "We must have:"
Expand Down Expand Up @@ -112,7 +112,7 @@ function system_test() {
PW_AGAIN="mysql-server mysql-server/root_password_again password ${MYSQL_PASSWORD}"
sudo debconf-set-selections <<< $PW_ONE
sudo debconf-set-selections <<< $PW_AGAIN
apt install mysql-server -y
sudo apt install mysql-server -y
sudo mysql -e "ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY '${MYSQL_PASSWORD}'; \
DELETE FROM mysql.user WHERE User=''; \
DELETE FROM mysql.user WHERE User='root' AND Host NOT IN ('localhost', '127.0.0.1', '::1'); \
Expand Down Expand Up @@ -187,7 +187,7 @@ function system_test() {
if [[ $(check_php) -eq 0 ]]; then
error_message "Error! PHP 7.3 Not Installed! Try to install.";
if [[ $(sudo apt-cache search php7.3 | wc -l) == 0 ]]; then
sudo apt-get install python-software-properties -y
sudo apt-get install software-properties-common -y
sudo add-apt-repository ppa:ondrej/php -y
sudo apt-get update
fi
Expand Down