forked from pimcore/pimcore
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Readme] Add instructions for multiple applications on same domain (p…
…imcore#17699) * add instrcutions for multiple applications on same domain * Create 08_Multi_Application_Setup.md * Update 08_Multi_Application_Setup.md * Update 08_Multi_Application_Setup.md
- Loading branch information
1 parent
2c42dd3
commit 56f8f15
Showing
2 changed files
with
24 additions
and
0 deletions.
There are no files selected for viewing
23 changes: 23 additions & 0 deletions
23
...tallation_and_Upgrade/03_System_Setup_and_Hosting/08_Multi_Application_Setup.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
# Multi-application setup | ||
|
||
## Sessions | ||
|
||
When running multiple applications on the same domain, there can be session cookie collisions which prevent you to log in to both systems at the same time. | ||
|
||
Imagine you run a web shop app on http://example.org and Pimcore on http://pim.example.org. Then you will have 2 cookies with name `PHPSESSID` (if `session.name` in php.ini is the same for both): | ||
| Name| Value | Domain | Path | | ||
|---|---|---|---| | ||
| PHPSESSID | 5a9b08750387d9e11c738a2947d93e38 | .example.org | / | | ||
| PHPSESSID | irqnjh5p96gp2i8iu743ulm32p | pim.example.org | / | | ||
|
||
First one is from the web shop, second one from Pimcore. | ||
When trying to log in at http://example.org/admin you will get a 403 Forbidden error. | ||
(The reason why the web shop sets the cookie for `.example.org` instead of `example.org` probably is to also support subdomains.) | ||
|
||
You can prevent this problem with the following config in your `config.yaml`. This way the session cookies do not conflict anymore and you will be able to log in to both applications at the same time. | ||
```yaml | ||
framework: | ||
session: | ||
name: "PIMCORE_SESSION_ID" | ||
``` | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters