shell初学之PHP

初次接触脚本,写了一个通过Apache实现PHP动态网站的脚本:

#!/bin/bash
yum -y install php
rm -rf /etc/httpd/conf.d/welcome.conf
echo "<?php phpinfo(); ?>" > /var/www/html/index.php
systemctl restart httpd
systemctl enable httpd
firewall-cmd --add-service=http --permanent
firewall-cmd --reload

 

posted @ 2019-08-03 15:11  Wolf_Coder  阅读(187)  评论(0编辑  收藏  举报