Skip to content

Latest commit

 

History

History
88 lines (57 loc) · 1.59 KB

Abstract.md

File metadata and controls

88 lines (57 loc) · 1.59 KB

CentOS

This project includes some shell-scripts to develop a web application using Symfony Framework

Abstract

  • App (PHP) + Cache (Redis) + Database (PostgreSQL) + Server (Nginx)

Dev Environment

Platform

  • CentOS - Install required packages
cd ~/Downloads
sudo apt update -y
sudo apt install -y curl git wget net-tools
sudo apt autoremove -y

App

1) Deploy this project

  • Deploy this project
./scripts/linux/centos/deploy.sh

Database

2) PostgreSQL

  • Configure the database
[root@localhost] cd /var/www/github/symfony

[root@localhost] sudo -i -u postgres
[sudo] password for user: {password}

postgres@localhost:~$ psql
psql (xx.y)
Type "help" for help.

postgres=# create user symfony password '!ChangeMe!' superuser;
CREATE ROLE
postgres=# \du
                                   List of roles
 Role name |                         Attributes                         | Member of 
-----------+------------------------------------------------------------+-----------
 postgres  | Superuser, Create role, Create DB, Replication, Bypass RLS | {}
 symfony   | Superuser                                                  | {}

postgres=# \q

  • Change the user's password
cd /var/www/github/symfony

sudo -i -u postgres
[sudo] password for user: {password}

postgres@localhost:~$ psql
psql (xx.y)
Type "help" for help.

postgres=# alter user {user_name} password {user_password}

postgres=# \q

  • Update a configuration
sudo cat /etc/postgresql/14/main/postgresql.conf | grep -i listen_addresses

Reference

Platform