Remove the compiled python bytecode
upgrade-charm could previously fail because of compiled bytecode remaining behind. This change makes the upgrade-charm hook remove any such compiled bytecode files Change-Id: I1cb6521cab1ac0d529907d44f1e9bdb313a798ac Closes-Bug: 1628322
This commit is contained in:
parent
daa475a8c5
commit
a62a1e5adb
|
@ -506,7 +506,7 @@ def client_relation_changed():
|
|||
log('mon cluster not in quorum', level=DEBUG)
|
||||
|
||||
|
||||
@hooks.hook('upgrade-charm')
|
||||
@hooks.hook('upgrade-charm.real')
|
||||
@harden()
|
||||
def upgrade_charm():
|
||||
emit_cephconf()
|
||||
|
|
|
@ -1 +0,0 @@
|
|||
ceph_hooks.py
|
|
@ -0,0 +1,6 @@
|
|||
#!/bin/bash
|
||||
# Wrapper to ensure that old python bytecode isn't hanging around
|
||||
# after we upgrade the charm with newer libraries
|
||||
rm -rf **/*.pyc
|
||||
|
||||
exec ./hooks/upgrade-charm.real
|
|
@ -0,0 +1 @@
|
|||
ceph_hooks.py
|
Loading…
Reference in New Issue