سلام دوستان
پیش نیاز
دبین 9
به ترتیب دستورات را اجرا نمایید.
	کد PHP:
	
sudo dpkg-reconfigure tzdata 
 
	کد PHP:
	
sudo apt update && sudo apt upgrade -y 
 
	کد PHP:
	
sudo apt install -y curl wget vim git unzip socat bash-completion apt-transport-https build-essential 
 
	کد PHP:
	
sudo apt install -y php7.0 php7.0-cli php7.0-fpm php7.0-common php7.0-mysql 
 
	کد PHP:
	
sudo apt install -y mariadb-server 
 
	کد PHP:
	
sudo mysql_secure_installation 
 سوالات رو اینجوری جواب بدید
	کد PHP:
	
Would you like to setup VALIDATE PASSWORD plugin? NNew password: your_secure_passwordRe-enter new password: your_secure_passwordRemove anonymous users? [Y/n] YDisallow root login remotely? [Y/n] YRemove test database and access to it? [Y/n] YReload privilege tables now? [Y/n] Y 
 
	کد PHP:
	
sudo mysql -u root -p# Enter password 
 
	کد PHP:
	
mariadb> CREATE DATABASE dbname;mariadb> GRANT ALL ON dbname.* TO 'username' IDENTIFIED BY 'password';mariadb> FLUSH PRIVILEGES; 
 
	کد PHP:
	
sudo su - rootgit clone https://github.com/Neilpang/acme.sh.gitcd acme.sh ./acme.sh --install --accountemail your_email@example.comsource ~/.bashrccd ~ 
 
	کد PHP:
	
# RSA 2048acme.sh --issue --standalone -d example.com --keylength 2048# ECDSAacme.sh --issue --standalone -d example.com --keylength ec-256 
 
	کد PHP:
	
mkdir -p /etc/letsecnrypt/example.comsudo mkdir -p /etc/letsencrypt/example.com_ecc 
 
	کد PHP:
	
# RSAacme.sh --install-cert -d example.com --cert-file /etc/letsencrypt/example.com/cert.pem --key-file /etc/letsencrypt/example.com/private.key --fullchain-file /etc/letsencrypt/example.com/fullchain.pem --reloadcmd "sudo systemctl reload nginx.service"# ECC/ECDSAacme.sh --install-cert -d example.com --ecc --cert-file /etc/letsencrypt/example.com_ecc/cert.pem --key-file /etc/letsencrypt/example.com_ecc/private.key --fullchain-file /etc/letsencrypt/example.com_ecc/fullchain.pem --reloadcmd "sudo systemctl reload nginx.service" 
 
	کد PHP:
	
sudo apt install -y nginx 
 
	کد PHP:
	
vim /etc/nginx/sites-available/phorum.conf 
 
	کد PHP:
	
server {  listen 80;  listen 443 ssl;  server_name example.com;  root /var/www/phorum;
  ssl_certificate /etc/letsencrypt/example.com/fullchain.pem;  ssl_certificate_key /etc/letsencrypt/example.com/private.key;  ssl_certificate /etc/letsencrypt/example.com_ecc/fullchain.pem;  ssl_certificate_key /etc/letsencrypt/example.com_ecc/private.key;
  index index.php index.html;
  location / {    try_files $uri $uri/ /index.php?$query_string;  }
  location ~ \.php$ {    include snippets/fastcgi-php.conf;    fastcgi_pass unix:/var/run/php/php7.0-fpm.sock;  }} 
 
	کد PHP:
	
sudo ln -s /etc/nginx/sites-available/phorum.conf /etc/nginx/sites-enabled 
 
	کد PHP:
	
sudo systemctl reload nginx.service 
 
	کد PHP:
	
sudo mkdir -p /var/www/phorum 
 
	کد PHP:
	
sudo chown -R [your_user]:[your_user] /var/www/phorum 
 
	کد PHP:
	
cd /var/www/phorum 
 
	کد PHP:
	
wget https://www.phorum.org/downloads/phorum-5.2.23.tar.gz 
 
	کد PHP:
	
tar xvzf phorum-5.2.23.tar.gzrm phorum-5.2.23.tar.gzmv Core-phorum_5_2_23/* . && mv Core-phorum_5_2_23/.* .rmdir Core-phorum_5_2_23 
 
	کد PHP:
	
cp include/db/config.php.sample include/db/config.php 
 
	کد PHP:
	
vim include/db/config.php 
 
	کد PHP:
	
sudo chown -R www-data:www-data /var/www/phorum 
 برای پایان نصب این صفحه رو باز کنید.
	کد PHP:
	
http://forum.example.com/admin.php 
 تمام