Docker can be used as a flexible development environment for (web) applications. With docker-compose you can add up several services to a complete scenario. Here I would like to present a new setup that contains a lot of things to make a developers life more comfortable, notably:
If you don’t need all these components, you always can disable whatever you’re not going to use. Your application will reside in the html subdirectory, the MySQL/MariaDB db files will be in the mysql directory so nothing is lost when you shut down the services.
If you need something else (PostgreSQL e.g.) please let me know and I will add it. Have fun!
Recently the public availability of Oxid eShop V6.0.0 was announced. And it finally runs with PHP7 and is a major step towards a modern and comfortable web shop.
If you would like to test it locally or develop with it there are many options. Some time ago another one, flexible and versatile, opened: Docker.
In this GitHub repository I assembled an environment with:
- Apache webserver with PHP 7.1 and all extensions needed (and xdebug)
- ELK stack to analyse and show apache log files
If you encounter any problems or bugs please file an issue with GitHub. I’m here and on Twitter to answer any question you might have. Have fun!
Just a little reminder: pip has this very useful option to install a bunch of packages from a single text file mostly called requirements.txt. Anaconda’s command line tool conda doesn’t support this option directly. It does support reading the package names from a file using the –yes and –file option
conda install --yes --file requirements.txt
but that does not automatically install all the dependencies. To do this, we need to iterate over the file and install each package in “single package mode”:
while read requirement; do conda install --yes $requirement; done < requirements.txt
Thanks to Luis Capelo for this snippet which I use to install dependencies in a dockerized instance of Anaconda / Jupyter (more on that in a later post).