Comments (10)
You can manually add a subdomain, if you'd like:
cd Sites/mergency
valet link burger.mergency
valet link coffee.mergency
valet link tea.mergency
Since I've run valet park
on the Sites
directory, this directory is now serving all of the following URLs:
- mergency.dev
- burger.mergency.dev
- coffee.mergency.dev
- tea.mergency.dev
from valet.
@MehmetNuri, it should just work, don't need to configure anything. If you have a site available at my-app.dev
, foo.my-app.dev
will already route to that project automatically.
from valet.
@jdavidbakr 👍 Thought you might say that, but wanted to expose this option in here in case it solved your or others' problems.
from valet.
@mattstauffer - yeah, but in my case, I am using the subdomains as a user-level identifier, so ideally I'd like to be able to add subdomains while playing with it that are not necessarily persistent and that I don't have to go in and create the link every time I need a new one. The solution of changing the server.php setup is working great, but it would be nice to have this configurable somehow so it doesn't get overwritten if I pull an update to valet.
from valet.
@mattstauffer I've tried that before with little luck, but this time around it worked. Thanks :) I rarely use more than 2 subdomains, but adding some kind of wildcard support could be nice.
from valet.
Just sent a PR to allow dynamic/wildcard subdomains: #267.
from valet.
This would save me some headache as well. We're also using subdomain groups.
from valet.
👍 to allow wildcards
from valet.
How i can route subdomains dynamic with valet?
from valet.
if you want support multi domain use this code
ln -s ~/Projects/directory ~/.valet/Sites/domain_name
Example:
ln -s ~/Projects/laravel ~/.valet/Sites/taylor
And change route file
Route::group(['domain' => 'laravel.app'], function()
{
Route::get('/', function () {
return "Main Domain";
});
});
Route::group(['domain' => 'taylor.app'], function()
{
Route::get('/', function () {
return "Taylor Domain";
});
});
//or
Route::group(['domain' => '{domain}.{tld}'], function ()
{
Route::get('/', function () {
return "Taylor Domain";
});
});
In this project, project name is laravel , main domain is laravel.app and taylor domain is taylor.app
Note: I don't use .dev domain. If you are use default valet settings, your domains are laravel.dev and taylor.dev
from valet.
Related Issues (20)
- Isolate command doesn't work, can't get [email protected] working HOT 13
- Platform check brakes valet on older PHP versions (<8.1) HOT 2
- Static files don't load in Statamic 3/4+ HOT 10
- valet stop do not stop dnsmasq service (macOS) HOT 5
- Wrong SSL Certificate Being Used HOT 3
- The current configuration and driver for TYPO3 does not work with version 11 of the CMS HOT 4
- Ngrok not finding authtoken HOT 3
- Valet 502 Error working with PostgreSQL and MongoDB HOT 101
- Warning: require_once(./cli/includes/require-drivers.php): Failed to open stream with custom driver for Symfony project HOT 7
- Running Valet with ExpressVPN not work HOT 21
- Any error in the system gives a 502 Gateway error and php-fpm.log file size in increased by ~1.1gb HOT 4
- update 4.0 bug
- Upgraded to Apple M1 now Valet services are erroring after being resintalled HOT 10
- nginx: [warn] the "http2_push_preload" directive is obsolete & the "listen ... http2" directive is deprecated HOT 2
- 502 Bad Gateway : upstream prematurely closed connection while reading response header from upstream HOT 6
- My extensions all stopped working after upgrading to v4 HOT 4
- Valet share not works HOT 2
- PHP 8.3 HOT 5
- Valet install - not starting nginx and dnsmasq HOT 1
- When using valet, sys_get_temp_dir() does return /var/tmp instead of /var/folders/7s/jq24sk81665c1j4y3v9l3vth0000gn/T HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from valet.