[Pkg-zope-developers] dzhandle should not handle non-enabled instances
martin f krafft
madduck@debian.org
Tue, 29 Mar 2005 12:52:50 +0200
--tKW2IUtsqtDRztdT
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable
It really only makes sense the make dzhandle act on instances which
are dzhandle-enabled (check for etc/debian_policy). Any other
instances need to be migrated, which should be an explicit action.
Therefore, locate_instances should only return dz-enabled instances.
The following patch checks for the debian policy file.
--- /usr/sbin/dzhandle Mon Mar 28 20:15:47 2005
+++ /usr/local/sbin/dzhandle Tue Mar 29 12:50:55 2005
@@ -1792,7 +1800,8 @@
if not versions or z['version'] in versions]
for version, instance_dir in pkgs:
for home in glob.glob(os.path.join(instance_dir, '*')):
- if os.path.isdir(os.path.join(home, 'var')):
+ if os.path.isdir(os.path.join(home, 'var')) and \
+ os.path.isfile(os.path.join(home, 'etc', 'debian_policy')):
instance =3D ZopeInstance(home, version)
instances.append(instance)
return instances
--=20
.''`. martin f. krafft <madduck@debian.org>
: :' : proud Debian developer, admin, user, and author
`. `'`
`- Debian - when you have better things to do than fixing a system
=20
Invalid/expired PGP subkeys? Use subkeys.pgp.net as keyserver!
=20
"if beethoven's seventh symphony
is not by some means abridged,
it will soon fall into disuse."
-- philip hale, boston music critic, 1837
--tKW2IUtsqtDRztdT
Content-Type: application/pgp-signature; name="signature.asc"
Content-Description: Digital signature
Content-Disposition: inline
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.0 (GNU/Linux)
iD8DBQFCSTOCIgvIgzMMSnURAtGbAKCNHXJ/zm+m6qQgaoP8HeCba5HWdwCfRxQ2
ZmOklw7K71oQkA4RjZmpKZU=
=20R6
-----END PGP SIGNATURE-----
--tKW2IUtsqtDRztdT--