[Jenkins][Kubernetes] Recovery pod annotations inside node

11 views
Skip to first unread message

Paulo Augusto de Almeida Ferreira

unread,
Feb 24, 2022, 8:00:09 PM2/24/22
to Jenkins Users
Hello.

Please, anyone who can help me.

Is there any way to retrieve the annotations of a pod from within the node?

The premise is that pod is not being created in the pipeline.

```groovy
def podCloud = "JenkinsCloudKubernetesPodTemplateName"

node(podCloud) {
   // get pod annotations
    stage("Checkout") {
    }
    // more stages
}
```
Reply all
Reply to author
Forward
0 new messages