php - yii2+nginx, subdomain to module -
i have project working on yii2 (backend nginx). project has several modules, can conditionally called:
- category 1 (cat1)
- category 2 (cat2)
it required implement functionality when requesting cat1.coolsite.example
, opens module available coolsite.example/cat1
. accordingly, second category
try adding 2 server configs modules 1 , @ nginx error.log if doesn't trick.
server { listen 80; server_name cat1.coolsite.example,; location / { proxy_pass coolsite.example/cat1/$uri; } }
Comments
Post a Comment