I am trying build bitbucket pipelines with SFDX and got stuck in the first stage.
I have followed this blog and created serverykey and certificate files.
And created Connected App and added certificate:
And here is my yml script:
# CI process for SFDX image: illbilly/sfdx #image with sfdx installed pipelines: default: #this will run for all branches unless specificed otherwise - step: name: Auth. with DevHub script: - sfdx force:auth:jwt:grant -i $CLIENT_ID -f jwt/server.key -u $DEVHUB_USERNAME --setdefaultdevhubusername --setalias DevHub - sfdx force:org:list - step: name: Create Scratch Org. script: - sfdx force:org:list - sfdx force:org:create -f environments/scratchorg1-scratch-def.json -v DevHub -a bitbucket_build_$BITBUCKET_BUILD_NUMBER
When I run the build: I am getting this below error, inspite of having the profile access to the connected app. what am I missing:
An error occurred authorizing this org. name: invalid_grant message: user hasn't approved this consumer