Refactor privileges for ssh commands
Remove logic that checks for root login and prepends command with sudo, because we should not use root login at all and all commands (that require higher permissions should be prefixed with sudo anyways). Add sudo prefix to privileged commands that require it. Signed-off-by: Vladimir Domnich <v.domnich@yadro.com>
This commit is contained in:
parent
f9ba463d2e
commit
b6b1644fd6
5 changed files with 22 additions and 18 deletions
|
@ -38,6 +38,13 @@ class SberCloudConfig:
|
|||
|
||||
|
||||
class SberCloud:
|
||||
"""
|
||||
Manages resources in Sbercloud via API.
|
||||
|
||||
API reference:
|
||||
https://docs.sbercloud.ru/terraform/ug/topics/quickstart.html
|
||||
https://support.hc.sbercloud.ru/en-us/api/ecs/en-us_topic_0020212668.html
|
||||
"""
|
||||
def __init__(self, config: SberCloudConfig) -> None:
|
||||
self.config = config
|
||||
self.ecs_url = None
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue