Expand my Community achievements bar.

Submissions are now open for the 2026 Adobe Experience Maker Awards.
SOLVED

Deployment steps for AEM Content Fragment Extension Project

Avatar

Level 9

Hello Team,

 

I have an AEM Content fragment extension project. Till now, manually I am deploying the project to differenet Adobe IO workspace. Now, I wanted to use jenkin deployment.


Previously team has created NodeJS micro project, that is deployed to Adobe IO workspace using jenkin deployment. Looks like, I cannot use those steps in my CF Extension project.

 

For reference purpose, I have referred the Github project URL: https://github.com/adobe/aem-uix-examples/tree/main

But, not getting much insight here. Can someone help me with this?

Note: I dont have any environment specific configuration for each workspace. Under the hood, need to run the command aio app deploy

Note: I have referred the steps here: https://github.com/adobe/aem-uix-examples/blob/main/cf-editor-generate-variations/deploy But, not getting the full pitcure about jenkin deployment.

 

cc @arunpatidar @daniel-strmecki   @sarav_prakash  @AmitVishwakarma @partyush 

 

Thanks in advance.

1 Accepted Solution

Avatar

Correct answer by
Level 4

Hi @Mahesh_Gunaje,

 

You want to automate the deployment of your AEM Content Fragment Extension (AIO app) using Jenkins, instead of running aio app deploy manually.

Here’s how to do it step-by-step:

  1. Install Prerequisites in Jenkins

    • Make sure Jenkins has:

      • Node.js

      • npm

      • Adobe I/O CLI (@adobe/aio-cli)

  2. Add Adobe I/O Credentials to Jenkins

    • Store your Adobe I/O auth credentials (like .env file values or runtime auth token) in Jenkins securely using the Credentials feature.

  3. Create a Jenkins Pipeline (Jenkinsfile)
    Use this basic structure:

    groovy
     
    pipeline { agent any environment { AIO_RUNTIME_AUTH = credentials('your-jenkins-secret-id') // Store auth token securely } stages { stage('Install Tools') { steps { sh 'npm install -g @adobe/aio-cli' } } stage('Install Dependencies') { steps { sh 'npm install' } } stage('Deploy to Adobe I/O') { steps { sh 'aio app deploy' } } } }
  4. No Workspace-Specific Configuration Needed

    • Since all workspaces are using the same config, you don't need to manage different .env files or separate builds.

  5. GitHub Project Link Helps with Structure, Not Jenkins

    • The GitHub example gives file setup and deploy command (aio app deploy), but doesn’t cover Jenkins setup — so you're on the right track building your own pipeline.


This setup will let Jenkins run aio app deploy just like you do manually — but now automated.

 

Thanks & Regards,

Vishal

View solution in original post

2 Replies

Avatar

Correct answer by
Level 4

Hi @Mahesh_Gunaje,

 

You want to automate the deployment of your AEM Content Fragment Extension (AIO app) using Jenkins, instead of running aio app deploy manually.

Here’s how to do it step-by-step:

  1. Install Prerequisites in Jenkins

    • Make sure Jenkins has:

      • Node.js

      • npm

      • Adobe I/O CLI (@adobe/aio-cli)

  2. Add Adobe I/O Credentials to Jenkins

    • Store your Adobe I/O auth credentials (like .env file values or runtime auth token) in Jenkins securely using the Credentials feature.

  3. Create a Jenkins Pipeline (Jenkinsfile)
    Use this basic structure:

    groovy
     
    pipeline { agent any environment { AIO_RUNTIME_AUTH = credentials('your-jenkins-secret-id') // Store auth token securely } stages { stage('Install Tools') { steps { sh 'npm install -g @adobe/aio-cli' } } stage('Install Dependencies') { steps { sh 'npm install' } } stage('Deploy to Adobe I/O') { steps { sh 'aio app deploy' } } } }
  4. No Workspace-Specific Configuration Needed

    • Since all workspaces are using the same config, you don't need to manage different .env files or separate builds.

  5. GitHub Project Link Helps with Structure, Not Jenkins

    • The GitHub example gives file setup and deploy command (aio app deploy), but doesn’t cover Jenkins setup — so you're on the right track building your own pipeline.


This setup will let Jenkins run aio app deploy just like you do manually — but now automated.

 

Thanks & Regards,

Vishal

Avatar

Community Advisor and Adobe Champion

Hi @Mahesh_Gunaje,

I haven't used Jenkins for a long time now, but it should not be a problem; all you need is Node and AIO command line tools installed.

 

Here is an example GitHub Action I am using to deploy an AIO plugin extension:

name: AIO App CI

on:
  workflow_dispatch:
  
jobs:
  deploy:
    name: Deploy to Stage
    runs-on: ${{ matrix.os }}
    strategy:
      max-parallel: 1
      matrix:
        node-version: ['20']
        os: [ubuntu-latest]
    steps:
      - name: Checkout
        uses: actions/checkout@v4
      - name: Use Node.js ${{ matrix.node-version }}
        uses: actions/setup-node@v4
        with:
          node-version: ${{ matrix.node-version }}
      - name: npm install
        run: npm i
      - name: Setup CLI
        uses: adobe/aio-cli-setup-action@1.3.0
        with:
          os: ${{ matrix.os }}
          version: 10.x.x
      - name: Auth
        uses: adobe/aio-apps-action@3.3.0
        with:
          os: ${{ matrix.os }}
          command: oauth_sts
          CLIENTID: ${{ secrets.CLIENTID_STAGE }}
          CLIENTSECRET: ${{ secrets.CLIENTSECRET_STAGE }}
          TECHNICALACCOUNTID: ${{ secrets.TECHNICALACCID_STAGE }}
          TECHNICALACCOUNTEMAIL: ${{ secrets.TECHNICALACCEMAIL_STAGE }}
          IMSORGID: ${{ secrets.IMSORGID_STAGE }}
          SCOPES: ${{ secrets.SCOPES_STAGE }}
      - name: Build
        env:
          AIO_RUNTIME_NAMESPACE: ${{ secrets.AIO_RUNTIME_NAMESPACE_STAGE }}
        uses: adobe/aio-apps-action@3.3.0
        with:
          os: ${{ matrix.os }}
          command: build
      - name: Deploy
        env:
          AIO_RUNTIME_NAMESPACE: ${{ secrets.AIO_RUNTIME_NAMESPACE_STAGE }}
          AIO_RUNTIME_AUTH: ${{ secrets.AIO_RUNTIME_AUTH_STAGE }}
          AIO_PROJECT_ID: ${{ secrets.AIO_PROJECT_ID_STAGE }}
          AIO_PROJECT_NAME: ${{ secrets.AIO_PROJECT_NAME_STAGE }}
          AIO_PROJECT_ORG_ID: ${{ secrets.AIO_PROJECT_ORG_ID_STAGE }}
          AIO_PROJECT_WORKSPACE_ID: ${{ secrets.AIO_PROJECT_WORKSPACE_ID_STAGE }}
          AIO_PROJECT_WORKSPACE_NAME: ${{ secrets.AIO_PROJECT_WORKSPACE_NAME_STAGE }}
          AIO_PROJECT_WORKSPACE_DETAILS_SERVICES: ${{ secrets.AIO_PROJECT_WORKSPACE_DETAILS_SERVICES_STAGE }}
        uses: adobe/aio-apps-action@3.3.0
        with:
          os: ${{ matrix.os }}
          command: deploy
          noPublish: true

 

Good luck,

Daniel