Python bundles get purged after reloading endpoints

Hi @jeffrngu, thanks for pointing this out, I’m currently investigating this issue and got other similar bug reports.

Will keep you updated.

@jeffrngu what value do you have set in middleware_path in your tyk.conf?

Actually, a beter question would be, if you run the daemon manually, so

cd /opt/tyk-gateway
./tyk-python --conf=/opt/tyk-gateway/tyk.conf

And then do a reload, does it purge the file?

Hi Martin,
Below is the setting in /opt/tyk-gateway/tyk.conf. The problem is very consistent even after several restarts.
“middleware_path”: “/opt/tyk-gateway/middleware”

BTW, I noticed the tyk-gateway service is launched through the script /opt/tyk-gateway/entrypoint.sh. It looks like the script is reset every time I restart the docker container for Tyk Gateway. How do I persist the changes in this script?

Thanks,
-Jeffrey

You would need to mount the script as a volume from outside the container tonoverwrite the one in the container. Containers are designed to be indempotent.