内置软件
* Ubuntu 14.04
* PHP 5.6
* HHVM
* Nginx
* MySQL (5.7.9)
* Postgres
* Node (With Bower, Grunt, and Gulp)
* Redis
* Memcached
* Beanstalkd
* Laravel Envoy
* Blackfire Profiler
默认数据库
账号 uhomestead
密码 secret
连接地址 192.168.10.10
vagrant up 启动命令
需在命令行 homestead-master 目录下执行。
否则提示:
A Vagrant environment or target machine is required to run this
command. Run `vagrant init` to create a new Vagrant environment. Or,
get an ID of a target machine from `vagrant global-status` to run
this command on. A final option is to change to a directory with a
Vagrantfile and to try again.
正确提示如下:
默认端口
- SSH: 2222 → Forwards To 22
- HTTP: 8000 → Forwards To 80
- HTTPS: 44300 → Forwards To 443
- MySQL: 33060 → Forwards To 3306
- Postgres: 54320 → Forwards To 5432
配置共享文件夹
在Homestead.yaml文件中配置,文件更改后,本地计算机和Homestead 保持同步。
folders:
- map: ~/Code
to: /home/vagrant/Code
启用 NFS:
folders:
- map: ~/Code
to: /home/vagrant/Code
type: "nfs"
NFS(Network File System)即网络文件系统,是FreeBSD支持的文件系统中的一种,它允许网络中的计算机之间通过TCP/IP网络共享资源。在NFS的应用中,本地NFS的客户端应用可以透明地读写位于远端NFS服务器上的文件,就像访问本地文件一样。
注:Windows用户:NFS文件夹不会在Windows主机上运行。