cds
cds copied to clipboard
CI integration with CDS orchestration
Hi Brothers!
I have fallen in love with CDS, it's a great tool! In words of my friend: CDS does whatever you say. Hahaha.
I'm trying to replace a CD(Paid) tool with CDS; now we have many projects running in CI, and I need to integrate it with CDS to orchestrate the continuous delivery and deployment.
But I'm having some difficulties..
I can't consume the API in the CI side without running an action to renew the JWT, because it expires in 1 hour. Is there a way to consume the API by giving an user and password? Or maybe there is a way to configure the session-token so it doesn't expire?
I'm asking this because the CI processes are completely separated, and I need to know the deployment version(Job ID) that was started by using the webhook, so the user can Know exactly the job that was started by each project.
The only information we can use to pass the link of the version of the release is the timestamp, returned after POST. Is there a way to configure the CDS to return the job version through the webhook's(JSON) access?
Hi,
Sorry about the very late answer to your question.
It's not possible to consume the API by giving an user and password. It's not possible to have a session token without expiration.
There are two kinds of tokens: the tokens (= signin token) and the session token. Session token are generated with a signin token. You will find some documentation about that here: https://ovh.github.io/cds/development/sdk/.
But, it you use cdsctl, the auth magic (generate the session token with a token) is done by the sdk.
CDS_TOKEN={{.cds.proj.your-token}} cdsctl worklfow ...