1
votes

I just set up default Windows 10/Homestead/Vagrant/Virtualbox/Nginx. Didn't change anything out of the box. I'm hyper new to this.

I set up a custom site in Homestead.yaml and the welcome page works.

I'm changing this:

Route::get('/', function () {
    return view('welcome');
});

to this:

Route::get('/test', function () {
    return view('welcome');
});

A simple 404 is served. I'm adding test controllers with artisan but everything throws a 404. My settings seem fine, I checked the yaml file and Nginx config (quite new to Nginx though). Vagrant reload --provision (or vagrant halt/up) don't help.

(If this is a dupe I will delete, I've looked though).

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

authorize: C:\Users\computeruser\.ssh\id_rsa.pub

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

folders:
    - map: /Users/computeruser/Documents/Projects/vue.js/Full-Stack-Vue.js-2-and-Laravel-5/vuebnb
      to: /home/vagrant/projects

sites:
    - map: vuebnb.test
      to: /home/vagrant/projects/vuebnb/public

databases:
    - homestead

variables:
    - key: APP_ENV
      value: local

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

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

updated answer with yaml. I check via SSH and the file isn't updated.

1
Dumb question but are you getting a 404 on http://localhost:4567 or http://localhost:4567/test ? (Your port numbers may not be 4567 of course)SystemGlitch

1 Answers

0
votes

Try clearing the caches:

php artisan cache:clear
php artisan route:clear

(Run these commands from the VM while being located in the root folder of your app)