Different admin URL for each website - Magento 2.1.1
-
03-10-2020 - |
Question
I trying to configure M2 (2.1.1) multiwebsite.
I already created separate websites/stores/views for each website, I also configured vhosts, M2 admin config and .htaccess. All websites are works fine except one thing.. admin login URL. How to set up this URLs like this:
example.com/admin - root M2 website admin login works fine
example2.com/admin - other M2 website admin login
Now, if i trying to access example2.com i get errors : http://pastebin.com/VbCqGzSV
Here you have my other setting:
.htaccess config:
###########################################
## settings fot webiste example2.com
## WEBSITE CODE: example2com
SetEnvIf Host .*example2.com.* MAGE_RUN_CODE=example2com
SetEnvIf Host .*example2.com.* MAGE_RUN_TYPE=website
###########################################
## example2.com
RewriteCond %{HTTP_HOST} ^(.*)example2\.com
RewriteRule .* – [E=MAGE_RUN_CODE:example2com]
RewriteCond %{HTTP_HOST} ^(.*)example2\.com
RewriteRule .* – [E=MAGE_RUN_TYPE:website]
## END OF: example2.com
Also vHost config file:
<VirtualHost *:80>
DocumentRoot /var/www/html/example2
ServerName example2.com
SetEnv MAGE_RUN_CODE "example2com"
SetEnv MAGE_RUN_TYPE "website"
</VirtualHost>
La solution
Lyczos, magento does not have this type of feature.
In magento admin, is also a store.As per as, magento store max 1 url.So you cannot use different admin urls for each websites
Licencié sous: CC-BY-SA avec attribution
Non affilié à magento.stackexchange