Trigger parameterized build with curl and crumb

前端 未结 7 856

I\'ve seen similar posts to this on SO, but not quite exactly what I am trying to do (or at least no full examples of a command to run).

I am trying to remotely trig

7条回答
  •  慢半拍i
    慢半拍i (楼主)
    2020-12-03 01:36

    What worked for me:

    SERVER=http://localhost:8080
    CRUMB=$(curl --user $USER:$APITOKEN \
        $SERVER/crumbIssuer/api/xml?xpath=concat\(//crumbRequestField,%22:%22,//crumb\))
    
    curl --user $USER:$APITOKEN -H "$CRUMB" -d "script=$GROOVYSCRIPT" $SERVER/script
    

提交回复
热议问题