Coder Social home page Coder Social logo

homestead's Introduction

Laravel Logo

Build Status Total Downloads Latest Stable Version License

About Laravel

Laravel is a web application framework with expressive, elegant syntax. We believe development must be an enjoyable and creative experience to be truly fulfilling. Laravel takes the pain out of development by easing common tasks used in many web projects, such as:

Laravel is accessible, powerful, and provides tools required for large, robust applications.

Learning Laravel

Laravel has the most extensive and thorough documentation and video tutorial library of all modern web application frameworks, making it a breeze to get started with the framework.

You may also try the Laravel Bootcamp, where you will be guided through building a modern Laravel application from scratch.

If you don't feel like reading, Laracasts can help. Laracasts contains thousands of video tutorials on a range of topics including Laravel, modern PHP, unit testing, and JavaScript. Boost your skills by digging into our comprehensive video library.

Laravel Sponsors

We would like to extend our thanks to the following sponsors for funding Laravel development. If you are interested in becoming a sponsor, please visit the Laravel Partners program.

Premium Partners

Contributing

Thank you for considering contributing to the Laravel framework! The contribution guide can be found in the Laravel documentation.

Code of Conduct

In order to ensure that the Laravel community is welcoming to all, please review and abide by the Code of Conduct.

Security Vulnerabilities

If you discover a security vulnerability within Laravel, please send an e-mail to Taylor Otwell via [email protected]. All security vulnerabilities will be promptly addressed.

License

The Laravel framework is open-sourced software licensed under the MIT license.

homestead's People

Contributors

ahsanity avatar alamellama avatar andrewhood125 avatar browner12 avatar cbj4074 avatar crynobone avatar csaba215 avatar deviantintegral avatar dfurnes avatar djuuu avatar driesvints avatar grahamcampbell avatar haampie avatar ideepblue avatar jamshady avatar litan1106 avatar m4olivei avatar martijn94 avatar nickroberts avatar olivierparent avatar piotr-cz avatar ricardoseriani avatar roberto-aguilar avatar sdespont avatar sn0wcrack avatar svpernova09 avatar taylorotwell avatar themaric avatar tillkruss avatar yazeed avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

homestead's Issues

Set file/folder permissions on shared folders

Is there any way to set custom folder permissions for the shared folders on the guest machine? I want to chmod some folders (like Laravel's app/storage folder, file-uploads folderโ€ฆ) but the chmod command doesn't have any effect on them.

I found a solution for other vagrant environments I work on with this setting for the Vagrantfile:

config.vm.synced_folder "./shared", "/var/www", :owner => "www-data", :group => "www-data"

But I don't know if the current Homestead behavior is intended or not.

Thank you!

Missing postgresql-contrib

I wanted to use hstore, intarray and other PostgreSQL extensions, but I could not start using them by command

CREATE EXTENSION hstore;

I had to install postgresql-contrib package first:

sudo apt-get install postgresql-contrib

It would be great, if postgresql-contrib was installed already. ๐Ÿ˜‰

[feature requeset] ability to create databases

I saw a tweet about adding the ability to automatically add databases.

So I've partly added this functionality.

I don't have sufficient knowledge and experiance width postgres to add support for it, but somebody should be able to do it quite easily.

Serve file does not create and link to the folder set

I have tried running the following code and even though it runs and sets the nginx blocks ok, its not linking to the folder in question.

   serve projects.dev /home/vagrant/Code/projects.dev

When i then list the folders within the Code folder i only get the folders that were created via the Yaml config file.

It seems to not be creating the folder and/or linking to it at all.

Running it on a iMac OS Mavericks.
Vagrant 1.6.2
VirtualBox 4.3.12

VMWare_Desktop

Hi,

Small thing - is there any reason we still call the Homestead Box option "vmware_workstation" box as "vmware_desktop"?

See attached picture.

desktop

It is slightly confusing - especially when all the Homestead docs everywhere only ever references one option as "vmware_workstation".

Would be nice to standardize and switch it to be known as "vmware_workstation" in the future if possible? Not sure how that might break box upgrades looking for 'new' versions though?

Install more locale? only en_US in the box

Hi

Possible to install more languages? Look tom me lika only 'en_US' do exists in Homestead and on the Forge machines.


locale -a
C
C.UTF-8
en_US.utf8

POSIX

best regards // johannes

[Proposal] Include MailHog in Homestead

As requested from laravel/ideas#257

I've recently switched away from MailCatcher (due to multiple issues with Ruby + Gems) - and found MailHog - https://github.com/mailhog/MailHog

Mailhog is an alternative for Mailcatcher or Mailtrap.io that doesnt require any special dependencies like Ruby, so installation dead simple. Here is a quick article I found on it: http://iankent.uk/2014/04/20/introducing-go-mailhog/

Here is an example of bash installation script that would cover everything needed to include in Homestead: https://gist.github.com/varghesejacob/68caf7aeee53305a1ffa#file-mailhog-bash-script

MailHog includes hooks (like Mailcatcher) to use in PHPUnit Tests so you can 'test' your emails are been sent etc etc: https://gist.github.com/varghesejacob/6113ac971a00611015c5#file-mailhog-test-helper.

And MailHog has a web viewer - so you can "see" your emails (just like Mailtrap.io etc)

Obviously people could install this themselves - but it would seem to be a natural synergy with Homestead - providing everything 'out of the box'. Taylor has previously tweeted that perhaps MailCatcher should be in Homestead by default: https://twitter.com/taylorotwell/status/536923096213516288 - and it was highly "+1" from many replied tweets (including @JeffreyWay) - so this would potentially be a better 'drop in' replacement.

Obviously there is also MailTraip.io - but Mailhog is a local service - so is much faster/reliable etc etc.

Environment variables

Is it worth setting things like the database variables as environment variables in homestead? This would allow my database config to look something like this:

<?php
    'mysql' => array(
        'driver'    => 'mysql',
        'host'     => getenv('DB_HOST'),
        'database' => 'whatever',
        'username' => getenv('DB_USER'),
        'password' => getenv('DB_PASS'),
        'charset'   => 'utf8',
        'collation' => 'utf8_unicode_ci',
        'prefix'    => '',
    ),

Issue upgrading to 0.3.3

Please note that the Homestead issue tracker is reserved for bug reports and
enhancements. We are not always able to debug Vagrant, Virtualbox, VMWare, or Operating System issues but will do our best to help. Thank you!

Vagrant version

1.9.0

Provider & Provider version

5.1.10

Host operating system

OS X

Homestead.yaml

---
ip: "192.168.10.10"
memory: 2048
cpus: 1
hostname: rollcall
name: rollcall
provider: virtualbox

authorize: ~/.ssh/id_rsa.pub

keys:
    - ~/.ssh/id_rsa

folders:
    - map: "./"
      to: "/home/vagrant/rollcall"

sites:
    - map: rollcall.dev
      to: "/home/vagrant/rollcall/public"

databases:
    - rollcall

variables:
    - key: APP_ENV
      value: local

# blackfire:
#     - id: foo
#       token: bar
#       client-id: foo
#       client-token: bar

# ports:
#     - send: 93000
#       to: 9300
#     - send: 7777
#       to: 777
#       protocol: udp

Vagrant up output

https://gist.github.com/willdoran/0c457bc552f3e68ac7af653b97c04aee

Expected behavior

Vagrant should update to a newer version of homestead and vagrant up should correctly boot and provision the VM

Actual behavior

Provisioning fails due to an expired password
Repaired by the following:
vagrant ssh
mysql -uhomestead -psecret -e "SET PASSWORD = PASSWORD('secret')" --connect-expired-password;
mysql -uroot -psecret -e "SET PASSWORD = PASSWORD('secret')" --connect-expired-password;
exit
vagrant provision

Steps to reproduce

  1. On version 0.3.0 run vagrant box update
  2. Run vagrant up

SQLite?

Wondering if there is a reason SQLite is not included. Seems like using SQLite for local development might be an answer for those concerned that "vagrant destroy" will remove the databases.

VMware (Windows) and IP Allocation

This is not so much a bug as it is just a provider issue (at least I think).

If you set an IP for the homestead box, the VMware provider will ignore it and use its own random IP. I have tested this on 2 different Windows 10 machines and its the same result on each on. I have used the most current version but this is something that has been around since I first started using Homestead.

Vagrant version

Vagrant 1.9.0

Provider & Provider version

VMware Workstation 12.5.2 build-4638234

Host operating system

Windows 10

Homestead.yaml

Simplified with the main relevant information

---
ip: "192.168.50.10"
memory: 2048
cpus: 1
hostname: homestead
name: homestead
provider: vmware_workstation
mariadb: true
gui: true

Vagrant up output

Narrowed to the relevant area.

    homestead: Waiting for machine to boot. This may take a few minutes...
    homestead: SSH address: 192.168.126.129:22
    homestead: SSH username: vagrant
    homestead: SSH auth method: private key

Expected behavior

IP should be the one entered in the Homestead.yaml file.

Actual behavior

A random IP was assigned to the VM

Steps to reproduce

  1. Use the same setup (Windows, VMware Workstation)
  2. Set a custom IP for the box in the Homestead.yaml
  3. Launch the machine.

References

Are there any other GitHub issues (open or closed) that should be linked here?
For example:
None that I could find.

[Proposal] Set UTF8mb4 as the default database character set / collate

With a lot of web apps these days, storing data such as emojis in messages etc has become a common requirement.

Unfortunately the default character set for MySQL in homestead seems to be UTF-8. This doesn't allow the full range of emoji characters (and others) to be stored, and results in a lot of database errors if these types of characters are in the data to be saved.

By using the UTF8mb4 character set, this limitation is bypassed.

I was unable to raise this issue in Laravel settler, but would the project team be at all interested in changing the (default) character set for the homestead database to UTF8mb4?

It would be a simple edit of this line https://github.com/laravel/settler/blob/master/scripts/provision.sh#L204

to

mysql --user="root" --password="secret" -e "CREATE DATABASE homestead character set UTF8mb4 collate utf8mb4_bin;"

Just wanted some thoughts before making the PR.

Some other links to this:
https://twitter.com/adamwathan/status/756569942397419520
http://stackoverflow.com/questions/766809/whats-the-difference-between-utf8-general-ci-and-utf8-unicode-ci/766996#766996

[Proposal] Define multiple databases in Homestead.yaml

Let me define multiple databases (users, passwords, database names) in Homestead.yaml. On vagrant up, you can use an inline provisioner to execute a custom bash script (much like you do with serve.sh now). This script will check to see if each database exists, and if not, create it and the specified user/password.

Access MySQL from box IP

I try connect MySQL database with SSH (Navicat), but I get the following error:

Lost connection to MySQL server at 'reading initial communication packet', system error: 0

To solve:

  1. access: sudo vim /etc/mysql/my.cnf
  2. comment:
    #skip-external-locking
    #bind-address = 127.0.0.1
  3. restart mysql: sudo service mysql restart

Update to MySQL 5.6.x

I think Homestead (and Forge) could benefit from updating to the latest release of MySQL instead of the older version currently installed by default. Yes, we could update this ourselves, but the beauty of Homestead (and Forge) is the ease of local development without custom configuration.

Why MySQL 5.6? Speed: http://www.mysql.com/why-mysql/benchmarks/

What it takes to use the official Oracle Debian package instead of the outdated apt-get version: http://dev.mysql.com/doc/mysql-apt-repo-quick-guide/en/

I just attended an Oracle MySQL talk where the speaker encouraged everyone to be using 5.6 release now because of the dramatic performance improvements especially in InnoDB, with 5.7 on the horizon in March of 2015 with even faster performance.

Let me know if I can help with this in some way too.

Can't vagrant up on ubuntu

The first I add

vagrant box add laravel/homestead

And I had Clone https://github.com/laravel/homestead/ into my /home/code folder. And I setup Laravel framework into my code folder and I named it to example.

And I Configure Homestead.yaml like the following


---
authorize: /Users/uvu/.ssh/id_rsa.pub

keys:
    - /Users/uvu/.ssh/id_rsa

folders:
    - map: /Users/uvu/code/example
      to: /home/vagrant/code/example

sites:
    - map: example.app
      to: /home/vagrant/code/Laravel/public

I generated my ssh with the following command

ssh-keygen -t rsa -C "[email protected]"

I add my example.app host to my /etc/hosts like the following

127.0.0.1  example.app

And When I vagrant up into my homestand I got the following erros. What I was wrong on this setup?

/home/uvu/code/homestead/scripts/homestead.rb:25:in `read': No such file or directory - /Users/uvu/.ssh/id_rsa.pub (Errno::ENOENT)
    from /home/uvu/code/homestead/scripts/homestead.rb:25:in `block in configure'
    from /opt/vagrant/embedded/gems/gems/vagrant-1.6.2/plugins/kernel_v2/config/vm_provisioner.rb:72:in `call'
    from /opt/vagrant/embedded/gems/gems/vagrant-1.6.2/plugins/kernel_v2/config/vm_provisioner.rb:72:in `add_config'
    from /opt/vagrant/embedded/gems/gems/vagrant-1.6.2/plugins/kernel_v2/config/vm.rb:281:in `provision'
    from /home/uvu/code/homestead/scripts/homestead.rb:23:in `configure'
    from /home/uvu/code/homestead/Vagrantfile:9:in `block in <top (required)>'
    from /opt/vagrant/embedded/gems/gems/vagrant-1.6.2/lib/vagrant/config/v2/loader.rb:37:in `call'
    from /opt/vagrant/embedded/gems/gems/vagrant-1.6.2/lib/vagrant/config/v2/loader.rb:37:in `load'
    from /opt/vagrant/embedded/gems/gems/vagrant-1.6.2/lib/vagrant/config/loader.rb:103:in `block (2 levels) in load'
    from /opt/vagrant/embedded/gems/gems/vagrant-1.6.2/lib/vagrant/config/loader.rb:97:in `each'
    from /opt/vagrant/embedded/gems/gems/vagrant-1.6.2/lib/vagrant/config/loader.rb:97:in `block in load'
    from /opt/vagrant/embedded/gems/gems/vagrant-1.6.2/lib/vagrant/config/loader.rb:94:in `each'
    from /opt/vagrant/embedded/gems/gems/vagrant-1.6.2/lib/vagrant/config/loader.rb:94:in `load'
    from /opt/vagrant/embedded/gems/gems/vagrant-1.6.2/lib/vagrant/vagrantfile.rb:28:in `initialize'
    from /opt/vagrant/embedded/gems/gems/vagrant-1.6.2/lib/vagrant/environment.rb:574:in `new'
    from /opt/vagrant/embedded/gems/gems/vagrant-1.6.2/lib/vagrant/environment.rb:574:in `vagrantfile'
    from /opt/vagrant/embedded/gems/gems/vagrant-1.6.2/lib/vagrant/environment.rb:359:in `host'
    from /opt/vagrant/embedded/gems/gems/vagrant-1.6.2/lib/vagrant/environment.rb:168:in `block in action_runner'
    from /opt/vagrant/embedded/gems/gems/vagrant-1.6.2/lib/vagrant/action/runner.rb:33:in `call'
    from /opt/vagrant/embedded/gems/gems/vagrant-1.6.2/lib/vagrant/action/runner.rb:33:in `run'
    from /opt/vagrant/embedded/gems/gems/vagrant-1.6.2/lib/vagrant/environment.rb:346:in `hook'
    from /opt/vagrant/embedded/gems/gems/vagrant-1.6.2/lib/vagrant/environment.rb:556:in `unload'
    from /opt/vagrant/bin/../embedded/gems/gems/vagrant-1.6.2/bin/vagrant:169:in `ensure in <main>'
    from /opt/vagrant/bin/../embedded/gems/gems/vagrant-1.6.2/bin/vagrant:169:in `<main>'

Error with vagrant 1.6.2

When halting the machine with and , the Vagrantfile doesn't load the homestead.rb script.

macbook :~/projects/test/vagrant halt <id>
There was an error loading a Vagrantfile. The file being loaded
and the error message are shown below. This is usually caused by
a syntax error.

Path: /Users/<user>/projects/Homestead/Vagrantfile
Message: cannot load such file -- ./scripts/homestead.rb

Discussion: Why not set root as default credentials for ssh and mysql?

Why not rely in using the root user for the ssh and the root:root for mysql? In a development environment this does not necessary represent a security threat, am I wrong?

Also, if this is intended to be "the default" development environment for Laravel-based (and perhaps other technologies) web applications, using the most common default values is more "default", precisely.

As an example, I had to commit a change on the DB config files for each of my existing projects in order to work on Homestead out-of-the-box. Otherwise, some more steps are required.

Thanks.

[Proposal] cd into site folder when running 'vagrant ssh'

Currently when you run vagrant ssh it will set the current directory to /home/vagrant. It would help a little if it could drop me right into my project's vagrant directory, which usually is a directory deeper, for example /home/vagrant/project.

Unfortunately I don't know bash very well, so I can't contribute this change myself. Hopefully something who can, decides to add this change.

Thanks!

Homestead VM Public Key

I see ~/.ssh/id_rsa, but I don't see ~/.ssh/id_rsa.pub. Is this expected behavior? I would like to have Homestead generate its own public/private key-pair so that I can setup communciation between Homestead VM and remote servers (in my case, for drush usage on Drupal sites).

CPU Virtualization

One of the biggest 'gotchas' when starting out with Laravel is not enabling CPU virtualization. If you dont have it enabled and try to vagrant up then you'll get this:

Waiting for machine to boot. This may take a few minutes...
The guest machine entered an invalid state while waiting for it
to boot. Valid states are 'starting, running'. The machine is in the
'poweroff' state. Please verify everything is configured
properly and try again.

But if you try to vagrant up homestead when you still dont have virtualization enabled its difficult to debug because all you get is ssh connection timeouts:

==> default: Waiting for machine to boot. This may take a few minutes...
    default: SSH address: 127.0.0.1:2222
    default: SSH username: vagrant
    default: SSH auth method: private key
    default: Warning: Connection timeout. Retrying...
    default: Warning: Connection timeout. Retrying...
    default: Warning: Connection timeout. Retrying...
    default: Warning: Connection timeout. Retrying...
    default: Warning: Connection timeout. Retrying...

I dont know much about Vagrant but I'm guessing its something in the homestead boot script that doesnt check if the machine fully boots or not?

I figure this could be a big issue as Laravel is becoming peoples first framework, Homestead is sure to be a lot of persons first foray into using Vagrant.

UTC timezone by default

Wouldn't be better if the server was configured to use UTC timezone by default? Currently it's configured to use CDT which is "inherited" by the MySQL server as well.

Loving Homestead so far. Thank you!!!

[Proposal] Add possibility to install locales on first vagrant up

Hi!

I'm using Russian locale in PHP, and after any vagrant destroy / up I have to manually add russian locales to ubuntu. Still its a rare situation though, when I need to destroy the box.

Is it possible to have a feature in future to somehow automate this process e.g. by means of Homestead.yaml ?

As a workaround, theoretically, I can add a bash-script to do this for me by issuing a single command, but I'm not good at scripting yet.

sudo locale-gen ru_RU
sudo locale-gen ru_RU.UTF-8

Try to start php-fpm7.0

Hello

Since the 1.0.0 image, when i provision the vm the script try to start php-fpm7.0 but it doesn't exist because now it's php-fpm7.1

==> homstead: Failed to restart php7.0-fpm.service: Unit php7.0-fpm.service not found.
The SSH command responded with a non-zero exit status. Vagrant
assumes that this means the command failed. The output for this command
should be in the log above. Please read the output to determine what
went wrong.

vagrant@homstead:$ sudo su -
root@homstead:
# /etc/init.d/php7.1-fpm start
[ ok ] Starting php7.1-fpm (via systemctl): php7.1-fpm.service.

[feature request] add zsh to the box

So I understand that the "laravel/homestead" box should be kept relatively clean and that I need to install an special dependencies my self as a provisioning step. That being said I see

alias ..="cd .."
alias ...="cd ../.."

alias h='cd ~'

in the alias file which leads me to suggest that oh-my-zsh is bundled in the box. I personally always use zsh over bash.

One of the nice things about zsh is that you don't have to type cd so those aliases could be removed. Just a suggestion.

Virtualbox doesn't connect the network adapter cable

Vagrant version

Vagrant 1.9.0

Provider & Provider version

Virtualbox 5.0.30 ; Virtualbox 5.0.10 ; Virtualbox 5.1.2

Host operating system

Sierra ; Windows 10

Homestead.yaml

---
ip: "192.168.10.10"
memory: 2048
cpus: 1
hostname: reploc
name: reploc
provider: virtualbox

authorize: ~/.ssh/id_rsa.pub

keys:
    - ~/.ssh/id_rsa

folders:
    - map: "/Users/a/Sites/Reploc"
      to: "/home/vagrant/reploc"

sites:
    - map: homestead.app
      to: "/home/vagrant/reploc/public"

databases:
    - homestead

# blackfire:
#     - id: foo
#       token: bar
#       client-id: foo
#       client-token: bar

# ports:
#     - send: 50000
#       to: 5000
#     - send: 7777
#       to: 777
#       protocol: udp

Vagrant up output

https://gist.github.com/JulienTant/f81d9f9b2bafa76a784946400214314f

Expected behavior

Vagrant creates a virtualbox machine with a connected cable

Actual behavior

Vagrant creates a virtualbox machine with a disconnected cable

Steps to reproduce

  1. vagrant destroy
  2. vagrant up

Steps to fix manually

  1. vagrant destroy
  2. vagrant up
  3. vagrant halt
  4. Go to the VM VB settings to connect the cable manually
  5. vagrant up

References

Command not found error

I was getting an error for unsupported locale setting when I tried to run a command that wasn't installed. This is the full error log:

vagrant@homestead:~/code/driesvints/driesvints.com$ sass
Sorry, command-not-found has crashed! Please file a bug report at:
https://bugs.launchpad.net/command-not-found/+filebug
Please include the following information with the report:

command-not-found version: 0.3
Python version: 3.4.0 candidate 1
Distributor ID: Ubuntu
Description:    Ubuntu 14.04 LTS
Release:    14.04
Codename:   trusty
Exception information:

unsupported locale setting
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/CommandNotFound/util.py", line 24, in crash_guard
    callback()
  File "/usr/lib/command-not-found", line 69, in main
    enable_i18n()
  File "/usr/lib/command-not-found", line 40, in enable_i18n
    locale.setlocale(locale.LC_ALL, '')
  File "/usr/lib/python3.4/locale.py", line 592, in setlocale
    return _setlocale(category, locale)
locale.Error: unsupported locale setting

I fixed it with the following solution: http://askubuntu.com/questions/205378/unsupported-locale-setting-fault-by-command-not-found

Now I get a correct error message:

vagrant@homestead:~/code/driesvints/driesvints.com$ sass
The program 'sass' is currently not installed. To run 'sass' please ask your administrator to install the package 'ruby-sass'

Has anyone else experienced this problem?

HHVM for Cli

I would love to see HHVM coming out the box, it's really useful for using with composer, much much much faster ๐Ÿ‘

Slashes and backslashes on Windows

I ran into a problem on Windows 7 x64.

Error was thrown:

/tmp/vagrant-shell: line 1: /home/vagrant/.ssh/$2: ambiguous redirect

My Homestead.yaml contents:


---
authorize: C:\Users\Me\.ssh\id_rsa.pub

keys:
    - C:\Users\Me\.ssh\id_rsa

folders:
    - map: C:\var\www
      to: /home/vagrant/www

sites:
    - map: awesome.app
      to: /home/vagrant/www/awesome/public

Everything went went fine after I replaced all backslashes \ with slashes /.

Would be cool if Homestead did at least tell me to use forward-slashes only, even on Windows.

Otherways, good job! ๐Ÿ˜‰

vagrant up timeout

A little research leads me to believe that the homestead box isn't booting on Linux. I had a friend also running Linux try and got the same result.

Opening VirtualBox shows the VM running, but the preview window is totally blank. Another friend on a Mac is able to run it just fine, his VirtualBox preview window looks as you'd expect it to.

Here's the output of vagrant up:

Bringing machine 'default' up with 'virtualbox' provider...
==> default: Checking if box 'laravel/homestead' is up to date...
==> default: Clearing any previously set forwarded ports...
==> default: Clearing any previously set network interfaces...
==> default: Preparing network interfaces based on configuration...
    default: Adapter 1: nat
    default: Adapter 2: hostonly
==> default: Forwarding ports...
    default: 80 => 8000 (adapter 1)
    default: 3306 => 33060 (adapter 1)
    default: 5432 => 54320 (adapter 1)
    default: 22 => 2222 (adapter 1)
==> default: Running 'pre-boot' VM customizations...
==> default: Booting VM...
==> default: Waiting for machine to boot. This may take a few minutes...
    default: SSH address: 127.0.0.1:2222
    default: SSH username: vagrant
    default: SSH auth method: private key
    default: Warning: Connection timeout. Retrying...
    default: Warning: Connection timeout. Retrying...
    default: Warning: Connection timeout. Retrying...
    default: Warning: Connection timeout. Retrying...
    default: Warning: Connection timeout. Retrying...
    default: Warning: Connection timeout. Retrying...
    default: Warning: Connection timeout. Retrying...
    default: Warning: Connection timeout. Retrying...
    default: Warning: Connection timeout. Retrying...
    default: Warning: Connection timeout. Retrying...
    default: Warning: Connection timeout. Retrying...
    default: Warning: Connection timeout. Retrying...
    default: Warning: Connection timeout. Retrying...
    default: Warning: Connection timeout. Retrying...
    default: Warning: Connection timeout. Retrying...
    default: Warning: Connection timeout. Retrying...
    default: Warning: Connection timeout. Retrying...
    default: Warning: Connection timeout. Retrying...
    default: Warning: Connection timeout. Retrying...
Timed out while waiting for the machine to boot. This means that
Vagrant was unable to communicate with the guest machine within
the configured ("config.vm.boot_timeout" value) time period.

If you look above, you should be able to see the error(s) that
Vagrant had when attempting to connect to the machine. These errors
are usually good hints as to what may be wrong.

If you're using a custom box, make sure that networking is properly
working and you're able to connect to the machine. It is a common
problem that networking isn't setup properly in these boxes.
Verify that authentication configurations are also setup properly,
as well.

If the box appears to be booting properly, you may want to increase
the timeout ("config.vm.boot_timeout") value.

Installing Homestead on Digital Ocean droplet.

I tried installing homestead on digital ocean droplet using digital ocean plugin for vagrant But no success. This is my Vagrantfile

Vagrant.configure('2') do |config|

  config.vm.define "hot-shot" do |config|
      config.vm.provider :digital_ocean do |provider, override|
        override.ssh.private_key_path = '~/.ssh/vagrant_rsa'
        override.vm.box = 'digital_ocean'
        override.vm.box_url = "https://atlas.hashicorp.com/laravel/boxes/homestead/versions/1.0.1/providers/virtualbox.box"
        provider.token = 'lorm-ipsom'
        provider.image = 'ubuntu-16-04-x64'
        provider.region = 'blr1'
        provider.size = '512mb'
      end
  end

end

Please let me know what am I missing? Thanks ๐Ÿ‘

connect to database

Hi

I cant connect to the databas from my app (works fine from sequel pro). See my app config, and error message. Guess I do miss something?

SQLSTATE[28000] [1045] Access denied for user 'homestead'@'localhost' (using password: YES)

'mysql' => array(
'driver' => 'mysql',
'host' => 'localhost',
'database' => 'homestead',
'username' => 'homestead',
'password' => 'secret',
'charset' => 'utf8',
'collation' => 'utf8_unicode_ci',
'prefix' => '',
),

Error while running vagrant up

I'm experiencing a problem while trying to use homestead on my machine.

The VM still runs and the folders I've shared are properly present but I can't access the site on my browser.

Here's the error:

==> default: /vagrant/scripts/serve.sh: line 2: $'\r': command not found
==> default: /vagrant/scripts/serve.sh: line 38: $'\r': command not found
==> default: Usage: nginx {start|stop|restart|reload|force-reload|status|configtest|rotate|upgrade}
The following SSH command responded with a non-zero exit status.
Vagrant assumes that this means the command failed!

chmod +x /tmp/vagrant-shell && /tmp/vagrant-shell "test.app" "C:/Users/Emanuele/works/test"

Stdout from the command:


Stderr from the command:

/vagrant/scripts/serve.sh: line 2: $'\r': command not found
/vagrant/scripts/serve.sh: line 38: $'\r': command not found
Usage: nginx {start|stop|restart|reload|force-reload|status|configtest|rotate|upgrade}

When I try to access to access the VM with vagrant shh I also got:

: command not found
: command not found
-bash: /home/vagrant/.bash_aliases: line 7: syntax error near unexpected token `$'{\r''
'bash: /home/vagrant/.bash_aliases: line 7: `function serve() {

For reference I'm running Vagrant 1.6.2 on Windows 7 x64.

postgres CREATE EXTENSION error

hello artisan , i installed homestead and when i run a postgres query for creation extension i get this error :

create extension unaccent;

[Err] ERROR: could not open extension control file "/usr/share/postgresql/9.3/extension/unaccent.control": No such file or directory

homestead offline error

I ran vagrant halt before i had put my notebook to sleep. The next day when I was traveling by train I wanted to boot the homestead vagrant box with vagrant up. (traveling => offline)

I got the following output and was unable to start working on my project:

$ vagrant up
Bringing machine 'default' up with 'virtualbox' provider...
==> default: Checking if box 'laravel/homestead' is up to date...
An error occurred while downloading the remote file. The error
message, if any, is reproduced below. Please fix this error and try
again.

Couldn't resolve host 'vagrantcloud.com'

I think vagrant should be warning the user but proceed so one is able booting up in this scenario. I'll just keep it running all the time now to prevent this kind of situation. Anyways that could easily be forgotten thought.

Expired password

Please note that the Homestead issue tracker is reserved for bug reports and
enhancements. We are not always able to debug Vagrant, Virtualbox, VMWare, or Operating System issues but will do our best to help. Thank you!

Vagrant version

Vagrant 1.8.4

Provider & Provider version

Virtualbox 4.3.38r106717

Host operating system

Linux elementary OS 0.3.2 Freya (64-bit) - Built on Ubuntu 14.04

Homestead.yaml

---
ip: "192.168.10.10"
memory: 2048
cpus: 1
provider: virtualbox
version: "0.3.3"
authorize: ~/.ssh/id_rsa.pub
keys:
    - ~/.ssh/id_rsa
folders:
    - map: ~/Code/TrueRev
      to: /home/vagrant/Code/TrueRev
sites:
    - map: truerev.dev
      to: /home/vagrant/Code/TrueRev/public        
databases:
    - homestead
    - truerev_testing
# blackfire:
#     - id: foo
#       token: bar
#       client-id: foo
#       client-token: bar
# ports:
#     - send: 50000
#       to: 5000
#     - send: 7777
#       to: 777
#       protocol: udp

Vagrant up output

https://gist.github.com/marabesi/7ea2a575b6e0c06b59f3384f10bab3b1

Expected behavior

Vagrant should have migrated the files into the database successfully.

Actual behavior

The vagrant up command fails with the following

==> default:   SQLSTATE[HY000] [1862] Your password has expired. To log in you must change it using a client that supports expired passwords.  
==> default:                                                                                                                                   
==> default:                                                                                                                                   
==> default:   [PDOException]                                                                                                                  
==> default:   SQLSTATE[HY000] [1862] Your password has expired. To log in you must change it using a client that supports expired passwords.  

Steps to reproduce

  1. git clone https://github.com/laravel/homestead.git ~/homestead
  2. add the follwoing line to your ~/.homestead/Homestead.yaml
version: "0.3.3"
  1. cd ~/homestead && vagrant up

References

SSL

I'd love to see default self signed certificates on each added site.
HTTPS may behave different to HTTP sometimes which would be good being able to test thought.

eth0 IP Address?

I seem to be having network issues with Homestead, which causes the box to suffer from severe lag. It appears that the box is getting assigned an that's conflicting with my router.

Comparing the Homestead eth0 address (with ifconfig) with the same on a working vagrant box reveals the following:

Working Box
inet addr:10.0.2.15 Bcast:10.0.2.255 Mask:255.255.255.0

Homestead Box
inet addr:192.168.0.15 Bcast:192.168.255.255 Mask:255.255.0.0

If I turn off my WiFi connection the lag is gone instantly, so I'm sure it's a networking/conflict issue.

I'm just wondering why/how Homestead is assigned that particular IP and if there's a way of changing it. I've never had this issue with any other Vagrant box.

Not able to connect to VM on Windows 7

Vagrant version

Vagrant 1.9.0

Provider & Provider version

VirtualBox 5.0.30 r112061

Host operating system

Windows 7 x64 Ultimate SP1

Homestead.yaml

---
ip: "192.168.10.10"
memory: 1024
cpus: 1
provider: virtualbox

authorize: ~/.ssh/id_rsa.pub

keys:
    - ~/.ssh/id_rsa

folders:
    - map: D:\Dev\projects
      to: /home/vagrant/projects

sites:
    - map: '~^(?<project>.+)\.app$'
      to: /home/vagrant/projects/\$project/public

databases:
    - homestead

Vagrant up output

https://gist.github.com/jaden/ea07b79d9f55e84d80244486b84fbac6

Expected behavior

192.168.10.10 should have been set as the static IP

Actual behavior

The VM appears to hang, but the console shows the following message (updating until the 5 minutes have elapsed)

[*** ] A start job is running for Raise network interface (2min 35s / 5min 3)

Once the VM boots, it has no static ip, as ifconfig shows:

enp0s3    Link encap:Ethernet  HWaddr 08:00:27:b5:5b:5e
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:144901 errors:0 dropped:0 overruns:0 frame:0
          TX packets:39078 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)

lo        Link encap:Local Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:65536  Metric:1
          RX packets:69 errors:0 dropped:0 overruns:0 frame:0
          TX packets:69 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1
          RX bytes:36681 (36.6 KB)  TX bytes:36681 (36.6 KB)

Steps to reproduce

  1. Run vagrant up with the laravel/homestead box version 0.6.0 on a Windows 7 host.
  2. Wait for the 5 minute time-out

Using the previous box version (0.5.0) by adding the following line to Homestead.yaml sets the static IP and boots up normally:
version: "0.5.0"

No input file specified.

I get a No input file specified. error when I try to run anything other then the root route on Laravel. Is this an nginx error?

Homestead Box Mcrypt

Versions

  • Vagrant: Vagrant 1.9.0
  • Provider: Virtualbox 5.1.10 r112026 (Qt5.6.2)
  • Homestead: 1.9.0

The latest Homestead Box doesn't have Mcrypt installed by default, and also now no longer works with Laravel 4.2 legacy projects once I install Mcrypt sudo apt-get install -y php7.1-mcrypt

Function mcrypt_get_iv_size() is deprecated inside /vendor/laravel/framework/src/Illuminate/Encryption/Encrypter.php line 305

Function mcrypt_get_iv_size() is deprecated

Calling "serve" command without parameters corrupts nginx configuration

Tried to execute mentioned command without parameters in hope it will output some kind of help about usage. Instead, it was executed as is, and after it nginx failed to start/restart.

2014/05/24 07:34:09 [crit] 1621#0: pread() "/etc/nginx/sites-enabled/sites-available" failed (21: Is a directory)

Seems that in this case it creates a directory "sites-available" inside "sites-enabled" which causes error. I simple deleted it and nginx started to work normally.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.