Commit 7d0f70aa authored by Jérome Perrin's avatar Jérome Perrin

prune: tolerate all forms of broken slapos.cfg in instance

When we recurse in instance to find nested slapos that might be using
parts from ourselves, we check all files named slapos.cfg but we may
encounter some slapos.cfg that are not actual slapos config files, for
example in testnodes we have a working copy of slapos repository which
contains a stack/slapos.cfg which is completly different.

This was breaking prune with an error like this:

    2020-04-29 20:07:28 slapos[2097] DEBUG Reading config at /srv/slapgrid/slappart9/srv/testnode/czp/slapos-repository/stack/slapos.cfg
    2020-04-29 20:07:28 slapos[2097] ERROR No section: 'slapos'

See merge request !211
parents 2f726fab 7b2da457
Pipeline #9317 failed with stage
in 0 seconds