Configure - mcuyar/station GitHub Wiki

Station has many options for configuring the homestead environment for your specific needs. Let's get started by creating a config file.

In the project directory copy the config-sample.yaml file and rename it to config.yaml.

Terminal: cp config-sample.yaml config.yaml.

Virtual Machine Settings

We will start by configuring your virtual machine settings for vagrant. Open the config.yamlfile in your favorite text editor.

Configure the vagrant box to use with station

A good option for customizing a box for station is using laravel/settler: https://github.com/laravel/settler

box: laravel/homestead

Configure the virtual machines Hostname

Configure a custom hostname for the vagrant environment. Change this value if you want to run multiple vagrant machine instances at the same time.

hostname: station

Configure the virtual machines IP Address

Bind a custom ip address to the virtual machine. Remember this IP address, as it will be used to map domains to your host machines hosts file. Change to a unique value if you are running multiple vagrant machine instances at the same time.

ip: "192.168.10.10"

Configure the virtual machines Memory Allocation

Amount of memory to allocate from the host environment. Setting this value too low will greatly affect the performance of the virtual machine.

memory: 2048

Configure the number virtual machine CPU's

Number of CPU's to allocate from the host environment.

cpus: 1

Configure the virtual machines Port Forwarding

Forward ports to the host machine to allow access from localhost (127.0.0.1)

forwarded_ports:
    http: 8000
    mysql: 3306
    postgresql: 5432

Configure SSH

Pass ssh public and private keys from the host machine to the virtual machine. The default settings will map the to the user home folders ssh location if you are using Mac OSX or linux.

If you haven't already. Setup the keys on your host machine to map to Station. A great tutorial for this be found at Github: generating-ssh-keys.

ssh:
  authorize: ~/.ssh/id_rsa.pub
  keys:
    - ~/.ssh/id_rsa
    # - ~/.ssh/amazon_web_services.pem

Set git configuration for the vagrant environment

If you have already set up your git configuration on your host machine, you can copy the file directly to the virtual machine by just passing the path to the git-config parameter.

git-config: ~/.gitconfig

Or you can set a custom git configuration for the environment manually. Visit git-scm.com for a list of git config options

git-config:
    user.name: "Your Name"
    user.email: [email protected]
    colors.ui: "true"
    push.default: simple