This example has a rundeck running in a docker container with a volume path set to /home/rundeck/server/data
Must be in rsa format which begins like
—–BEGIN RSA PRIVATE KEY—– xxxxxxx
You likely have openssh format
—–BEGIN OPENSSH PRIVATE KEY—–
so this needs to be converted to rsa with
ssh-keygen -p -m PEM -f .ssh/id_rsa
Once its converted add it to Rundeck Cog wheel in upper right corner > Key Storage > Add or Upload Key
If you already added a project select it, go to Project settings > Edit Configuration > Default node executor, select SSH then in SSH Key Storage Path browse to the added key above. Set SSH Authentication to “privateKey”.
In “Default File Copier” tab select “SCP” with same settings as above.
When adding the new project the steps are the same.
Go to Project settings > Edit Configuration > Edit nodes. Go to “Sources” and “Add a new node source” then choose “File” and set the “Format” to resourceyml and “File Path” to the name of the yaml file e.g. /home/rundeck/server/data/nodes.yml. Also tick the “Generate” and “Writeable” option.
Now go to “Edit” tab and click “Modify” and paste the configuration for the node, example:
node1: nodename: node1 hostname: 10.10.10.5 description: '' username: username osFamily: Linux
Select “Commands” from the sidebar, in the dropdown click “Show all nodes” and select the node you added. Now run some simple command like ls
to see if it works.
When defining a job, in “Nodes” tab select “Dispatch to Nodes” and select your node(s) in “Node Filter”.