Note: work in progress

Requirement

REQ-1043 - Getting issue details... STATUS

Epic

EpicDescriptionJIRA TicketPriority
ASD Package Distribution Microservice shall support Application Package distribution

ASD Package Distribution Microservice shall support Application Package distribution

  • Support ASD Package storage and CRUDQ APIs
  • Support Helm Chart storage and CRUDQ APIs
  • Support Image storage and CRUDQ APIs

1




User Stories

User StoryDescriptionJIRA TicketPriority
CNF Catalog Manager shall manage ASD package, Helm Artifacts and Image Artifacts

CNF Catalog Manager shall manage ASD package, Helm Artifacts and Image Artifacts

Pre Condition:

  • SDC supports ASD Onboarding Package and notification

Post Condition:

  • CNF Catalog Manager is ready and running

1

Task: shall Extend ETSI Catalog Manager (Modeling Catalog) component to handle:

  • Receive ASD package notification thru DMaaP and query ASD packages from SDC
  • triggering ASD package repository process
  • triggering Helm Artifact repository process
  • triggering Image Artifact repository process

1.1
ASD Package Repository shall manage ASD Package distribution

ASD Package Repository manages ASD Package distribution

Pre Condition:

  • SDC supports ASD onboarding package
  • CNF Catalog Manager is ready and running

Post Condition:

  • ASD Package is stored at the ASD Package Repository

2

Task: Support for ASD Package Repository Management APIs

  • Shall provide CRUDQ REST APIs for ASD packages

2.1

Task:

  • ASD Package Repository shall receive ASD Package handling requests from CNF Catalog Manager and store the Package to its database

2.2

Task:

  • Extended ETSI Catalog Manager shall trigger Helm Artifacts

2.3

Task: Create Image Artifact Repository Management

  • Create Image Artifact Repository Database
  • Create Image Artifact Repository CRUDQ APIs

Note: it is allowed to use an open-source Artifact Repository


2.4
Helm Artifact Repository manages Helm Chart distribution

Helm Artifact Repository manages Helm Artifacts distribution

Pre Condition:

  • SDC supports ASD Onboarding Package and notification
  • CNF Catalog Manager is ready and running

Post Condition:

  • Helm Artifact Repository is ready and running
  • Helm Artifacts are stored at the Helm Artifact Repository.

3

Task: Create Helm Artifact Repository Management

  • Create/deploy Helm Artifact Repository
  • Create/deploy Helm Artifact Repository CRUDQ APIs

Note: it is allowed to use an open-source Artifact Repository


3.1

Task:

  • Helm Artifact Repository shall receive Helm Artifact handling requests from CNF Catalog Manager
    • Add charts:
      • POST /api/charts - upload a new chart version
    • List charts: 
      • GET /api/charts - list all charts
      • GET /api/charts/<name> - list all versions of a chart
      • GET /api/charts/<name>/<version> - describe a chart version
    • Remove charts
      • DELETE /api/charts/<name>/<version> - delete a chart version (and corresponding provenance file)
  • Shall get Helm Chart reference information from the ASD deploymentItems
  • If the ASD Package embeds Helm Chart files, it shall store the files to its repository

3.2
Image Artifact Repository manages Image distribution

Image Artifact Repository manages Image Artifacts distribution

Pre Condition:

  • SDC supports ASD Onboarding Package and notification
  • CNF Catalog Manager is ready and running

Post Condition:

  • Image Artifact Repository is ready and running
  • Image Artifacts are stored at the Image Artifact Repository.
  • Image Artifact Repository should be accessible by external K8S cluster(s)

Post Condition:

  • Image Artifacts are stored at the Image Artifact Repository.

4

Task: Create Image Artifact Repository Management

  • Create Image Artifact Repository
  • Create Image Artifact Repository CRUDQ APIs

Note: it is allowed to use an open-source Artifact Repository


4.1

Task:

  • Image Artifact Repository shall receive Image Artifact handling requests from CNF Catalog Manager
  • Shall get Image reference information from the ASD Package
  • If the ASD Package has image references with K8S Object Storage, it shall retrieve the associated images from K8S Object Storage and store the images to its repository

4.2

Distribution Sequence

ASD Catalog Manager


ASD Artifact Distribution

ASD Artifact Distribution


Note:

  • The certificate chain must be added so that the worker nodes in the additional (operator) cluster(s) can pull Docker images from the Image Repository/Registry Service.
    • The Worker Nodes in the operator K8S cluster pull Images from the Image Artifact Repository from the ONAP K8S cluster.
    • The access can be done thru the Ingress in the ONAP K8S cluster.

Docker Commands


docker login <REGISTRY_HOST>:<REGISTRY_PORT>

docker tag <IMAGE_ID> <REGISTRY_HOST>:<REGISTRY_PORT>/<APPNAME>:<APPVERSION>

docker push <REGISTRY_HOST>:<REGISTRY_PORT>/<APPNAME>:<APPVERSION>




Image Registry 



The image registry path is parameterized to support deployments using a private registry.

<TBD>


Image Pull Secret

A Docker registry secret is needed for each namespace to access the container registry. The secret is included in the POD definition.



ASD Package Distribution Service

The distribution service distributes ASD application packages to the registries deployed in the ONAP K8S cluster. The process of distribution pushes ASD application-specific Helm charts and Docker images to their respective registries and pushes the ASD to the Catalog Manager Database (ASD repository).

The followings are the steps in the process of onboarding a ASD App CSAR file:

  • receive an uploaded ASD-based CNF / application as a CSAR file
  • Unpack the uploaded CSAR file
  • Retag Docker images with the target Docker registry details
  • Push the retagged images to the target Docker registry
  • Upload the Helm chart of the ASD-based CNF / application to the Helm chart registry that the Distribution service specifies
  • Upload the ASD to the Catalog Manager Database (ASD Repository)





ASD Package/Artifact APIs

  • The Catalog Manager provides the following APIs for its clients:
    • List onboarded ASD App Packages
    • Query a specified ASD App Package
    • Retrieve ASD from the Onboarded ASD App Package
    • Delete an ASD App Package. (for a given asPkgId)
      • When an ASD App Package is deleted, 1) the Helm chart or charts are removed from the Helm chart Repository, 2) the ASD App package entry is removed from the ASD App Repository and 3) the Docker image or images are removed from the Image repository if no other onboarded package references them.


  • The Helm Repository provides APIs for Helm chart query for a given Helm chart id, which is from the ASD DeploymentItems.
  • The Image Repository (e.g., Docker repo) provides APIs for Image query for a given Image name (and Tag)
  • Fetch Artifact from CSAR package








  • No labels