سؤال

My python buildout-based production environment was moved by admins into a chroot. Now rerunning the buildout fails because compiler(gcc) exits with error while compiling any package which C-extensions (PIL, ZODB).

_imaging.c:3403: error: (near initialization for 'functions[39].ml_meth')
error: Setup script exited with error: command 'gcc' failed with exit status 1

Admins told me gcc is broken in chroot. Of course this is a strange and not viable situation and it will be fixed ASAP.

But I am using buildout/virtualenv since years. Now I am really interested in the options I still do have now for updating my buildout-based python deployment while gcc is broken. I successfully ran the buildout, if I removed any dependencies (in buildout.cfg or packages setup.py) that trigger gcc compilation, but this got me left with uncomplete application startup scripts. Basically all packages are already downloaded/assembled/compiled, but buildout always recompiles a part that has changed somehow (I know about .installed.cfg).

How can I or any python developer not responsible for system administration continue using the strengths of a buildout deployment in such a situation? I am open for any suggestions and want to discuss and learn about their pros and cons.

هل كانت مفيدة؟

المحلول

Build elsewhere, on a build host -- run buildout in a place it can be run (a box of same architecture running GCC) -- then integrate Fabric into your build environment to push the build to your deployment host. I have not done this, but assume you would have to write much of the means to push what you need (e.g. built eggs, develop-eggs, src, parts, bin directories) to your server in your fabfile.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top