[Freeipa-devel] [PATCH 0153] ipatests: Fix incorrect order of operations when restoring

Petr Viktorin pviktori at redhat.com
Tue Feb 25 09:30:25 UTC 2014


On 02/25/2014 08:56 AM, Tomas Babej wrote:
> Given the fact that the patch has been ACKed, can we push the current
> iteration?
>
> On 02/20/2014 01:07 PM, Petr Viktorin wrote:
>> On 02/20/2014 12:58 PM, Jan Pazdziora wrote:
>>> On Thu, Feb 20, 2014 at 12:20:12PM +0100, Petr Viktorin wrote:
>>>> On 02/19/2014 04:54 PM, Jan Pazdziora wrote:
>>>>>
>>>>> However: since this is about restoring a backup, can't the backup
>>>>> contain the extended attributes, so that the SELinux context gets
>>>>> restored to the original state (which could be different from what
>>>>> the restorecon will give you)?
>>>>
>>>> Well, I guess you're the Beaker authority here. Is that necessary
>>>
>>> This is not about Beaker, is it?
>>
>> It is; all other use cases I know of use disposable or at least
>> single-purpose VMs.
>>
>>> But since you mention it, beakerlib does cp -a upon backup and restore
>>>
>>>      https://git.fedorahosted.org/cgit/beakerlib.git/tree/src/infrastructure.sh#n484
>>>
>>>      https://git.fedorahosted.org/cgit/beakerlib.git/tree/src/infrastructure.sh#n593
>>>
>>>
>>> for files to preserve the SELinux context, plus chcon --reference
>>> upon backup for directories:
>>>
>>>      https://git.fedorahosted.org/cgit/beakerlib.git/tree/src/infrastructure.sh#n495
>>>
>>>
>>>> when restoring?
>>>> The tests expect a "sane" state, and they return to that; using a
>>>> somehow customized machine to test on is a bad idea anyway.
>>>
>>> You might specifically want to run your test on non-sane state because
>>> you want to test that the non-sane state will for example produce
>>> correct error, SELinux-related or other.
>>
>> In that case you're on your own, you should wrap the test in custom
>> setup & teardown code.
>>
>>
>> There's no way we can perfectly restore a system after IPA has been
>> installed on it, much less if it was an unstable/testing version of
>> IPA, so returning to a sane state seems good for me.
>>
>

Pushed to:
master: bc0872cc0b33379a2a4109c9b353ac81d10cec83
ipa-3-3: edba30d2c6c9b01cf023abb6c5bcc378a3d56272

-- 
Petr³




More information about the Freeipa-devel mailing list