New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow PHP 7.x and 5.6 side by side #1765
Comments
可以设置2个容器,,不同的别名和端口号,nginx配置中取不同的别名连接啊 |
Most of us are running different environments per project, you can clone Laradock into each of your projects' directory. Modify docker-compose configurations to your needs. They will be completely independent. and But note, rebuilding containers wouldn't take long because the first time you build one, it gets cached. |
Yes, I know that and I agree. But I don't want to go that way because that would mean I would have to keep multiple systems up to date and that would not by very DRY. I wanted to switch to Docker / Laradock to have something simple to use, more lightweight than classic Laravel Homestead. For now I've made myself a bash script to switch between 7.2 / 5.6 and other versions in .env file
and rebuild the containers, bring them up. It's certainly more user friendly and makes usage of the system a lot easier or better to say enjoyable to use. Anyway I still think that the process of switching PHP versions in PHP and Workspace containers should be easier for newcomers. PHP version in the workspace container matters because of composer and executables installed in the project using composer. Yes we can use composers |
sure but typically, we have every project, with it's own dependencies, 1 PHP version, specific PHP extensions. That's why we clone Laradock into each folder and make customizations (if needed). |
At present, many PHP integrated development environments are multi-project sharing. The demand of most users is actually multi-version PHP and multi-version MySQL coexist. Most of the other modules can be shared. The COMPOSE_PROJECT_NAME mechanism requires laradock to copy multiple copies. This will result in maintenance costs for multiple cloned version environments, which is not an optimal solution. Is it possible to add a grouping mechanism to the outermost layer to store multiple items that can be configured in a shared configuration? |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Hi again 👋 we would like to inform you that this issue has been automatically |
Hello, I am using multi project setup and I was wondering how could I have 2 versions of the PHP in one installation of Laradock.
The problem is that some of our legacy projects still runs on PHP 5.6 but newer (and upgraded) stuff runs on PHP 7.x. Also if I want to start a new Laravel project, I want to use latest stable framework release which requires me to use PHP 7+
Having to change environment variable to switch PHP version and rebuild the container is a pain. I was wondering if it would be possible to have 2 containers and just run which ever version I need at the moment.
PS: I was looking for similar issues, but did not find any. If there is one, sorry about the duplicate.
PS2: I am new to Docker. I was happy with my Vagrant / Homestead setup but wanted to try something more lightweight. If this is a stupid question, sorry about that.
PS3: English is not my native language, sorry if it's hard to follow what I mean.
The text was updated successfully, but these errors were encountered: