Closed excieve closed 4 years ago
Can we fix gateway image itself in meantime?
@buger Yes, but here's the size difference uncompressed:
localhost/tykio/tyk-gateway test-dev 17f6f2f7f65e 5 seconds ago 333 MB
localhost/tykio/tyk-gateway test da53989ac7d0 12 minutes ago 223 MB
@buger I've been looking into this some more and with a bit of dirty hacking I was able to keep the size to just 1MB overhead. I can update existing 2.9+ images with that for now, which fixes the issues. And later remove the hack and use long-term solution from https://github.com/TykTechnologies/tyk/issues/2749 when it's ready.
@marksou Python documentation may need updating based on the outcome of this.
When using a gateway image for v2.9.0 and later and configuring a Python plugin for an API, the gateway isn't able to initialise the co-process dispatcher.
Relevant logs:
This is happening due to a missing
python3-config
executable on this image. The newdlpython
component is using it in order to determine the version and paths to the Python library currently installed on the system.The issue disappears when
python3-dev
package is installed on the container. This however adds significant size overhead to the image (TBD: how much exactly, the packages are about 80MB) as it also installs the development files (symbols, headers, etc.) for the Python lib + dependencies.It might be better to have ability to force some library path for the gateway instead since we know that for each image.