Custom CI/CD Pipeline for Asset Compute Worker Using Bitbucket | Community
Skip to main content
Level 3
February 27, 2025
Question

Custom CI/CD Pipeline for Asset Compute Worker Using Bitbucket

  • February 27, 2025
  • 2 replies
  • 3361 views

Hi,  

We have written code for asset manipulation using Asset Compute Worker in App Builder and want to deploy the code to a higher environment using Bitbucket. Can you please guide me on how to achieve this using Bitbucket?

 

Request you to please help me with the deployment process.

Thanks,

@EstebanBustamante 
@arunpatidar 
@Harwinder-singh 
@sravs 
@abhishekanand_
@tmj 

2 replies

sarav_prakash
Community Advisor
Community Advisor
March 8, 2025

Hi @vishal33 ,

Adobe provided excellent documentation to setup CI-CD pipeline using github actions

https://developer.adobe.com/app-builder/docs/resources/ci-cd/requirements/

You can refer to my this reply. But this works only for Github.

 

We cant directly trigger Github actions from Bitbucket. Should try some workarounds

  1. Setup github repo. Trigger sync from Bitbucket into github. And then run the adobe provided github actions to deploy to AppBuilder.
  2. Install Bitbucket Post webhook plugin. The plugin will trigger github actions. But this once again requires sync of code from Bitbucket into Github
  3. Reinvent the wheel. Refer to adobe deploy script. And rewrite the yaml to work from Bitbucket pipelines. afaik no direct adobe documentation for Bitbucket pipeline. But steps involved would as below. 
    1. Checkout code
    2. Install node, npm i
    3. install adobe/aio-cli-setup-action,  adobe/aio-apps-action
    4. setup secrets as env variables
    5. Finally run `aio app deploy`. If required add --force-build, verbose, --no-action, whatever required flags.  

Sounds you ll need to reinvent with option3 to rewrite the github actions yaml into bitbucket pipeline. I have not done this. But I have written as Jenkins job to perform above steps in above order to checkout code from TFS and deploy onto AppBuilder. All the best!

Vishal33Author
Level 3
April 3, 2025

Hi @sarav_prakash

we have followed the steps given in the video( App Builder Live - CI/CD) regarding Jenkins setup.
Below is our Bash File

#!/bin/bash source ~/.bashrc echo $ENV_FILE_CONTENTS > .env cp .aio-stage .aio npm i export AIO_runtime_namespace=13xxx-xxxxassetcompute-stage aio app deploy

Error
/tmp/jenkins2065956486425470096.sh: line 9: aio: command not found

and when we change the bash file with

#!/bin/bash source ~/.bashrc echo $ENV_FILE_CONTENTS > .env cp .aio-stage .aio npm install -g @adobe/aio-cli npm i export AIO_runtime_namespace=13xxx-xxxxassetcompute-stage aio app deploy


Error
The operation was rejected by your operating system.
npm error It is likely you do not have the permissions to access this file as the current user

Also as you mentioned 
->But I have written as Jenkins job to perform above steps in above order to checkout code from TFS and deploy onto AppBuilder

can you please send us the detail steps you followed to write Jenkins job and also the sample bash file which you used. It will be really helpful for us.

Request you to please help me with the deployment process.

Thanks & Regards,

Vishal Jain

Vishal33Author
Level 3
April 7, 2025

Hi @sarav_prakash 

Have you had the chance to go through the previous post? Please take a moment to go through it, and feel free to reach out to us if you have any questions.

Looking forward to hearing from you!"

Thanks & Regards,
Vishal Jain

tmj
Adobe Employee
Adobe Employee
March 10, 2025

@vishal33 this video is a few years old but I think it should still prove to be a useful reference: https://www.youtube.com/watch?v=lbB2jl2rQZM&ab_channel=AdobeDevelopers

 

Vishal33Author
Level 3
March 12, 2025

Thank you for your reply @tmj 

Actually, we are exploring both options bitbucket pipelines and Jenkins job
I have one question related to Jenkins job

If the .env file contains (

AIO_RUNTIME_NAMESPACE,AIO_RUNTIME_AUTH) then what is the need of separately configuring the file for auth and then what is the actual content of that AIO_RUNTIME_AUTH file?


Also, why we need to set the AIO_RUNTIME_NAMESPACE

again, in the shell command section if it is already present in the .env file?

please find the attached screenshot

 

Request you to please help me with the deployment process.

Thanks & Regards,

Vishal Jain

tmj
Adobe Employee
Adobe Employee
March 12, 2025

Hi @vishal33 

 

>If the .env file contains (AIO_RUNTIME_NAMESPACE,AIO_RUNTIME_AUTH) then what is the need of separately configuring the file for auth and then what is the actual content of that AIO_RUNTIME_AUTH file?

> Also, why we need to set the AIO_RUNTIME_NAMESPACE

again, in the shell command section if it is already present in the .env file?


It's been a few years since the video was recorded so I cannot tell you off the top of my head. But did you try with/without it? Did you face any problems? Can you show us your code and tell us what problems you are facing? 

 

App Builder provides an out-of-the-box CI/CD pipeline with Github actions. If you want to implement it in Bitbucket or Jenkins that can be achieved but you have to write the code yourself. See docs for more help - https://developer.adobe.com/app-builder/docs/guides/deployment/ci_cd_for_firefly_apps/ 

 

Thanks
Manik