# 安装 centos
cd /etc/sysconfig/network-scripts/
vi ifcfg-xxx
# 修改 ONBOOT="no" 为 "yes"
# 修改 BOOTPROTO=dhcp 为 "static"
# 虚拟机切换成桥接模式

#########################
IPADDR=your ip
NETMASK=
GATEWAY=
DNS1=
#########################
# 可以不用执行 yum update -y
systemctl restart network && mv /etc/localtime /etc/localtime.bak && ln -s /usr/share/zoneinfo/Asia/Shanghai /etc/localtime && yum install -y epel-release zip unzip vim wget ed mlocate && rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-7.rpm && rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm && yum install -y php71w httpd mariadb mariadb-server php71w-mysql php71w-xml php71w-soap php71w-cli php71w-xmlrpc php71w-mbstring php71w-json php71w-gd php71w-mcrypt && systemctl enable httpd.service && systemctl enable mariadb.service && systemctl start httpd.service && systemctl start mariadb.service && systemctl start firewalld.service && firewall-cmd --zone=public --add-port=80/tcp --permanent && systemctl restart firewalld.service && mysqladmin -u root password

wget https://files.phpmyadmin.net/phpMyAdmin/4.6.4/phpMyAdmin-4.6.4-all-languages.tar.gz && tar xvfz phpMyAdmin-4.6.4-all-languages.tar.gz && rm -rf phpMyAdmin-4.6.4-all-languages.tar.gz && mv phpMyAdmin-4.6.4-all-languages /var/www/html/pmd && cd /var/www/html && cd pmd && cp config.sample.inc.php config.inc.php && vi config.inc.php

cd /var/www/html && curl -O https://getcomposer.org/installer && php installer && rm -f installer && mv composer.phar /usr/local/bin/ && composer.phar config -g repo.packagist composer https://packagist.phpcomposer.com && composer.phar create-project laravel/laravel && chmod -R 755 /var/www/html/laravel/storage /var/www/html/laravel/bootstrap/cache && chown -R apache.apache /var/www/html/laravel/storage /var/www/html/laravel/bootstrap/cache && cd /var/www/html/laravel/public && php artisan key:generate && php artisan make:auth && php artisan migrate && mv /var/www/html/pmd ./ && setenforce 0 && systemctl stop firewalld && vim /etc/httpd/conf/httpd.conf

1. 找到以下内容,
Include conf.modules.d/*.conf
在上面一行之后添加以下内容,
LoadModule rewrite_module modules/mod_rewrite.so

2. AllowOverride None    # 改成 All

3. /var/www/html => /var/www/html/laravel/public

systemctl restart httpd && vim /var/www/html/laravel/config/database.php
# 修改 charset 和 collation 为 utf8 和 utf8_general_ci

vim /var/www/html/laravel/.env
# 在.env文件中设置如下
mysql 的 账户、密码、数据库

MAIL_DRIVER=smtp
MAIL_HOST=smtp.qq.com
MAIL_PORT=465
MAIL_USERNAME=00000000000@qq.com
MAIL_PASSWORD=填写授权码(在QQ邮箱设置-账户-POP3/IMAP/SMTP/Exchange/CardDAV/CalDAV服务-生成授权码)
MAIL_ENCRYPTION=ssl

# 在config/mail.php文件中设置如下
vim /var/www/html/laravel/config/mail.php
'from' => ['address' => '00000000000@qq.com', 'name' => 'Laravel5'],

最新文章

  1. CQRS及.NET中的参考资料
  2. 【bzoj1367】[Baltic2004]sequence
  3. C#泛型-小心使用静态成员变量
  4. fill_parent和wrap_content的区别
  5. UI-程序的运行顺序
  6. iOS:CALayer核心动画层上绘图
  7. [转载]C# Random 生成不重复随机数
  8. struts_ognl详解
  9. WPF XAML之bing使用StringFormat(转)
  10. IOS UITextField &UITextView
  11. SVN常见错误两项纪录
  12. JavaEE开发之SpringBoot整合MyBatis以及Thymeleaf模板引擎
  13. clear命令新认识
  14. Beamer 中的页面链接
  15. Django小技巧——使用package管理app
  16. CAP原则
  17. Mysql 多字段去重
  18. 【题解】LFYZNoip前水题赛 T6
  19. WPF 手机验证码 发送按钮倒计时 代码
  20. (转)Mysql数据库之Binlog日志使用总结

热门文章

  1. PHP CI 框架初识(一)
  2. Junit : how to add listener, and how to extends RunListener to override behaviors while failed
  3. c++中字符输入函数cin.getline在输入char与string时的不同
  4. Java中this和super的用法总结(转)
  5. 第一章 SpringCloud简介
  6. LoadRunner 技巧之 集合点设置
  7. SpringMVC以POST提交表单中文乱码解决方案。
  8. cosbench 安装
  9. MYSQL5.5 linux安装
  10. LeetCode.1047-重复删除字符串中的所有相邻重复项