Skip to content

RegestaItalia/abapcicd

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ABAP CI/CD

This repository contains an example of how a CI/CD approach can be achieved with an ABAP S4/ECC project.

Tools used

  • abapGit: Serializing objects and having a git approach for ABAP developments
  • abapLint: Syntax check based on a defined rule set
  • ADASH: Run ABAP unit tests
  • TRM: Publish and distribute software ready for production environments

SAP System

The source and target SAP systems are instances of ABAP Platform 1909 provided by Nuve Platform.

The source instance is where all the code changes are performed and committed to this repository; it's also where the TRM release will be generated.

When ready to distribute, a new ABAP Platform 1909 instance is generated but this time from a blank backup (a snapshot where this example package was never installed): this will simulate the first install of a TRM package.

Branching strategy

The branching strategy of this repository is trunk-based:

the main branch is protected, only allowing merge from pull requests.

Tests

Merges to main are prevented (by pull request rules) if something wrong with the tests is detected.

abapLint

abapLint will check for syntax errors on each commit.

ABAP Unit tests

Each commit to any branch other than main will trigger a workflow that checks all of the unit tests in the package (using ADASH).

Release

Releases are generated with Github Releases.

TRM Release

When a Github Release is created, the TRM publish workflow will trigger.

The release can then be found on the registry here https://trmregistry.com/#/package/abapcicd.

Distribute

As soon as the TRM release is completed, the TRM install workflow is triggered.

Workflow

 

Steps:

  • All code is written in a central development system
  • Commits are done in a new branch
    • Trigger abapLint syntax check
    • Trigger ABAP Unit tests (ADASH executed on central development system)
  • When ready, pull request from branch -> main
    • If all checks ok, merge
  • When ready, manually create a new Github release
    • Trigger TRM Publish (from central development system)
  • TRM Release published
    • Trigger TRM Install (in this case, run and install on a new instance of ABAP Platform 1909 on Nuve Platform)