Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changing route configuration #174

Closed
fletch3555 opened this issue Aug 25, 2018 · 7 comments
Closed

Changing route configuration #174

fletch3555 opened this issue Aug 25, 2018 · 7 comments

Comments

@fletch3555
Copy link

I'm looking to host my admin panel on a subdomain. Is there a way to change the Nova route configuration so it'll use my subdomain? I know I could wrap the call to Nova::routes()......register() in a Route::group() defining my subdomain, but that doesn't apply to nova-api routes.

Any thoughts? Anyone else get this working?

@fletch3555
Copy link
Author

Any update on this? It's been over 3 weeks now. I don't expect it to work tomorrow, but a note saying it's in progress or "planned" would be nice.

@davidhemphill
Copy link
Contributor

Can you try setting nova.domain in your Nova config file and see if that gets you what you want?

@fletch3555
Copy link
Author

Is that a newer config option? I don't remember seeing anything like that in the version I was using when originally reporting this (1.0.3 I think...?)

I'll give it a shot later when I get home.

@caseydwyer
Copy link

@davidhemphill that seemed to work as expected for me, thanks! @fletch3555 - I added domain above the path option, in config/nova.php— eg:

'domain' => 'admin.my-application.test',
'path' => '/',

For handling local/dev vs. production URL, based on my .env, I would update like this:

'domain' => 'admin.' . env('APP_URL'),
'path' => '/',

@davidhemphill
Copy link
Contributor

@dwyer14 Nice!

@salvisb
Copy link

salvisb commented May 11, 2019

Hi,
I'm keep getting this error: "Missing required parameters for [Route: nova.login] [URI: login]".

I've set domain parameter in config/nova.php to {tenant}.my-domain.local and added entry to vhosts file. I'm running Laravel using php artisan serve.

Any help would be appreciated.

@Brotzka
Copy link

Brotzka commented Jan 19, 2020

Just in case someone faces the same problem like @salvisb :

You have to use the url option instead of the domain option in Novas config file.

Example:

  • for multi-tenancy'url' => '{client}.' . env('APP_DOMAIN', '/'),
  • for a specific subdomain: 'url' => 'admin.' . env('APP_DOMAIN', '/'),

Note that I've added the APP_DOMAIN key to my env-file and my app.php-config-file because you need the domainname without http/https.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants