Skip to content
This repository was archived by the owner on Dec 20, 2023. It is now read-only.

Conversation

rvernica
Copy link

I made the necessary changes to base the Django images out of Alpine 3.3.

Here are a few notes:

  1. The required database libraries for SQLite, MySQL and PostgreSQL are installed first.
  2. pip install requires some -dev packages. I install the -dev packages, run pip and then remove the -dev packages. (I use the apk's virtual feature.) All this is done in a single Docker command. This keeps the images small. This is also done for onbuild images when the requirements.txt are installed.
  3. For the Python 3 image, Alpine 3.3 comes with Python 3.5, so I changed the directory name from 3.4 to 3.5 and updated the Travis configuration file.
  4. I tested the four images (2.7, 2.7-onbuild, 3.5, and 3.5-onbuild) by running a small project with Django Admin interface on SQLite, MySQL (MariaDB) and PostgreSQL back-ends.

@rvernica
Copy link
Author

Build failed due to DNS issues with Alpine Linux. Their domain expired briefly and was re-registered shortly after. The build on my fork was successful.

@rvernica
Copy link
Author

I built the images in my Docker Hub and their reported size is 18-37MB. Compare that to 158-280MB for the non-Alpine images.

@mwaaas
Copy link

mwaaas commented May 20, 2016

would love to see this changes merged

Update 3.5 file to Django 1.9.5
UPdate 3.5 file to Django 1.10.3
@yosifkit
Copy link
Member

yosifkit commented Nov 8, 2016

We have deprecated the django image in favor of just the python image: docker-library/docs#630.

@yosifkit yosifkit closed this Nov 8, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants