combine symfony1 and Symfony2 projects

前端 未结 1 2026
臣服心动
臣服心动 2021-02-06 16:18

There is an existing website developed in symfony1.0 (propel as ORM). I have developed a module in Symfony2 (Doctrine2 as ORM) for the website. Both have authentication. New mod

相关标签:
1条回答
  • 2021-02-06 16:43

    I think you should create a custom user provider in your Symfony2 project to be able to share the users between two projects (but first check if you could use the doctrine user provider).

    You should also implement a custom authentication provider to automatically log user in in the Symfony2 app if he was logged in symfony1. You'd probably need to inspect symfony1 session and based on that log user in (or not).

    It might be worth looking at the IngewikkeldWrapperBundle which wraps symfony1 project in Symfony2.

    It's also worth watching a talk from Symfony Live 2011: Nice performance using Sf2 cache wrapping Sf1 application:

    • video
    • slides

    Last but not least go through the docs:

    • Security
    • Security Cookbook entry
    0 讨论(0)
提交回复
热议问题