Jump to content

How to Work with Rundeck Webhooks?


Recommended Posts

Step 1 – Create a Project and Job with Node Steps

image-80.png

Step 2 – Go to Webhooks under project Menu

image-81-1024x652.png

Step 3 – Create Webhook

image-82-1024x702.png

Step 4 – Add Webhook Handlers Configurations

image-83-1024x743.png image-84-1024x561.png image-86-1024x431.png

Step 5 – Validate the webhook url

image-87-1024x548.png

Step 6 – Get a User API Token

image-88-1024x450.png image-89-1024x665.png image-90-1024x495.png

Step 6 – Generate a CURL command and Run using Gitbash


ENCODED_API_TOKEN=$(echo -n "6BnnOqW7EicQix9lDAn9MceNtSIQ2LBN" | base64)

curl -X POST \
  -H "Authorization: Basic $ENCODED_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "webhook_id": "c6lMILXGYTvR6uaY59ZxhgsWybEfF5uF#hook1",
    "payload": {
      "key1": "value1",
      "key2": "value2"
    }
  }' \
  http://localhost:4440/api/45/webhook/c6lMILXGYTvR6uaY59ZxhgsWybEfF5uF#hook1

image-93-1024x442.png image-91-1024x297.png image-92-1024x529.png

The post How to Work with Rundeck Webhooks? appeared first on DevOpsSchool.com.

View the full article

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...