Open MikeTheCanuck opened 6 years ago
1, So the use of the stretch variant comes down to the question of the use of the wait-for-it script to test whether the container is able to make a connection with the postgres client prior to completing the rest of the bootup cycle. The stretch variant seemed to be necessary as per @znmeb for the use of of the required postgres client necessary to connect to the current database.
The root of this usage is from this recommendation from Docker Compose: https://docs.docker.com/compose/startup-order/
It does improve on the local dev container experience as usually the api container will attempt to startup prior to the database being booted. We may have adequate healthchecks on the database and api container through aws that this may not be necessary?
Lines 5-13 are packages related to 2 concerns:
postgresql-client-9.6 \
and i assume qqy? binutils \
gdal-bin \
libproj-dev \
see ref in the comments of the docker file: https://docs.djangoproject.com/en/2.0/ref/contrib/gis/install/geolibs/
Line 22 Nope, hence why is separate req file, can be left out from projects not needing it, could be possibly made more automated. See: https://github.com/hackoregon/backend-examplar-2018/issues/22
Thanks Brian - this is great insight, and thanks as always to the docs links!
Addressing some of item (2) with #71
There are three separate enhancements in the production DOCKERFILE that I don't believe are necessary for every project: