vnc-biz / zcs-zmpkg

Package management core for the Zimbra Collaboration Suite
6 stars 3 forks source link

zmpkg-dpkg: Don't run zmpkg-autodeploy if fakeroot fails #6

Closed adriangibanelbtactic closed 11 years ago

adriangibanelbtactic commented 11 years ago

After examining (in an installed system) the contents of:

bin/zmpkg-dpkg

I think that the last zmpkg-autodeploy command shouldn't be run if the previous fakeroot commands fails. So it's exit value should be evaluated.

I'm referring to these two lines:

fakeroot dpkg --force-architecture --force-not-root $OPT_FORCE_ARCH --root=$ZIMBRA_ROOT --log=$ZIMBRA_ROOT/var/log/dpkg.log $FOREIGN_ARCH $COMMAND

zmpkg-autodeploy

This is vaguely related to this other vnc-zcs-crm issue: https://github.com/vnc-biz/vnc-zcs-crm/issues/2 .

metux commented 11 years ago

Thanks for the report. Actually, a failure should also return a proper exit code.

At this point, I'd also like to mention that we currently assume that the zimbra instance is up and running, otherwise strange things might happen (additional zmpkg-autodeploy calls once zimbra is up again, hopefully should fix this).

By the way: always feel free to submit patches ;-)

metux commented 11 years ago

Resolved in latest 1.3 line.