Do we need to use a CLI tool to implement a fence agent? I rather stay away 
from redfishtool to avoid having it as a dependency (and Python v3) and would 
rather just use the requests library directly.

I created a fence agent for redfish, the agent can take as argument the Systems 
URI or can programmatically find it as it will be different across OEMs:

https://github.com/jose-delarosa/fence-agents/blob/add_redfish_fence_agent/agents/redfish/fence_redfish.py

Looking for initial feedback please.

I usually don’t use tabs to indent lines, is this a requirement?

Jose Delarosa
Linux Engineering
Dell EMC|Infrastructure Solutions Group



-----Original Message-----
From: Developers [mailto:developers-boun...@clusterlabs.org] On Behalf Of 
Andrei Borzenkov
Sent: Thursday, November 15, 2018 10:09 PM
To: developers@clusterlabs.org
Subject: Re: [ClusterLabs Developers] [fence-agents] How to "login" other than 
ssh or telnet?


[EXTERNAL EMAIL]

16.11.2018 0:31, jose.delar...@dell.com<mailto:jose.delar...@dell.com> пишет:
> All,
>
> I am looking at writing a fence agent for Redfish, which uses REST APIs to 
> run "commands" like power off/on/status. There is no ssh login per se, as the 
> APIs are accessed through HTTP methods (GET/POST/PATCH, etc.), so none of 
> these can be used:
>
> https://github.com/ClusterLabs/fence-agents/blob/master/lib/fencing.py
> .py#L968-L976
> <https://github.com/ClusterLabs/fence-agents/blob/master/agents/autode
> tect/fencing.py#L888-L896> I'm new to this project, so looking for
> insightful feedback from the project maintainers or more experience 
> developers here as to the best way to implement a fence "login" for Redfish.

python redfishtool.py -r <rhost> -u <username> -p <password> Systems reset 
ForceRestart

At which point you can take any of existing fencing/stonith agent as template 
and fill in actual command.

https://github.com/DMTF/Redfishtool

>
> Also, is anyone here also looking at developing a Redfish fence agent?
> I see https://github.com/ClusterLabs/fence-agents/issues/230, but not much 
> activity, happy to collaborate.> Thank you all.
>
> Jose Delarosa
>
>
>
>
>
> _______________________________________________
> Developers mailing list
> Developers@clusterlabs.org<mailto:Developers@clusterlabs.org>
> https://lists.clusterlabs.org/mailman/listinfo/developers
>

_______________________________________________
Developers mailing list
Developers@clusterlabs.org<mailto:Developers@clusterlabs.org>
https://lists.clusterlabs.org/mailman/listinfo/developers

_______________________________________________
Developers mailing list
Developers@clusterlabs.org
https://lists.clusterlabs.org/mailman/listinfo/developers

Reply via email to