proxmox shutdown notes
parent
e37c5203ba
commit
3541b8c655
|
@ -1,7 +1,7 @@
|
|||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio Version 16
|
||||
VisualStudioVersion = 16.0.30002.166
|
||||
# Visual Studio Version 17
|
||||
VisualStudioVersion = 17.0.32014.148
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NetworkResurrector.Server", "src\server\NetworkResurrector.Server\NetworkResurrector.Server.csproj", "{F6600491-5D79-4548-8745-59D9D337D3DB}"
|
||||
EndProject
|
||||
|
@ -69,9 +69,10 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "notes", "notes", "{6973CB33
|
|||
ProjectSection(SolutionItems) = preProject
|
||||
notes\generic.txt = notes\generic.txt
|
||||
notes\nugets.txt = notes\nugets.txt
|
||||
notes\proxmox-shutdown-notes.txt = notes\proxmox-shutdown-notes.txt
|
||||
EndProjectSection
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NetworkResurrector.Agent.Wrapper", "src\agent\NetworkResurrector.Agent.Wrapper\NetworkResurrector.Agent.Wrapper.csproj", "{3624DFF4-C692-42F8-BDC2-1C2107E6EDC8}"
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "NetworkResurrector.Agent.Wrapper", "src\agent\NetworkResurrector.Agent.Wrapper\NetworkResurrector.Agent.Wrapper.csproj", "{3624DFF4-C692-42F8-BDC2-1C2107E6EDC8}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
|
|
|
@ -0,0 +1,16 @@
|
|||
Hi Guys
|
||||
So long story short I want to shut down my physical server that is running Proxmox VE using the API. I am fairly new to using API but what I have found thus far is this:
|
||||
curl https://yourip:8006/api2/json//nodes/proxmox/stop -k -d 'username=root@pam&password=yourpassword'
|
||||
Above does not seem to work, Anyone able to assist and just provide the correct curl to use
|
||||
|
||||
Thanx
|
||||
|
||||
!!!!!!!
|
||||
Please don't use the root user for that. It is possible to create a new user, name it "shutdown" or something like that, create a new role like "shutdown", add the "shutdown" role to the "shutdown" user. If you then only give that role the rights to use "Sys.PowerMgmt" that user is only allowed to start/shutdown/reboot the node.
|
||||
Never a good idea to use the root user and its password in clear text. The password could end up in logs if the command fails to execute and so on.
|
||||
|
||||
|
||||
|
||||
URLS:
|
||||
https://pve.proxmox.com/wiki/Proxmox_VE_API
|
||||
https://forum.proxmox.com/threads/shutdown-the-server-via-api.98125/
|
Loading…
Reference in New Issue