fix(ci): build and push the image for release tags

Pushing a release tag such as 2.0.0 built no image. build-and-push ran only for the main and develop branches, and it always named the image ci-<branch>-<sha>. The helm chart on main points at service-resource-manager:2.0.0, which therefore doesn't exist.

Changes in .gitlab-ci.yml (build-and-push), matching the federation-manager fix:

  • The image is named after the git tag when the pipeline runs for a tag: ${CI_COMMIT_TAG:-ci-${CI_COMMIT_REF_SLUG}-${CI_COMMIT_SHORT_SHA}}. Branch builds keep their ci-… names.
  • New rule $CI_COMMIT_TAG =~ /^\d+\.\d+\.\d+$/ runs the job for release tags. It sits after the SDK-trigger when: never rule, so TF-SDK consumer pipelines still skip the build.

After merging: tag the merge commit on main as 2.0.0 and push the tag. The pipeline runs the checks, then pushes labs.etsi.org:5050/oop/code/service-resource-manager:2.0.0.

Merge request reports

Loading
Loading