Merge "Refactored the docker compose This enables the one click deployment of all or selected components in nonrtric"
diff --git a/.gitignore b/.gitignore
index 26c6731..02f4f98 100644
--- a/.gitignore
+++ b/.gitignore
@@ -3,6 +3,8 @@
.tox
docs/_build/
.DS_STORE
+.swagger*
+docs/offeredapis/swagger/README.md
# Eclipse
.checkstyle
diff --git a/docs/api-docs.rst b/docs/api-docs.rst
index ed0cc79..9e438f6 100644
--- a/docs/api-docs.rst
+++ b/docs/api-docs.rst
@@ -18,15 +18,15 @@
This is the API-docs of Non-RT RIC.
The Non-RT RIC consists of three parts, described in the sections below:
- * The Policy Agent
+ * The A1 Policy Management Service
* The Enrichment Coordinator Service
* The rAPP Catalogue
-Policy Agent
-============
+A1 Policy Management Service
+============================
-For information about the The Policy Agent that is implemented in ONAP, see `readthedocs`_ and `wiki`_.
+For information about the A1 Policy Management Service that is implemented in ONAP, see `readthedocs`_ and `wiki`_.
.. _readthedocs: https://docs.onap.org/projects/onap-ccsdk-oran/en/latest/index.html
.. _wiki: https://wiki.onap.org/pages/viewpage.action?pageId=84644984
@@ -37,10 +37,10 @@
See `ECS API <./ecs-api.html>`_ for how to use the API.
.. csv-table::
- :header: "API name", "|swagger-icon|"
- :widths: 10,5
+ :header: "API name", "|swagger-icon|", "|yaml-icon|"
+ :widths: 10,5,5
- "ECS API", ":download:`link <./offeredapis/swagger/ecs-api.json>`"
+ "ECS API", ":download:`link <../enrichment-coordinator-service/api/ecs-api.json>`", ":download:`link <../enrichment-coordinator-service/api/ecs-api.yaml>`"
rAPP Catalogue
diff --git a/docs/conf.py b/docs/conf.py
index 09eeb37..85721c6 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -24,7 +24,7 @@
{
'name': 'ECS API',
'page': 'ecs-api',
- 'spec': './offeredapis/swagger/ecs-api.json',
+ 'spec': '../enrichment-coordinator-service/api/ecs-api.json',
'embed': True,
}
]
diff --git a/docs/developer-guide.rst b/docs/developer-guide.rst
index 576cf2d..5358fe3 100644
--- a/docs/developer-guide.rst
+++ b/docs/developer-guide.rst
@@ -7,8 +7,8 @@
This document provides a quickstart for developers of the Non-RT RIC.
-Policy Agent
-------------
+A1 Policy Management Service
+----------------------------
The Policy Management is implemented in ONAP. For documentation see `readthedocs`_ and `wiki`_.
diff --git a/docs/release-notes.rst b/docs/release-notes.rst
index 1970ffa..b09dcfb 100644
--- a/docs/release-notes.rst
+++ b/docs/release-notes.rst
@@ -14,51 +14,54 @@
:local:
-Version history Policy Agent
-============================
+Version history A1 Policy Management Service
+============================================
-+------------+----------+------------------+-------------------+
-| **Date** | **Ver.** | **Author** | **Comment** |
-| | | | |
-+------------+----------+------------------+-------------------+
-| 2020-02-03 | 1.0.0 | Henrik Andersson | First version |
-| | | | Amber Maintenance |
-| | | | Release |
-+------------+----------+------------------+-------------------+
-| 2020-06-18 | 2.0.0 | Henrik Andersson | Bronze Release |
-| | | | |
-+------------+----------+------------------+-------------------+
-| 2020-07-29 | 2.0.1 | Henrik Andersson | Bronze Maintenance|
-| | | | Release |
-| | | | |
-+------------+----------+------------------+-------------------+
++------------+----------+------------------+--------------------+
+| **Date** | **Ver.** | **Author** | **Comment** |
+| | | | |
++------------+----------+------------------+--------------------+
+| 2020-02-03 | 1.0.0 | Henrik Andersson | First version |
+| | | | Amber Maintenance |
+| | | | Release |
++------------+----------+------------------+--------------------+
+| 2020-06-18 | 2.0.0 | Henrik Andersson | Bronze Release |
+| | | | |
++------------+----------+------------------+--------------------+
+| 2020-07-29 | 2.0.1 | Henrik Andersson | Bronze Maintenance |
+| | | | Release |
+| | | | |
++------------+----------+------------------+--------------------+
+| 2020-12-03 | 2.1.0 | Henrik Andersson | Cherry Release |
+| | | | |
++------------+----------+------------------+--------------------+
Summary
-------
-Improved stability.
+Introduction of Enrichment Service Coordinator and rAPP Catalogue.
Version history SDNC A1 Controller
==================================
-+------------+----------+------------------+-------------------+
-| **Date** | **Ver.** | **Author** | **Comment** |
-| | | | |
-+------------+----------+------------------+-------------------+
-| 2019-11-12 | 1.7.3 | Maxime Bonneau | |
-| | | | |
-+------------+----------+------------------+-------------------+
-| 2020-02-04 | 1.7.4 | Henrik Andersson | Amber Maintenance |
-| | | | Release |
-+------------+----------+------------------+-------------------+
-| 2020-06-18 | 2.0.0 | Henrik Andersson | Bronze Release |
-| | | | |
-+------------+----------+------------------+-------------------+
-| 2020-07-29 | 2.0.1 | Henrik Andersson | Bronze Maintenance|
-| | | | Release |
-| | | | |
-+------------+----------+------------------+-------------------+
++------------+----------+------------------+--------------------+
+| **Date** | **Ver.** | **Author** | **Comment** |
+| | | | |
++------------+----------+------------------+--------------------+
+| 2019-11-12 | 1.7.3 | Maxime Bonneau | |
+| | | | |
++------------+----------+------------------+--------------------+
+| 2020-02-04 | 1.7.4 | Henrik Andersson | Amber Maintenance |
+| | | | Release |
++------------+----------+------------------+--------------------+
+| 2020-06-18 | 2.0.0 | Henrik Andersson | Bronze Release |
+| | | | |
++------------+----------+------------------+--------------------+
+| 2020-07-29 | 2.0.1 | Henrik Andersson | Bronze Maintenance |
+| | | | Release |
+| | | | |
++------------+----------+------------------+--------------------+
Release Data
@@ -139,3 +142,23 @@
| **Purpose of the delivery** | Introduce configuration of certificates |
| | |
+-----------------------------+---------------------------------------------------+
+
+Cherry
+------
++-----------------------------+---------------------------------------------------+
+| **Project** | Non-RT RIC |
+| | |
++-----------------------------+---------------------------------------------------+
+| **Repo/commit-ID** | nonrtric/90ce16238dd6970153e1c0fbddb15e32c68c504f |
+| | |
++-----------------------------+---------------------------------------------------+
+| **Release designation** | Cherry |
+| | |
++-----------------------------+---------------------------------------------------+
+| **Release date** | 2020-12-03 |
+| | |
++-----------------------------+---------------------------------------------------+
+| **Purpose of the delivery** | Introduction of Enrichment Service Coordinator |
+| | and rAPP Catalogue |
+| | |
++-----------------------------+---------------------------------------------------+
diff --git a/docs/offeredapis/swagger/ecs-api.json b/enrichment-coordinator-service/api/ecs-api.json
similarity index 99%
rename from docs/offeredapis/swagger/ecs-api.json
rename to enrichment-coordinator-service/api/ecs-api.json
index 3684c0e..79ab5d3 100644
--- a/docs/offeredapis/swagger/ecs-api.json
+++ b/enrichment-coordinator-service/api/ecs-api.json
@@ -508,7 +508,6 @@
"tags": ["A1-EI (enrichment information)"]
}}
},
- "host": "localhost:34053",
"definitions": {
"producer_ei_job_request": {
"description": "The body of the EI producer callbacks for EI job creation and deletion",
@@ -742,4 +741,4 @@
"description": "Status Controller"
}
]
-}
+}
\ No newline at end of file
diff --git a/enrichment-coordinator-service/api/ecs-api.yaml b/enrichment-coordinator-service/api/ecs-api.yaml
new file mode 100644
index 0000000..ac49e5a
--- /dev/null
+++ b/enrichment-coordinator-service/api/ecs-api.yaml
@@ -0,0 +1,827 @@
+openapi: 3.0.1
+info:
+ title: Enrichment Data service
+ description: This page lists all the rest apis for the service.
+ version: "1.0"
+servers:
+- url: /
+tags:
+- name: A1-EI (enrichment information)
+ description: Consumer Controller
+- name: Consumer Callbacks
+ description: Consumer Simulator Controller
+- name: Enrichment Data Producer API
+ description: Producer Controller
+- name: Producer Callbacks
+ description: Producer Simulator Controller
+- name: Service status
+ description: Status Controller
+paths:
+ /producer_simulator/ei_job:
+ post:
+ tags:
+ - Producer Callbacks
+ summary: Callback for EI job creation
+ operationId: jobCreatedCallbackUsingPOST
+ requestBody:
+ description: request
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/producer_ei_job_request'
+ required: true
+ responses:
+ 200:
+ description: OK
+ content: {}
+ 201:
+ description: Created
+ content: {}
+ 401:
+ description: Unauthorized
+ content: {}
+ 403:
+ description: Forbidden
+ content: {}
+ 404:
+ description: Not Found
+ content: {}
+ deprecated: false
+ /A1-EI/v1/eitypes/{eiTypeId}:
+ get:
+ tags:
+ - A1-EI (enrichment information)
+ summary: Individual EI type
+ operationId: getEiTypeUsingGET
+ parameters:
+ - name: eiTypeId
+ in: path
+ description: eiTypeId
+ required: true
+ schema:
+ type: string
+ responses:
+ 200:
+ description: EI type
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/EiTypeObject'
+ 401:
+ description: Unauthorized
+ content: {}
+ 403:
+ description: Forbidden
+ content: {}
+ 404:
+ description: Enrichment Information type is not found
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ProblemDetails'
+ deprecated: false
+ /consumer_simulator/eijobs/{eiJobId}/status:
+ post:
+ tags:
+ - Consumer Callbacks
+ summary: Callback for EI job status
+ operationId: jobStatusCallbackUsingPOST
+ parameters:
+ - name: eiJobId
+ in: path
+ description: eiJobId
+ required: true
+ schema:
+ type: string
+ requestBody:
+ description: status
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/EiJobStatusObject'
+ required: true
+ responses:
+ 200:
+ description: OK
+ content: {}
+ 201:
+ description: Created
+ content: {}
+ 401:
+ description: Unauthorized
+ content: {}
+ 403:
+ description: Forbidden
+ content: {}
+ 404:
+ description: Not Found
+ content: {}
+ deprecated: false
+ /ei-producer/v1/eitypes:
+ get:
+ tags:
+ - Enrichment Data Producer API
+ summary: EI type identifiers
+ operationId: getEiTypeIdentifiersUsingGET_1
+ responses:
+ 200:
+ description: EI type identifiers
+ content:
+ application/json:
+ schema:
+ type: array
+ items:
+ type: string
+ 401:
+ description: Unauthorized
+ content: {}
+ 403:
+ description: Forbidden
+ content: {}
+ 404:
+ description: Not Found
+ content: {}
+ deprecated: false
+ /A1-EI/v1/eitypes:
+ get:
+ tags:
+ - A1-EI (enrichment information)
+ summary: EI type identifiers
+ operationId: getEiTypeIdentifiersUsingGET
+ responses:
+ 200:
+ description: EI type identifiers
+ content:
+ application/json:
+ schema:
+ type: array
+ items:
+ type: string
+ 401:
+ description: Unauthorized
+ content: {}
+ 403:
+ description: Forbidden
+ content: {}
+ 404:
+ description: Not Found
+ content: {}
+ deprecated: false
+ /ei-producer/v1/eiproducers/{eiProducerId}/status:
+ get:
+ tags:
+ - Enrichment Data Producer API
+ summary: EI producer status
+ operationId: getEiProducerStatusUsingGET
+ parameters:
+ - name: eiProducerId
+ in: path
+ description: eiProducerId
+ required: true
+ schema:
+ type: string
+ responses:
+ 200:
+ description: EI jobs
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/producer_status'
+ 401:
+ description: Unauthorized
+ content: {}
+ 403:
+ description: Forbidden
+ content: {}
+ 404:
+ description: Enrichment Information producer is not found
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ProblemDetails'
+ deprecated: false
+ /producer_simulator/ei_job/{eiJobId}:
+ delete:
+ tags:
+ - Producer Callbacks
+ summary: Callback for EI job deletion
+ operationId: jobDeletedCallbackUsingDELETE
+ parameters:
+ - name: eiJobId
+ in: path
+ description: eiJobId
+ required: true
+ schema:
+ type: string
+ responses:
+ 200:
+ description: OK
+ content: {}
+ 204:
+ description: No Content
+ content: {}
+ 401:
+ description: Unauthorized
+ content: {}
+ 403:
+ description: Forbidden
+ content: {}
+ deprecated: false
+ /ei-producer/v1/eiproducers:
+ get:
+ tags:
+ - Enrichment Data Producer API
+ summary: EI producer identifiers
+ operationId: getEiProducerIdentifiersUsingGET
+ responses:
+ 200:
+ description: EI producer identifiers
+ content:
+ application/json:
+ schema:
+ type: array
+ items:
+ type: string
+ 401:
+ description: Unauthorized
+ content: {}
+ 403:
+ description: Forbidden
+ content: {}
+ 404:
+ description: Not Found
+ content: {}
+ deprecated: false
+ /ei-producer/v1/eitypes/{eiTypeId}:
+ get:
+ tags:
+ - Enrichment Data Producer API
+ summary: Individual EI type
+ operationId: getEiTypeUsingGET_1
+ parameters:
+ - name: eiTypeId
+ in: path
+ description: eiTypeId
+ required: true
+ schema:
+ type: string
+ responses:
+ 200:
+ description: EI type
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/producer_ei_type_info'
+ 401:
+ description: Unauthorized
+ content: {}
+ 403:
+ description: Forbidden
+ content: {}
+ 404:
+ description: Enrichment Information type is not found
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ProblemDetails'
+ deprecated: false
+ /status:
+ get:
+ tags:
+ - Service status
+ summary: Returns status and statistics of this service
+ operationId: getStatusUsingGET
+ responses:
+ 200:
+ description: Service is living
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/status_info'
+ 401:
+ description: Unauthorized
+ content: {}
+ 403:
+ description: Forbidden
+ content: {}
+ 404:
+ description: Not Found
+ content: {}
+ deprecated: false
+ /A1-EI/v1/eijobs/{eiJobId}:
+ get:
+ tags:
+ - A1-EI (enrichment information)
+ summary: Individual EI job
+ operationId: getIndividualEiJobUsingGET
+ parameters:
+ - name: eiJobId
+ in: path
+ description: eiJobId
+ required: true
+ schema:
+ type: string
+ responses:
+ 200:
+ description: EI job
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/EiJobObject'
+ 401:
+ description: Unauthorized
+ content: {}
+ 403:
+ description: Forbidden
+ content: {}
+ 404:
+ description: Enrichment Information job is not found
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ProblemDetails'
+ deprecated: false
+ put:
+ tags:
+ - A1-EI (enrichment information)
+ summary: Individual EI job
+ operationId: putIndividualEiJobUsingPUT
+ parameters:
+ - name: eiJobId
+ in: path
+ description: eiJobId
+ required: true
+ schema:
+ type: string
+ requestBody:
+ description: eiJobObject
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/EiJobObject'
+ required: true
+ responses:
+ 200:
+ description: Job updated
+ content: {}
+ 201:
+ description: Job created
+ content: {}
+ 401:
+ description: Unauthorized
+ content: {}
+ 403:
+ description: Forbidden
+ content: {}
+ 404:
+ description: Enrichment Information type is not found
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ProblemDetails'
+ deprecated: false
+ delete:
+ tags:
+ - A1-EI (enrichment information)
+ summary: Individual EI job
+ operationId: deleteIndividualEiJobUsingDELETE
+ parameters:
+ - name: eiJobId
+ in: path
+ description: eiJobId
+ required: true
+ schema:
+ type: string
+ responses:
+ 200:
+ description: Not used
+ content: {}
+ 204:
+ description: Job deleted
+ content: {}
+ 401:
+ description: Unauthorized
+ content: {}
+ 403:
+ description: Forbidden
+ content: {}
+ 404:
+ description: Enrichment Information job is not found
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ProblemDetails'
+ deprecated: false
+ /ei-producer/v1/eiproducers/{eiProducerId}:
+ get:
+ tags:
+ - Enrichment Data Producer API
+ summary: Individual EI producer
+ operationId: getEiProducerUsingGET
+ parameters:
+ - name: eiProducerId
+ in: path
+ description: eiProducerId
+ required: true
+ schema:
+ type: string
+ responses:
+ 200:
+ description: EI jobs
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/producer_registration_info'
+ 401:
+ description: Unauthorized
+ content: {}
+ 403:
+ description: Forbidden
+ content: {}
+ 404:
+ description: Enrichment Information producer is not found
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ProblemDetails'
+ deprecated: false
+ put:
+ tags:
+ - Enrichment Data Producer API
+ summary: Individual EI producer
+ operationId: putEiProducerUsingPUT
+ parameters:
+ - name: eiProducerId
+ in: path
+ description: eiProducerId
+ required: true
+ schema:
+ type: string
+ requestBody:
+ description: registrationInfo
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/producer_registration_info'
+ required: true
+ responses:
+ 200:
+ description: Producer updated
+ content: {}
+ 201:
+ description: Producer created
+ content: {}
+ 401:
+ description: Unauthorized
+ content: {}
+ 403:
+ description: Forbidden
+ content: {}
+ 404:
+ description: Not Found
+ content: {}
+ deprecated: false
+ delete:
+ tags:
+ - Enrichment Data Producer API
+ summary: Individual EI producer
+ operationId: deleteEiProducerUsingDELETE
+ parameters:
+ - name: eiProducerId
+ in: path
+ description: eiProducerId
+ required: true
+ schema:
+ type: string
+ responses:
+ 200:
+ description: Not used
+ content: {}
+ 204:
+ description: Producer deleted
+ content: {}
+ 401:
+ description: Unauthorized
+ content: {}
+ 403:
+ description: Forbidden
+ content: {}
+ 404:
+ description: Producer is not found
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ProblemDetails'
+ deprecated: false
+ /producer_simulator/health_check:
+ get:
+ tags:
+ - Producer Callbacks
+ summary: Producer supervision
+ operationId: producerSupervisionUsingGET
+ responses:
+ 200:
+ description: OK
+ content:
+ application/json:
+ schema:
+ type: string
+ 401:
+ description: Unauthorized
+ content: {}
+ 403:
+ description: Forbidden
+ content: {}
+ 404:
+ description: Not Found
+ content: {}
+ deprecated: false
+ /ei-producer/v1/eiproducers/{eiProducerId}/eijobs:
+ get:
+ tags:
+ - Enrichment Data Producer API
+ summary: EI job definitions
+ description: EI job definitions for one EI producer
+ operationId: getEiProducerJobsUsingGET
+ parameters:
+ - name: eiProducerId
+ in: path
+ description: eiProducerId
+ required: true
+ schema:
+ type: string
+ responses:
+ 200:
+ description: EI jobs
+ content:
+ application/json:
+ schema:
+ type: array
+ items:
+ $ref: '#/components/schemas/producer_ei_job_request'
+ 401:
+ description: Unauthorized
+ content: {}
+ 403:
+ description: Forbidden
+ content: {}
+ 404:
+ description: Enrichment Information producer is not found
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ProblemDetails'
+ deprecated: false
+ /A1-EI/v1/eijobs:
+ get:
+ tags:
+ - A1-EI (enrichment information)
+ summary: EI job identifiers
+ description: query for EI job identifiers
+ operationId: getEiJobIdsUsingGET
+ parameters:
+ - name: eiTypeId
+ in: query
+ description: selects EI jobs of matching EI type
+ allowEmptyValue: false
+ schema:
+ type: string
+ - name: owner
+ in: query
+ description: selects EI jobs for one EI job owner
+ allowEmptyValue: false
+ schema:
+ type: string
+ responses:
+ 200:
+ description: EI job identifiers
+ content:
+ application/json:
+ schema:
+ type: array
+ items:
+ type: string
+ 401:
+ description: Unauthorized
+ content: {}
+ 403:
+ description: Forbidden
+ content: {}
+ 404:
+ description: Enrichment Information type is not found
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ProblemDetails'
+ deprecated: false
+ /A1-EI/v1/eijobs/{eiJobId}/status:
+ get:
+ tags:
+ - A1-EI (enrichment information)
+ summary: EI job status
+ operationId: getEiJobStatusUsingGET
+ parameters:
+ - name: eiJobId
+ in: path
+ description: eiJobId
+ required: true
+ schema:
+ type: string
+ responses:
+ 200:
+ description: EI job status
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/EiJobStatusObject'
+ 401:
+ description: Unauthorized
+ content: {}
+ 403:
+ description: Forbidden
+ content: {}
+ 404:
+ description: Enrichment Information job is not found
+ content:
+ application/json:
+ schema:
+ $ref: '#/components/schemas/ProblemDetails'
+ deprecated: false
+components:
+ schemas:
+ producer_ei_job_request:
+ title: producer_ei_job_request
+ required:
+ - ei_job_identity
+ type: object
+ properties:
+ owner:
+ type: string
+ description: The owner of the job
+ ei_job_identity:
+ type: string
+ description: Idenitity of the EI job
+ ei_job_data:
+ type: object
+ properties: {}
+ description: Json for the job data
+ target_uri:
+ type: string
+ description: URI for the target of the EI
+ ei_type_identity:
+ type: string
+ description: Type idenitity for the job
+ description: The body of the EI producer callbacks for EI job creation and deletion
+ EiTypeObject:
+ title: EiTypeObject
+ type: object
+ description: Information for an EI type
+ producer_ei_type_registration_info:
+ title: producer_ei_type_registration_info
+ required:
+ - ei_type_identity
+ type: object
+ properties:
+ ei_type_identity:
+ type: string
+ description: EI type identity
+ ei_job_data_schema:
+ type: object
+ properties: {}
+ description: Json schema for the job data
+ description: Information for an EI type
+ status_info:
+ title: status_info
+ type: object
+ properties:
+ no_of_producers:
+ type: integer
+ description: Number of EI producers
+ format: int32
+ no_of_jobs:
+ type: integer
+ description: Number of EI jobs
+ format: int32
+ no_of_types:
+ type: integer
+ description: Number of EI types
+ format: int32
+ status:
+ type: string
+ description: status text
+ Mono«ResponseEntity«object»»:
+ title: Mono«ResponseEntity«object»»
+ type: object
+ producer_ei_type_info:
+ title: producer_ei_type_info
+ type: object
+ properties:
+ ei_producer_ids:
+ type: array
+ description: Registered producers
+ items:
+ type: string
+ ei_job_data_schema:
+ type: object
+ properties: {}
+ description: Json schema for the job data
+ description: Information for an EI type
+ producer_registration_info:
+ title: producer_registration_info
+ required:
+ - ei_job_callback_url
+ - ei_producer_supervision_callback_url
+ - supported_ei_types
+ type: object
+ properties:
+ supported_ei_types:
+ type: array
+ description: Supported EI types
+ items:
+ $ref: '#/components/schemas/producer_ei_type_registration_info'
+ ei_producer_supervision_callback_url:
+ type: string
+ description: callback for producer supervision
+ ei_job_callback_url:
+ type: string
+ description: callback for EI job
+ description: Information for an EI producer
+ producer_status:
+ title: producer_status
+ required:
+ - operational_state
+ type: object
+ properties:
+ operational_state:
+ type: string
+ description: |-
+ Operational state, values:
+ ENABLED: TBD
+ DISABLED: TBD.
+ enum:
+ - ENABLED
+ - DISABLED
+ description: Status for an EI Producer
+ ProblemDetails:
+ title: ProblemDetails
+ type: object
+ properties:
+ detail:
+ type: string
+ description: A human-readable explanation specific to this occurrence of
+ the problem.
+ example: EI job type not found
+ status:
+ type: integer
+ description: The HTTP status code generated by the origin server for this
+ occurrence of the problem.
+ format: int32
+ example: 404
+ description: A problem detail to carry details in a HTTP response according
+ to RFC 7807
+ Void:
+ title: Void
+ type: object
+ description: Void/empty
+ EiJobStatusObject:
+ title: EiJobStatusObject
+ required:
+ - eiJobStatus
+ type: object
+ properties:
+ eiJobStatus:
+ type: string
+ description: |-
+ values:
+ ENABLED: the A1-EI producer is able to deliver EI result for the EI job
+ DISABLED: the A1-EI producer is unable to deliver EI result for the EI job
+ enum:
+ - ENABLED
+ - DISABLED
+ description: Status for an EI job
+ EiJobObject:
+ title: EiJobObject
+ required:
+ - eiTypeId
+ - jobDefinition
+ - jobOwner
+ - jobResultUri
+ type: object
+ properties:
+ eiTypeId:
+ type: string
+ description: EI type Idenitifier of the EI job
+ jobResultUri:
+ type: string
+ description: The target URI of the EI data
+ jobOwner:
+ type: string
+ description: Identity of the owner of the job
+ jobStatusNotificationUri:
+ type: string
+ description: The target of EI job status notifications
+ jobDefinition:
+ type: object
+ properties: {}
+ description: EI type specific job data
+ description: Information for an Enrichment Information Job
diff --git a/enrichment-coordinator-service/config/application.yaml b/enrichment-coordinator-service/config/application.yaml
index 850dc67..5900d63 100644
--- a/enrichment-coordinator-service/config/application.yaml
+++ b/enrichment-coordinator-service/config/application.yaml
@@ -9,9 +9,11 @@
endpoints:
web:
exposure:
+ # Enabling of springboot actuator features. See springboot documentation.
include: "loggers,logfile,health,info,metrics,threaddump,heapdump"
logging:
+ # Configuration of logging
level:
ROOT: ERROR
org.springframework: ERROR
@@ -21,6 +23,8 @@
file:
name: /var/log/enrichment-coordinator-service/application.log
server:
+ # Configuration of the HTTP/REST server. The parameters are defined and handeled by the springboot framework.
+ # See springboot documentation.
port : 8434
http-port: 8083
ssl:
@@ -30,10 +34,16 @@
key-password: policy_agent
key-alias: policy_agent
app:
- filepath: /opt/app/enrichment-coordinator-service/data/application_configuration.json
webclient:
+ # Configuration of the trust store used for the HTTP client (outgoing requests)
+ # The file location and the password for the truststore is only relevant if trust-store-used == true
+ # Note that the same keystore as for the server is used.
trust-store-used: false
trust-store-password: policy_agent
trust-store: /opt/app/enrichment-coordinator-service/etc/cert/truststore.jks
+ # Configuration of usage of HTTP Proxy for the southbound accesses.
+ # The HTTP proxy (if configured) will only be used for accessing NearRT RIC:s
+ http.proxy-host:
+ http.proxy-port: 0
vardata-directory: /var/enrichment-coordinator-service
diff --git a/enrichment-coordinator-service/pom.xml b/enrichment-coordinator-service/pom.xml
index d34c9a6..2a65315 100644
--- a/enrichment-coordinator-service/pom.xml
+++ b/enrichment-coordinator-service/pom.xml
@@ -56,6 +56,7 @@
<maven-compiler-plugin.version>3.8.0</maven-compiler-plugin.version>
<formatter-maven-plugin.version>2.12.2</formatter-maven-plugin.version>
<spotless-maven-plugin.version>1.24.3</spotless-maven-plugin.version>
+ <swagger-codegen-maven-plugin.version>3.0.11</swagger-codegen-maven-plugin.version>
<docker-maven-plugin>0.30.0</docker-maven-plugin>
<version.dmaap>1.1.11</version.dmaap>
<javax.ws.rs-api.version>2.1.1</javax.ws.rs-api.version>
@@ -281,6 +282,27 @@
</executions>
</plugin>
<plugin>
+ <groupId>io.swagger.codegen.v3</groupId>
+ <artifactId>swagger-codegen-maven-plugin</artifactId>
+ <version>${swagger-codegen-maven-plugin.version}</version>
+ <executions>
+ <execution>
+ <phase>test</phase>
+ <goals>
+ <goal>generate</goal>
+ </goals>
+ <configuration>
+ <inputSpec>${project.basedir}/api/ecs-api.json</inputSpec>
+ <language>openapi-yaml</language>
+ <output>${project.basedir}/api</output>
+ <configOptions>
+ <outputFile>ecs-api.yaml</outputFile>
+ </configOptions>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+ <plugin>
<groupId>io.fabric8</groupId>
<artifactId>docker-maven-plugin</artifactId>
<version>${docker-maven-plugin}</version>
diff --git a/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/clients/AsyncRestClient.java b/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/clients/AsyncRestClient.java
index 76da624..f0f6c4b 100644
--- a/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/clients/AsyncRestClient.java
+++ b/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/clients/AsyncRestClient.java
@@ -28,6 +28,7 @@
import java.lang.invoke.MethodHandles;
import java.util.concurrent.atomic.AtomicInteger;
+import org.oransc.enrichment.configuration.WebClientConfig.HttpProxyConfig;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.http.MediaType;
@@ -42,6 +43,7 @@
import reactor.core.publisher.Mono;
import reactor.netty.http.client.HttpClient;
import reactor.netty.resources.ConnectionProvider;
+import reactor.netty.tcp.ProxyProvider.Proxy;
import reactor.netty.tcp.TcpClient;
/**
@@ -54,19 +56,12 @@
private final String baseUrl;
private static final AtomicInteger sequenceNumber = new AtomicInteger();
private final SslContext sslContext;
+ private final HttpProxyConfig httpProxyConfig;
- /**
- * Note that only http (not https) will work when this constructor is used.
- *
- * @param baseUrl
- */
- public AsyncRestClient(String baseUrl) {
- this(baseUrl, null);
- }
-
- public AsyncRestClient(String baseUrl, SslContext sslContext) {
+ public AsyncRestClient(String baseUrl, @Nullable SslContext sslContext, @Nullable HttpProxyConfig httpProxyConfig) {
this.baseUrl = baseUrl;
this.sslContext = sslContext;
+ this.httpProxyConfig = httpProxyConfig;
}
public Mono<ResponseEntity<String>> postForEntity(String uri, @Nullable String body) {
@@ -188,7 +183,7 @@
logger.debug("{} HTTP error status = '{}', body '{}'", traceTag, exception.getStatusCode(),
exception.getResponseBodyAsString());
} else {
- logger.debug("{} HTTP error", traceTag, t);
+ logger.debug("{} HTTP error {}", traceTag, t.getMessage());
}
}
@@ -200,27 +195,31 @@
}
}
- private TcpClient createTcpClientSecure(SslContext sslContext) {
- return TcpClient.create(ConnectionProvider.newConnection()) //
- .option(ChannelOption.CONNECT_TIMEOUT_MILLIS, 10_000) //
- .secure(c -> c.sslContext(sslContext)) //
- .doOnConnected(connection -> {
- connection.addHandlerLast(new ReadTimeoutHandler(30));
- connection.addHandlerLast(new WriteTimeoutHandler(30));
- });
+ private boolean isHttpProxyConfigured() {
+ return httpProxyConfig != null && httpProxyConfig.httpProxyPort() > 0
+ && !httpProxyConfig.httpProxyHost().isEmpty();
}
- private TcpClient createTcpClientInsecure() {
- return TcpClient.create(ConnectionProvider.newConnection()) //
+ private TcpClient createTcpClient() {
+ TcpClient client = TcpClient.create(ConnectionProvider.newConnection()) //
.option(ChannelOption.CONNECT_TIMEOUT_MILLIS, 10_000) //
.doOnConnected(connection -> {
connection.addHandlerLast(new ReadTimeoutHandler(30));
connection.addHandlerLast(new WriteTimeoutHandler(30));
});
+ if (this.sslContext != null) {
+ client = client.secure(c -> c.sslContext(sslContext));
+ }
+ if (isHttpProxyConfigured()) {
+ client = client.proxy(proxy -> proxy.type(Proxy.HTTP).host(httpProxyConfig.httpProxyHost())
+ .port(httpProxyConfig.httpProxyPort()));
+ }
+ return client;
}
private WebClient createWebClient(String baseUrl, TcpClient tcpClient) {
HttpClient httpClient = HttpClient.from(tcpClient);
+
ReactorClientHttpConnector connector = new ReactorClientHttpConnector(httpClient);
ExchangeStrategies exchangeStrategies = ExchangeStrategies.builder() //
.codecs(configurer -> configurer.defaultCodecs().maxInMemorySize(-1)) //
@@ -235,13 +234,8 @@
private Mono<WebClient> getWebClient() {
if (this.webClient == null) {
try {
- if (this.sslContext != null) {
- TcpClient tcpClient = createTcpClientSecure(sslContext);
- this.webClient = createWebClient(this.baseUrl, tcpClient);
- } else {
- TcpClient tcpClient = createTcpClientInsecure();
- this.webClient = createWebClient(this.baseUrl, tcpClient);
- }
+ TcpClient tcpClient = createTcpClient();
+ this.webClient = createWebClient(this.baseUrl, tcpClient);
} catch (Exception e) {
logger.error("Could not create WebClient {}", e.getMessage());
return Mono.error(e);
diff --git a/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/clients/AsyncRestClientFactory.java b/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/clients/AsyncRestClientFactory.java
index 07f23e9..4865df5 100644
--- a/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/clients/AsyncRestClientFactory.java
+++ b/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/clients/AsyncRestClientFactory.java
@@ -42,6 +42,7 @@
import javax.net.ssl.KeyManagerFactory;
import org.oransc.enrichment.configuration.WebClientConfig;
+import org.oransc.enrichment.configuration.WebClientConfig.HttpProxyConfig;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.util.ResourceUtils;
@@ -53,25 +54,38 @@
private static final Logger logger = LoggerFactory.getLogger(MethodHandles.lookup().lookupClass());
private final SslContextFactory sslContextFactory;
+ private final HttpProxyConfig httpProxyConfig;
public AsyncRestClientFactory(WebClientConfig clientConfig) {
if (clientConfig != null) {
this.sslContextFactory = new CachingSslContextFactory(clientConfig);
+ this.httpProxyConfig = clientConfig.httpProxyConfig();
} else {
+ logger.warn("No configuration for web client defined, HTTPS will not work");
this.sslContextFactory = null;
+ this.httpProxyConfig = null;
}
}
- public AsyncRestClient createRestClient(String baseUrl) {
+ public AsyncRestClient createRestClientNoHttpProxy(String baseUrl) {
+ return createRestClient(baseUrl, false);
+ }
+
+ public AsyncRestClient createRestClientUseHttpProxy(String baseUrl) {
+ return createRestClient(baseUrl, true);
+ }
+
+ private AsyncRestClient createRestClient(String baseUrl, boolean useHttpProxy) {
if (this.sslContextFactory != null) {
try {
- return new AsyncRestClient(baseUrl, this.sslContextFactory.createSslContext());
+ return new AsyncRestClient(baseUrl, this.sslContextFactory.createSslContext(),
+ useHttpProxy ? httpProxyConfig : null);
} catch (Exception e) {
String exceptionString = e.toString();
logger.error("Could not init SSL context, reason: {}", exceptionString);
}
}
- return new AsyncRestClient(baseUrl);
+ return new AsyncRestClient(baseUrl, null, httpProxyConfig);
}
private class SslContextFactory {
@@ -175,5 +189,4 @@
}
}
-
}
diff --git a/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/configuration/ApplicationConfig.java b/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/configuration/ApplicationConfig.java
index 8937464..fce9e22 100644
--- a/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/configuration/ApplicationConfig.java
+++ b/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/configuration/ApplicationConfig.java
@@ -20,10 +20,9 @@
package org.oransc.enrichment.configuration;
-import javax.validation.constraints.NotEmpty;
-
import lombok.Getter;
+import org.oransc.enrichment.configuration.WebClientConfig.HttpProxyConfig;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
@@ -31,10 +30,6 @@
@EnableConfigurationProperties
@ConfigurationProperties()
public class ApplicationConfig {
- @NotEmpty
- @Getter
- @Value("${app.filepath}")
- private String localConfigurationFilePath;
@Getter
@Value("${app.vardata-directory}")
@@ -61,7 +56,17 @@
@Value("${app.webclient.trust-store}")
private String sslTrustStore = "";
+ @Value("${app.webclient.http.proxy-host:\"\"}")
+ private String httpProxyHost = "";
+
+ @Value("${app.webclient.http.proxy-port:0}")
+ private int httpProxyPort = 0;
+
public WebClientConfig getWebClientConfig() {
+ HttpProxyConfig httpProxyConfig = ImmutableHttpProxyConfig.builder() //
+ .httpProxyHost(this.httpProxyHost) //
+ .httpProxyPort(this.httpProxyPort) //
+ .build();
return ImmutableWebClientConfig.builder() //
.keyStoreType(this.sslKeyStoreType) //
.keyStorePassword(this.sslKeyStorePassword) //
@@ -70,6 +75,7 @@
.isTrustStoreUsed(this.sslTrustStoreUsed) //
.trustStore(this.sslTrustStore) //
.trustStorePassword(this.sslTrustStorePassword) //
+ .httpProxyConfig(httpProxyConfig) //
.build();
}
diff --git a/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/configuration/WebClientConfig.java b/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/configuration/WebClientConfig.java
index 61d0f5a..0b68248 100644
--- a/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/configuration/WebClientConfig.java
+++ b/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/configuration/WebClientConfig.java
@@ -42,4 +42,13 @@
public String trustStore();
+ @Value.Immutable
+ public interface HttpProxyConfig {
+ public String httpProxyHost();
+
+ public int httpProxyPort();
+ }
+
+ public HttpProxyConfig httpProxyConfig();
+
}
diff --git a/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/consumer/ConsumerCallbacks.java b/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/consumer/ConsumerCallbacks.java
index 9087355..c222cfa 100644
--- a/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/consumer/ConsumerCallbacks.java
+++ b/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/consumer/ConsumerCallbacks.java
@@ -55,7 +55,7 @@
@Autowired
public ConsumerCallbacks(ApplicationConfig config, EiTypes eiTypes, EiJobs eiJobs) {
AsyncRestClientFactory restClientFactory = new AsyncRestClientFactory(config.getWebClientConfig());
- this.restClient = restClientFactory.createRestClient("");
+ this.restClient = restClientFactory.createRestClientUseHttpProxy("");
this.eiTypes = eiTypes;
this.eiJobs = eiJobs;
}
diff --git a/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/producer/ProducerCallbacks.java b/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/producer/ProducerCallbacks.java
index dc732e1..00d9c14 100644
--- a/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/producer/ProducerCallbacks.java
+++ b/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/controllers/producer/ProducerCallbacks.java
@@ -60,7 +60,7 @@
@Autowired
public ProducerCallbacks(ApplicationConfig config, EiTypes eiTypes) {
AsyncRestClientFactory restClientFactory = new AsyncRestClientFactory(config.getWebClientConfig());
- this.restClient = restClientFactory.createRestClient("");
+ this.restClient = restClientFactory.createRestClientNoHttpProxy("");
this.eiTypes = eiTypes;
}
diff --git a/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/tasks/ProducerSupervision.java b/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/tasks/ProducerSupervision.java
index e242166..b4c21d4 100644
--- a/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/tasks/ProducerSupervision.java
+++ b/enrichment-coordinator-service/src/main/java/org/oransc/enrichment/tasks/ProducerSupervision.java
@@ -57,7 +57,7 @@
public ProducerSupervision(ApplicationConfig applicationConfig, EiProducers eiProducers, EiJobs eiJobs,
EiTypes eiTypes, ConsumerCallbacks consumerCallbacks) {
AsyncRestClientFactory restClientFactory = new AsyncRestClientFactory(applicationConfig.getWebClientConfig());
- this.restClient = restClientFactory.createRestClient("");
+ this.restClient = restClientFactory.createRestClientNoHttpProxy("");
this.eiJobs = eiJobs;
this.eiProducers = eiProducers;
this.eiTypes = eiTypes;
diff --git a/enrichment-coordinator-service/src/test/java/org/oransc/enrichment/ApplicationTest.java b/enrichment-coordinator-service/src/test/java/org/oransc/enrichment/ApplicationTest.java
index c5ee82a..b62a965 100644
--- a/enrichment-coordinator-service/src/test/java/org/oransc/enrichment/ApplicationTest.java
+++ b/enrichment-coordinator-service/src/test/java/org/oransc/enrichment/ApplicationTest.java
@@ -45,8 +45,10 @@
import org.oransc.enrichment.clients.AsyncRestClient;
import org.oransc.enrichment.clients.AsyncRestClientFactory;
import org.oransc.enrichment.configuration.ApplicationConfig;
+import org.oransc.enrichment.configuration.ImmutableHttpProxyConfig;
import org.oransc.enrichment.configuration.ImmutableWebClientConfig;
import org.oransc.enrichment.configuration.WebClientConfig;
+import org.oransc.enrichment.configuration.WebClientConfig.HttpProxyConfig;
import org.oransc.enrichment.controller.ConsumerSimulatorController;
import org.oransc.enrichment.controller.ProducerSimulatorController;
import org.oransc.enrichment.controllers.consumer.ConsumerConsts;
@@ -161,8 +163,10 @@
ResponseEntity<String> resp = restClient().getForEntity(url).block();
assertThat(resp.getStatusCode()).isEqualTo(HttpStatus.OK);
- String indented = (new JSONObject(resp.getBody())).toString(4);
- try (PrintStream out = new PrintStream(new FileOutputStream("../docs/offeredapis/swagger/ecs-api.json"))) {
+ JSONObject jsonObj = new JSONObject(resp.getBody());
+ jsonObj.remove("host");
+ String indented = jsonObj.toString(4);
+ try (PrintStream out = new PrintStream(new FileOutputStream("api/ecs-api.json"))) {
out.print(indented);
}
}
@@ -711,6 +715,10 @@
private AsyncRestClient restClient(boolean useTrustValidation) {
WebClientConfig config = this.applicationConfig.getWebClientConfig();
+ HttpProxyConfig httpProxyConfig = ImmutableHttpProxyConfig.builder() //
+ .httpProxyHost("") //
+ .httpProxyPort(0) //
+ .build();
config = ImmutableWebClientConfig.builder() //
.keyStoreType(config.keyStoreType()) //
.keyStorePassword(config.keyStorePassword()) //
@@ -719,10 +727,10 @@
.isTrustStoreUsed(useTrustValidation) //
.trustStore(config.trustStore()) //
.trustStorePassword(config.trustStorePassword()) //
- .build();
+ .httpProxyConfig(httpProxyConfig).build();
AsyncRestClientFactory restClientFactory = new AsyncRestClientFactory(config);
- return restClientFactory.createRestClient(baseUrl());
+ return restClientFactory.createRestClientNoHttpProxy(baseUrl());
}
private AsyncRestClient restClient() {
diff --git a/enrichment-coordinator-service/src/test/java/org/oransc/enrichment/clients/AsyncRestClientTest.java b/enrichment-coordinator-service/src/test/java/org/oransc/enrichment/clients/AsyncRestClientTest.java
index f879c7b..364203a 100644
--- a/enrichment-coordinator-service/src/test/java/org/oransc/enrichment/clients/AsyncRestClientTest.java
+++ b/enrichment-coordinator-service/src/test/java/org/oransc/enrichment/clients/AsyncRestClientTest.java
@@ -58,7 +58,7 @@
InternalLoggerFactory.setDefaultFactory(JdkLoggerFactory.INSTANCE);
Loggers.useJdkLoggers();
mockWebServer = new MockWebServer();
- clientUnderTest = new AsyncRestClient(mockWebServer.url(BASE_URL).toString());
+ clientUnderTest = new AsyncRestClient(mockWebServer.url(BASE_URL).toString(), null, null);
}
@AfterAll
diff --git a/test/auto-test/FTC1.sh b/test/auto-test/FTC1.sh
index 144ac36..9c0254f 100755
--- a/test/auto-test/FTC1.sh
+++ b/test/auto-test/FTC1.sh
@@ -24,7 +24,7 @@
INCLUDED_IMAGES="CBS CONSUL CP CR MR PA RICSIM SDNC"
#SUPPORTED TEST ENV FILE
-SUPPORTED_PROFILES="ONAP-MASTER ONAP-GUILIN ORAN-CHERRY"
+SUPPORTED_PROFILES="ONAP-GUILIN ONAP-HONOLULU ORAN-CHERRY ORAN-DAWN"
. ../common/testcase_common.sh $@
. ../common/agent_api_functions.sh
diff --git a/test/auto-test/FTC10.sh b/test/auto-test/FTC10.sh
index ca545b2..77a6c34 100755
--- a/test/auto-test/FTC10.sh
+++ b/test/auto-test/FTC10.sh
@@ -23,7 +23,7 @@
INCLUDED_IMAGES="CBS CONSUL CP CR MR PA RICSIM"
#SUPPORTED TEST ENV FILE
-SUPPORTED_PROFILES="ONAP-MASTER ONAP-GUILIN ORAN-CHERRY"
+SUPPORTED_PROFILES="ONAP-GUILIN ONAP-HONOLULU ORAN-CHERRY ORAN-DAWN"
. ../common/testcase_common.sh $@
. ../common/agent_api_functions.sh
diff --git a/test/auto-test/FTC100.sh b/test/auto-test/FTC100.sh
index 4b2e162..34705f4 100755
--- a/test/auto-test/FTC100.sh
+++ b/test/auto-test/FTC100.sh
@@ -23,9 +23,8 @@
#App names to include in the test, space separated list
INCLUDED_IMAGES="CBS CONSUL CP CR MR PA RICSIM SDNC"
-
#SUPPORTED TEST ENV FILE
-SUPPORTED_PROFILES="ONAP-MASTER ONAP-GUILIN ORAN-CHERRY"
+SUPPORTED_PROFILES="ONAP-GUILIN ONAP-HONOLULU ORAN-CHERRY ORAN-DAWN"
. ../common/testcase_common.sh $@
. ../common/agent_api_functions.sh
diff --git a/test/auto-test/FTC110.sh b/test/auto-test/FTC110.sh
index 0406c40..50e3f37 100755
--- a/test/auto-test/FTC110.sh
+++ b/test/auto-test/FTC110.sh
@@ -24,7 +24,7 @@
INCLUDED_IMAGES="CBS CONSUL CP CR MR PA RICSIM"
#SUPPORTED TEST ENV FILE
-SUPPORTED_PROFILES="ONAP-MASTER ONAP-GUILIN ORAN-CHERRY"
+SUPPORTED_PROFILES="ONAP-GUILIN ONAP-HONOLULU ORAN-CHERRY ORAN-DAWN"
. ../common/testcase_common.sh $@
. ../common/agent_api_functions.sh
diff --git a/test/auto-test/FTC1100.sh b/test/auto-test/FTC1100.sh
index 4672cb2..3ad18f3 100755
--- a/test/auto-test/FTC1100.sh
+++ b/test/auto-test/FTC1100.sh
@@ -24,7 +24,7 @@
INCLUDED_IMAGES="ECS PRODSTUB CR RICSIM CP"
#SUPPORTED TEST ENV FILE
-SUPPORTED_PROFILES="ONAP-MASTER ORAN-CHERRY"
+SUPPORTED_PROFILES="ONAP-HONOLULU ORAN-CHERRY ORAN-DAWN"
. ../common/testcase_common.sh $@
. ../common/ecs_api_functions.sh
diff --git a/test/auto-test/FTC150.sh b/test/auto-test/FTC150.sh
index daeb3c7..ab1e8a6 100755
--- a/test/auto-test/FTC150.sh
+++ b/test/auto-test/FTC150.sh
@@ -24,7 +24,7 @@
INCLUDED_IMAGES="RICSIM SDNC"
#SUPPORTED TEST ENV FILE
-SUPPORTED_PROFILES="ONAP-MASTER ONAP-GUILIN ORAN-CHERRY"
+SUPPORTED_PROFILES="ONAP-GUILIN ONAP-HONOLULU ORAN-CHERRY ORAN-DAWN"
. ../common/testcase_common.sh $@
. ../common/controller_api_functions.sh
diff --git a/test/auto-test/FTC1800.sh b/test/auto-test/FTC1800.sh
index caec939..f807967 100755
--- a/test/auto-test/FTC1800.sh
+++ b/test/auto-test/FTC1800.sh
@@ -24,7 +24,7 @@
INCLUDED_IMAGES="ECS PRODSTUB CR CP"
#SUPPORTED TEST ENV FILE
-SUPPORTED_PROFILES="ONAP-MASTER ORAN-CHERRY"
+SUPPORTED_PROFILES="ONAP-HONOLULU ORAN-CHERRY ORAN-DAWN"
. ../common/testcase_common.sh $@
. ../common/ecs_api_functions.sh
diff --git a/test/auto-test/FTC300.sh b/test/auto-test/FTC300.sh
index 3973282..713d330 100755
--- a/test/auto-test/FTC300.sh
+++ b/test/auto-test/FTC300.sh
@@ -23,7 +23,7 @@
INCLUDED_IMAGES="CBS CONSUL CP CR MR PA RICSIM SDNC"
#SUPPORTED TEST ENV FILE
-SUPPORTED_PROFILES="ONAP-MASTER ONAP-GUILIN ORAN-CHERRY"
+SUPPORTED_PROFILES="ONAP-GUILIN ONAP-HONOLULU ORAN-CHERRY ORAN-DAWN"
. ../common/testcase_common.sh $@
. ../common/agent_api_functions.sh
diff --git a/test/auto-test/FTC310.sh b/test/auto-test/FTC310.sh
index eec4542..674df8c 100755
--- a/test/auto-test/FTC310.sh
+++ b/test/auto-test/FTC310.sh
@@ -24,7 +24,7 @@
INCLUDED_IMAGES="CBS CONSUL CP CR MR PA RICSIM"
#SUPPORTED TEST ENV FILE
-SUPPORTED_PROFILES="ONAP-MASTER ONAP-GUILIN ORAN-CHERRY"
+SUPPORTED_PROFILES="ONAP-GUILIN ONAP-HONOLULU ORAN-CHERRY ORAN-DAWN"
. ../common/testcase_common.sh $@
. ../common/agent_api_functions.sh
diff --git a/test/auto-test/FTC350.sh b/test/auto-test/FTC350.sh
index 0605944..4df0a15 100755
--- a/test/auto-test/FTC350.sh
+++ b/test/auto-test/FTC350.sh
@@ -23,7 +23,7 @@
INCLUDED_IMAGES="CBS CONSUL CP CR MR PA RICSIM SDNC"
#SUPPORTED TEST ENV FILE
-SUPPORTED_PROFILES="ONAP-MASTER ONAP-GUILIN ORAN-CHERRY"
+SUPPORTED_PROFILES="ONAP-GUILIN ONAP-HONOLULU ORAN-CHERRY ORAN-DAWN"
. ../common/testcase_common.sh $@
. ../common/agent_api_functions.sh
diff --git a/test/auto-test/FTC800.sh b/test/auto-test/FTC800.sh
index c90940c..ceda58c 100755
--- a/test/auto-test/FTC800.sh
+++ b/test/auto-test/FTC800.sh
@@ -23,7 +23,7 @@
INCLUDED_IMAGES="CBS CONSUL CP CR MR PA RICSIM SDNC"
#SUPPORTED TEST ENV FILE
-SUPPORTED_PROFILES="ONAP-MASTER ONAP-GUILIN ORAN-CHERRY"
+SUPPORTED_PROFILES="ONAP-GUILIN ONAP-HONOLULU ORAN-CHERRY ORAN-DAWN"
. ../common/testcase_common.sh $@
. ../common/agent_api_functions.sh
diff --git a/test/auto-test/FTC810.sh b/test/auto-test/FTC810.sh
index 7ac759c..c5d284a 100755
--- a/test/auto-test/FTC810.sh
+++ b/test/auto-test/FTC810.sh
@@ -23,7 +23,7 @@
INCLUDED_IMAGES="CBS CONSUL CP CR MR PA RICSIM SDNC"
#SUPPORTED TEST ENV FILE
-SUPPORTED_PROFILES="ONAP-MASTER ONAP-GUILIN ORAN-CHERRY"
+SUPPORTED_PROFILES="ONAP-GUILIN ONAP-HONOLULU ORAN-CHERRY ORAN-DAWN"
. ../common/testcase_common.sh $@
. ../common/agent_api_functions.sh
diff --git a/test/auto-test/FTC850.sh b/test/auto-test/FTC850.sh
index 3b65b10..324044e 100755
--- a/test/auto-test/FTC850.sh
+++ b/test/auto-test/FTC850.sh
@@ -23,7 +23,7 @@
INCLUDED_IMAGES="CBS CONSUL CP CR MR PA RICSIM SDNC"
#SUPPORTED TEST ENV FILE
-SUPPORTED_PROFILES="ONAP-MASTER ONAP-GUILIN ORAN-CHERRY"
+SUPPORTED_PROFILES="ONAP-GUILIN ONAP-HONOLULU ORAN-CHERRY ORAN-DAWN"
. ../common/testcase_common.sh $@
. ../common/agent_api_functions.sh
diff --git a/test/auto-test/FTC900.sh b/test/auto-test/FTC900.sh
index 356301e..8a937ff 100755
--- a/test/auto-test/FTC900.sh
+++ b/test/auto-test/FTC900.sh
@@ -23,7 +23,7 @@
INCLUDED_IMAGES="CBS CONSUL CP CR MR PA RICSIM"
#SUPPORTED TEST ENV FILE
-SUPPORTED_PROFILES="ONAP-MASTER ONAP-GUILIN ORAN-CHERRY"
+SUPPORTED_PROFILES="ONAP-GUILIN ONAP-HONOLULU ORAN-CHERRY ORAN-DAWN"
. ../common/testcase_common.sh $@
. ../common/agent_api_functions.sh
diff --git a/test/auto-test/PM_DEMO.sh b/test/auto-test/PM_DEMO.sh
index c43ad3e..fe85372 100755
--- a/test/auto-test/PM_DEMO.sh
+++ b/test/auto-test/PM_DEMO.sh
@@ -23,7 +23,7 @@
INCLUDED_IMAGES="CBS CONSUL CP CR MR PA RICSIM SDNC"
#SUPPORTED TEST ENV FILE
-SUPPORTED_PROFILES="ONAP-MASTER ONAP-GUILIN ORAN-CHERRY"
+SUPPORTED_PROFILES="ONAP-GUILIN ONAP-HONOLULU ORAN-CHERRY ORAN-DAWN"
. ../common/testcase_common.sh $@
. ../common/agent_api_functions.sh
diff --git a/test/auto-test/PM_EI_DEMO.sh b/test/auto-test/PM_EI_DEMO.sh
index 2915b02..3f9f8fd 100755
--- a/test/auto-test/PM_EI_DEMO.sh
+++ b/test/auto-test/PM_EI_DEMO.sh
@@ -23,7 +23,7 @@
INCLUDED_IMAGES="CBS CONSUL CP CR MR PA RICSIM SDNC ECS PRODSTUB RC"
#SUPPORTED TEST ENV FILE
-SUPPORTED_PROFILES="ONAP-MASTER ORAN-CHERRY"
+SUPPORTED_PROFILES="ONAP-HONOLULU ORAN-CHERRY ORAN-DAWN"
. ../common/testcase_common.sh $@
. ../common/agent_api_functions.sh
@@ -72,8 +72,6 @@
start_policy_agent
-start_rapp_catalogue
-
start_cr
start_prod_stub
diff --git a/test/auto-test/README.md b/test/auto-test/README.md
index 82ff47b..005ee0a 100644
--- a/test/auto-test/README.md
+++ b/test/auto-test/README.md
@@ -15,7 +15,7 @@
## How to run
A test script, for example FTC1, is executed from the cmd line using the script filename and one or more parameters:
- ./FTC1.sh remote --env-file ../common/test_env-oran-cherry
+ ./FTC1.sh remote --env-file ../common/test_env-oran-cherry.sh
See the README.md in `../common/` for all details about available parameters and their meaning.
diff --git a/test/common/README.md b/test/common/README.md
index 21475c0..b4754cd 100644
--- a/test/common/README.md
+++ b/test/common/README.md
@@ -68,18 +68,22 @@
| arg list |
|--|
-| `local|remote|remote-remove [auto-clean] [--stop-at-error] [--ricsim-prefix <prefix> ] [ --env-file <environment-filename> ] [--use-local-image <app-nam> [<app-name>]*]` |
+| `remote|remote-remove --env-file <environment-filename> [release] [auto-clean] [--stop-at-error] [--ricsim-prefix <prefix> ] [--use-local-image <app-nam>+] [--use-snapshot-image <app-nam>+] [--use-staging-image <app-nam>+] [--use-release-image <app-nam>+]` |
| parameter | description |
|-|-|
-| `local` | only locally built images (in local docker respository) will be used for the Non-RT RIC components. CBS, Consul, DB will still use remote nexus images |
-| `remote` | only remote images from nexus will be used. Images pulled if not present in local docker repository |
-| `remote-remove` | same as remote but all images are removed first so that fresh images are pulled when running |
-| `auto-clean` | all containers will be automatically stopped and removed when the test case is complete. Requires the function 'auto_clean_containers' to be included last in the applicable auto-test script |
-| `--stop-at-error` | intended for debugging and make the script stop at first 'FAIL' and save all logs with a prefix 'STOP_AT_ERROR' |
-| `--ricsim-prefix <prefix>` | use another prefix for the ric simulator container name than the standard 'ricsim'. Note that the testscript has to read and use the env var `$RIC_SIM_PREFIX` instead of a hardcoded name of the ric(s). |
-| `--env-file` | point to a file with environment variables (the previous default, test_env.sh, replaced with one env file for each branch in test/common) |
-| `--use-local-image <app-nam> [<app-name>]*` | only applicable when running as 'remote' or 'remote-remove'. Mainly for debugging when a locally built image shall be used together with other remote images from nexus.Accepts a space separated list of PA, CP, RICSIM, SDNC, RC for Policy Agent, Control Panel, A1-controller, Ric simulator, RAPP Catalogue |
+| `remote` | Use images from remote repositories. Can be overridden for individual images using the '--use_xxx' flags |
+| `remote-remove` | Same as 'remote' but will also try to pull fresh images from remote repositories |
+| `--env-file` | The script will use the supplied file to read environment variables from |
+| `release` | If this flag is given the script will use release version of the images |
+| `auto-clean` | If the function 'auto_clean_containers' is present in the end of the test script then all containers will be stopped and removed. If 'auto-clean' is not given then the function has no effect |
+| `--stop-at-error` | The script will stop when the first failed test or configuration |
+| `--ricsim-prefix <prefix>` | The a1 simulator will use the supplied string as container prefix instead of 'ricsim'. Note that the testscript has to read and use the env var `$RIC_SIM_PREFIX` instead of a hardcoded name of the ric(s). |
+| `--use-local-image` | The script will use local images for the supplied apps, space separated list of app short names |
+| `--use-snapshot-image` | The script will use images from the nexus snapshot repo for the supplied apps, space separated list of app short names |
+| `--use-staging-image` | The script will use images from the nexus staging repo for the supplied apps, space separated list of app short names |
+| `--use-release-image` | The script will use images from the nexus release repo for the supplied apps, space separated list of app short names |
+| `help` | Print this info along with the test script description and the list of app short names supported |
## Function: print_result ##
diff --git a/test/common/test_env-onap-guilin.sh b/test/common/test_env-onap-guilin.sh
index 1dc2b36..9b85bf0 100644
--- a/test/common/test_env-onap-guilin.sh
+++ b/test/common/test_env-onap-guilin.sh
@@ -18,64 +18,123 @@
#
#Profile for ONAP guilin release
TEST_ENV_PROFILE="ONAP-GUILIN"
+
+########################################
+## Nexus repo settings
+########################################
+
+# Nexus repos for developed images
NEXUS_PROXY_REPO="nexus3.onap.org:10001/"
+NEXUS_RELEASE_REPO="nexus3.onap.org:10002/"
+NEXUS_SNAPSHOT_REPO="nexus3.onap.org:10003/"
+NEXUS_STAGING_REPO=$NEXUS_SNAPSHOT_REPO #staging repo not used in ONAP, using snapshot
-# Set up the image and tags for the test. Do not add the image tag to the image names.
+# Nexus repos for images used by test (not developed by the project)
+NEXUS_RELEASE_REPO_ORAN="nexus3.o-ran-sc.org:10002/" # Only for released ORAN images
+NEXUS_RELEASE_REPO_ONAP=$NEXUS_RELEASE_REPO
-# NOTE: A env var for each container is created by the test script.
-# This var will point to the local or remote var depending on how
-# the test script is started. The name format is <container-name>_IMAGE, ie with 'LOCAL' or 'REMOTE'.
+########################################
+# Set up of image and tags for the test.
+########################################
-# Tag for guilin branch
-# Remote Policy Agent image and tag
-POLICY_AGENT_REMOTE_IMAGE="nexus3.onap.org:10003/onap/ccsdk-oran-a1policymanagementservice"
-POLICY_AGENT_REMOTE_IMAGE_TAG="1.0.2-SNAPSHOT"
+# NOTE: One environment variable containing the image name and tag is create by the test script
+# for each image from the env variables below.
+# The variable is created by removing the suffix "_BASE" from the base image variable name.
+# Example: POLICY_AGENT_IMAGE_BASE -> POLICY_AGENT_IMAGE
+# This var will point to the local or remote image depending on cmd line arguments.
+# In addition, the repo and the image tag version are selected from the list of image tags based on the cmd line argurment.
+# For images built by the script, only tag #1 shall be specified
+# For project images, only tag #1, #2, #3 and #4 shall be specified
+# For ORAN images (non project), only tag #5 shall be specified
+# For ONAP images (non project), only tag #6 shall be specified
+# For all other images, only tag #7 shall be specified
+# 1 XXX_LOCAL: local images: <image-name>:<local-tag>
+# 2 XXX_REMOTE_SNAPSHOT: snapshot images: <snapshot-nexus-repo><image-name>:<snapshot-tag>
+# 3 XXX_REMOTE: staging images: <staging-nexus-repo><image-name>:<staging-tag>
+# 4 XXX_REMOTE_RELEASE: release images: <release-nexus-repo><image-name>:<release-tag>
+# 5 XXX_REMOTE_RELEASE_ORAN: ORAN release images: <oran-release-nexus-repo><image-name>:<release-tag>
+# 6 XXX_REMOTE_RELEASE_ONAP: ONAP release images: <onap-release-nexus-repo><image-name>:<release-tag>
+# 7 XXX_PROXY: other images, not produced by the project: <proxy-nexus-repo><mage-name>:<proxy-tag>
-# Control Panel remote image and tag
-CONTROL_PANEL_REMOTE_IMAGE="nexus3.o-ran-sc.org:10004/o-ran-sc/nonrtric-controlpanel"
-CONTROL_PANEL_REMOTE_IMAGE_TAG="2.0.0"
+# Policy Agent image and tags
+POLICY_AGENT_IMAGE_BASE="onap/ccsdk-oran-a1policymanagementservice"
+POLICY_AGENT_IMAGE_TAG_LOCAL="1.0.2-SNAPSHOT"
+POLICY_AGENT_IMAGE_TAG_REMOTE_SNAPSHOT="1.0.2-SNAPSHOT"
+POLICY_AGENT_IMAGE_TAG_REMOTE="1.0.2-SNAPSHOT" #Will use snapshot repo
+POLICY_AGENT_IMAGE_TAG_REMOTE_RELEASE="1.0.1"
+
# Tag for guilin branch
# SDNC A1 Controller remote image and tag
-SDNC_A1_CONTROLLER_REMOTE_IMAGE="nexus3.onap.org:10003/onap/sdnc-image"
-SDNC_A1_CONTROLLER_REMOTE_IMAGE_TAG="2.0.2-STAGING-latest"
+SDNC_A1_CONTROLLER_IMAGE_BASE="onap/sdnc-image"
+SDNC_A1_CONTROLLER_IMAGE_TAG_REMOTE_SNAPSHOT="2.0.5-STAGING-latest"
+SDNC_A1_CONTROLLER_IMAGE_TAG_REMOTE="2.0.5-STAGING-latest"
+SDNC_A1_CONTROLLER_IMAGE_TAG_REMOTE_RELEASE="2.0.4" #Will use snapshot repo
#SDNC DB remote image and tag
-SDNC_DB_REMOTE_IMAGE=$NEXUS_PROXY_REPO"mysql/mysql-server"
-SDNC_DB_REMOTE_IMAGE_TAG="5.6"
-#No local image for DB, remote image always used
+#The DB is part of SDNC so handled in the same way as SDNC
+SDNC_DB_IMAGE_BASE="mysql/mysql-server"
+SDNC_DB_IMAGE_TAG_REMOTE_PROXY="5.6"
-# Near RT RIC Simulator remote image and tag
-RIC_SIM_REMOTE_IMAGE="nexus3.o-ran-sc.org:10004/o-ran-sc/a1-simulator"
-RIC_SIM_REMOTE_IMAGE_TAG="2.0.0"
+# Control Panel image and tag - uses bronze release
+CONTROL_PANEL_IMAGE_BASE="o-ran-sc/nonrtric-controlpanel"
+CONTROL_PANEL_IMAGE_TAG_REMOTE_RELEASE_ORAN="2.0.0"
+
+
+# Near RT RIC Simulator image and tags - uses bronze release
+RIC_SIM_IMAGE_BASE="o-ran-sc/a1-simulator"
+RIC_SIM_IMAGE_TAG_REMOTE_RELEASE_ORAN="2.0.0"
#Consul remote image and tag
-CONSUL_REMOTE_IMAGE=$NEXUS_PROXY_REPO"consul"
-CONSUL_REMOTE_IMAGE_TAG="1.7.2"
+CONSUL_IMAGE_BASE="consul"
+CONSUL_IMAGE_TAG_REMOTE_PROXY="1.7.2"
#No local image for Consul, remote image always used
#CBS remote image and tag
-CBS_REMOTE_IMAGE="nexus3.onap.org:10001/onap/org.onap.dcaegen2.platform.configbinding.app-app"
-CBS_REMOTE_IMAGE_TAG="2.3.0"
+CBS_IMAGE_BASE="onap/org.onap.dcaegen2.platform.configbinding.app-app"
+CBS_IMAGE_TAG_REMOTE_RELEASE_ONAP="2.3.0"
#No local image for CBS, remote image always used
#MR stub image and tag
-MRSTUB_LOCAL_IMAGE="mrstub"
-MRSTUB_LOCAL_IMAGE_TAG="latest"
+MRSTUB_IMAGE_BASE="mrstub"
+MRSTUB_IMAGE_TAG_LOCAL="latest"
#No remote image for MR stub, local image always used
+
#Callback receiver image and tag
-CR_LOCAL_IMAGE="callback-receiver"
-CR_LOCAL_IMAGE_TAG="latest"
+CR_IMAGE_BASE="callback-receiver"
+CR_IMAGE_TAG_LOCAL="latest"
#No remote image for CR, local image always used
-# Common env var for auto-test. Vars used by docker-compose need to be exported
+
+#Producer stub image and tag
+PROD_STUB_IMAGE_BASE="producer-stub"
+PROD_STUB_IMAGE_TAG_LOCAL="latest"
+#No remote image for producer stub, local image always used
+
+
+# List of app short names produced by the project
+PROJECT_IMAGES_APP_NAMES="PA SDNC"
+
+# List of app short names which images pulled from ORAN
+ORAN_IMAGES_APP_NAMES="CP RICSIM"
+
+# List of app short names which images pulled from ONAP
+ONAP_IMAGES_APP_NAMES="" # Not used
+
+########################################
+# Detailed settings per app
+########################################
+
+# Vars used by docker-compose need to be exported
+
+
export DOCKER_SIM_NWNAME="nonrtric-docker-net" # Name of docker private network
export POLICY_AGENT_EXTERNAL_PORT=8081 # Policy Agent container external port (host -> container)
@@ -140,6 +199,12 @@
export CONTROL_PANEL_INTERNAL_PORT=8080 # Control Panel container external port (host -> container)
CONTROL_PANEL_LOGPATH="/logs/nonrtric-controlpanel.log" # Path the application log in the Control Panel container
+
+########################################
+# Setting for common curl-base function
+########################################
+
+
UUID="" # UUID used as prefix to the policy id to simulate a real UUID
# Testscript need to set the UUID to use other this empty prefix is used
diff --git a/test/common/test_env-onap-master.sh b/test/common/test_env-onap-honolulu.sh
similarity index 67%
rename from test/common/test_env-onap-master.sh
rename to test/common/test_env-onap-honolulu.sh
index 29647bd..a8c852e 100644
--- a/test/common/test_env-onap-master.sh
+++ b/test/common/test_env-onap-honolulu.sh
@@ -16,84 +16,134 @@
# limitations under the License.
# ============LICENSE_END=================================================
#
-#Profile for ONAP master
-TEST_ENV_PROFILE="ONAP-MASTER"
+#Profile for ONAP honolulu release
+TEST_ENV_PROFILE="ONAP-HONOLULU"
+
+########################################
+## Nexus repo settings
+########################################
+
+# Nexus repos for developed images
NEXUS_PROXY_REPO="nexus3.onap.org:10001/"
+NEXUS_RELEASE_REPO="nexus3.onap.org:10002/"
+NEXUS_SNAPSHOT_REPO="nexus3.onap.org:10003/"
+NEXUS_STAGING_REPO=$NEXUS_SNAPSHOT_REPO #staging repo not used in ONAP, using snapshot
-# Set up the image and tags for the test. Do not add the image tag to the image names.
+# Nexus repos for images used by test (not developed by the project)
+NEXUS_RELEASE_REPO_ORAN="nexus3.o-ran-sc.org:10002/" # Only for released ORAN images
+NEXUS_RELEASE_REPO_ONAP=$NEXUS_RELEASE_REPO
-# NOTE: A env var for each container is created by the test script.
-# This var will point to the local or remote var depending on how
-# the test script is started. The name format is <container-name>_IMAGE, ie with 'LOCAL' or 'REMOTE'.
+########################################
+# Set up of image and tags for the test.
+########################################
-# Local Policy Agent image and tag
-POLICY_AGENT_LOCAL_IMAGE="onap/ccsdk-oran-a1policymanagementservice"
-POLICY_AGENT_LOCAL_IMAGE_TAG="1.1.0-SNAPSHOT"
-# Remote Policy Agent image and tag
-POLICY_AGENT_REMOTE_IMAGE="nexus3.onap.org:10003/onap/ccsdk-oran-a1policymanagementservice"
-POLICY_AGENT_REMOTE_IMAGE_TAG="1.1.0-SNAPSHOT"
+# NOTE: One environment variable containing the image name and tag is create by the test script
+# for each image from the env variables below.
+# The variable is created by removing the suffix "_BASE" from the base image variable name.
+# Example: POLICY_AGENT_IMAGE_BASE -> POLICY_AGENT_IMAGE
+# This var will point to the local or remote image depending on cmd line arguments.
+# In addition, the repo and the image tag version are selected from the list of image tags based on the cmd line argurment.
+# For images built by the script, only tag #1 shall be specified
+# For project images, only tag #1, #2, #3 and #4 shall be specified
+# For ORAN images (non project), only tag #5 shall be specified
+# For ONAP images (non project), only tag #6 shall be specified
+# For all other images, only tag #7 shall be specified
+# 1 XXX_LOCAL: local images: <image-name>:<local-tag>
+# 2 XXX_REMOTE_SNAPSHOT: snapshot images: <snapshot-nexus-repo><image-name>:<snapshot-tag>
+# 3 XXX_REMOTE: staging images: <staging-nexus-repo><image-name>:<staging-tag>
+# 4 XXX_REMOTE_RELEASE: release images: <release-nexus-repo><image-name>:<release-tag>
+# 5 XXX_REMOTE_RELEASE_ORAN: ORAN release images: <oran-release-nexus-repo><image-name>:<release-tag>
+# 6 XXX_REMOTE_RELEASE_ONAP: ONAP release images: <onap-release-nexus-repo><image-name>:<release-tag>
+# 7 XXX_PROXY: other images, not produced by the project: <proxy-nexus-repo><mage-name>:<proxy-tag>
-# Local ECS image and tag
-ECS_LOCAL_IMAGE="o-ran-sc/nonrtric-enrichment-coordinator-service"
-ECS_LOCAL_IMAGE_TAG="1.0.0-SNAPSHOT"
-# Remote ECS image and tag
-ECS_REMOTE_IMAGE="nexus3.o-ran-sc.org:10003/o-ran-sc/nonrtric-enrichment-coordinator-service"
-ECS_REMOTE_IMAGE_TAG="1.0.0-SNAPSHOT"
-
-# Control Panel local image and tag
-CONTROL_PANEL_LOCAL_IMAGE="o-ran-sc/nonrtric-controlpanel"
-CONTROL_PANEL_LOCAL_IMAGE_TAG="2.0.0-SNAPSHOT"
-# Control Panel remote image and tag
-CONTROL_PANEL_REMOTE_IMAGE="nexus3.o-ran-sc.org:10004/o-ran-sc/nonrtric-controlpanel"
-CONTROL_PANEL_REMOTE_IMAGE_TAG="2.0.0"
+# Policy Agent image and tags
+POLICY_AGENT_IMAGE_BASE="onap/ccsdk-oran-a1policymanagementservice"
+POLICY_AGENT_IMAGE_TAG_LOCAL="1.1.1-SNAPSHOT"
+POLICY_AGENT_IMAGE_TAG_REMOTE_SNAPSHOT="1.1.1-SNAPSHOT"
+POLICY_AGENT_IMAGE_TAG_REMOTE="1.1.1-SNAPSHOT" #Will use snapshot repo
+POLICY_AGENT_IMAGE_TAG_REMOTE_RELEASE="1.1.1"
# SDNC A1 Controller remote image and tag
-SDNC_A1_CONTROLLER_REMOTE_IMAGE="nexus3.onap.org:10003/onap/sdnc-image"
-SDNC_A1_CONTROLLER_REMOTE_IMAGE_TAG="2.1.0-STAGING-latest"
-
+SDNC_A1_CONTROLLER_IMAGE_BASE="onap/sdnc-image"
+SDNC_A1_CONTROLLER_IMAGE_TAG_LOCAL="2.1.1-SNAPSHOT" ###CHECK THIS
+SDNC_A1_CONTROLLER_IMAGE_TAG_REMOTE_SNAPSHOT="2.1.1-STAGING-latest"
+SDNC_A1_CONTROLLER_IMAGE_TAG_REMOTE="2.1.1-STAGING-latest" #Will use snapshot repo
+SDNC_A1_CONTROLLER_IMAGE_TAG_REMOTE_RELEASE="2.1.1"
#SDNC DB remote image and tag
-SDNC_DB_REMOTE_IMAGE=$NEXUS_PROXY_REPO"mysql/mysql-server"
-SDNC_DB_REMOTE_IMAGE_TAG="5.6"
-#No local image for DB, remote image always used
+#The DB is part of SDNC so handled in the same way as SDNC
+SDNC_DB_IMAGE_BASE="mysql/mysql-server"
+SDNC_DB_IMAGE_TAG_REMOTE_PROXY="5.6"
-# Near RT RIC Simulator local image and tag
-RIC_SIM_LOCAL_IMAGE="o-ran-sc/a1-simulator"
-RIC_SIM_LOCAL_IMAGE_TAG="latest"
-# Near RT RIC Simulator remote image and tag
-RIC_SIM_REMOTE_IMAGE="nexus3.o-ran-sc.org:10004/o-ran-sc/a1-simulator"
-RIC_SIM_REMOTE_IMAGE_TAG="2.1.0"
+
+# ECS image and tag - uses cherry release
+ECS_IMAGE_BASE="o-ran-sc/nonrtric-enrichment-coordinator-service"
+ECS_IMAGE_TAG_REMOTE_RELEASE_ORAN="1.0.0"
+
+
+# Control Panel image and tag - uses cherry release
+CONTROL_PANEL_IMAGE_BASE="o-ran-sc/nonrtric-controlpanel"
+CONTROL_PANEL_IMAGE_TAG_REMOTE_RELEASE_ORAN="2.1.0"
+
+
+# RAPP Catalogue image and tags - uses cherry release
+RAPP_CAT_IMAGE_BASE="o-ran-sc/nonrtric-r-app-catalogue"
+RAPP_CAT_IMAGE_TAG_REMOTE_RELEASE_ORAN="1.0.0"
+
+
+# Near RT RIC Simulator image and tags - uses cherry release
+RIC_SIM_IMAGE_BASE="o-ran-sc/a1-simulator"
+RIC_SIM_IMAGE_TAG_REMOTE_RELEASE_ORAN="2.1.0"
#Consul remote image and tag
-CONSUL_REMOTE_IMAGE=$NEXUS_PROXY_REPO"consul"
-CONSUL_REMOTE_IMAGE_TAG="1.7.2"
+CONSUL_IMAGE_BASE="consul"
+CONSUL_IMAGE_TAG_REMOTE_PROXY="1.7.2"
#No local image for Consul, remote image always used
#CBS remote image and tag
-CBS_REMOTE_IMAGE="nexus3.onap.org:10001/onap/org.onap.dcaegen2.platform.configbinding.app-app"
-CBS_REMOTE_IMAGE_TAG="2.3.0"
+CBS_IMAGE_BASE="onap/org.onap.dcaegen2.platform.configbinding.app-app"
+CBS_IMAGE_TAG_REMOTE_RELEASE_ONAP="2.3.0"
#No local image for CBS, remote image always used
#MR stub image and tag
-MRSTUB_LOCAL_IMAGE="mrstub"
-MRSTUB_LOCAL_IMAGE_TAG="latest"
+MRSTUB_IMAGE_BASE="mrstub"
+MRSTUB_IMAGE_TAG_LOCAL="latest"
#No remote image for MR stub, local image always used
+
#Callback receiver image and tag
-CR_LOCAL_IMAGE="callback-receiver"
-CR_LOCAL_IMAGE_TAG="latest"
+CR_IMAGE_BASE="callback-receiver"
+CR_IMAGE_TAG_LOCAL="latest"
#No remote image for CR, local image always used
+
#Producer stub image and tag
-PROD_STUB_LOCAL_IMAGE="producer-stub"
-PROD_STUB_LOCAL_IMAGE_TAG="latest"
+PROD_STUB_IMAGE_BASE="producer-stub"
+PROD_STUB_IMAGE_TAG_LOCAL="latest"
#No remote image for producer stub, local image always used
-# Common env var for auto-test. Vars used by docker-compose need to be exported
+
+# List of app short names produced by the project
+PROJECT_IMAGES_APP_NAMES="PA SDNC"
+
+# List of app short names which images pulled from ORAN
+ORAN_IMAGES_APP_NAMES="CP ECS RICSIM RC"
+
+# List of app short names which images pulled from ONAP
+ONAP_IMAGES_APP_NAMES="" # Not used
+
+
+########################################
+# Detailed settings per app
+########################################
+
+# Vars used by docker-compose need to be exported
+
+
export DOCKER_SIM_NWNAME="nonrtric-docker-net" # Name of docker private network
export POLICY_AGENT_EXTERNAL_PORT=8081 # Policy Agent container external port (host -> container)
@@ -171,12 +221,22 @@
SDNC_ALIVE_URL="/apidoc/explorer/" # Base url path for SNDC API docs (for alive check)
SDNC_KARAF_LOG="/opt/opendaylight/data/log/karaf.log" # Path to karaf log
+export RAPP_CAT_APP_NAME="rapp-catalogue" # Name for the RAPP Catalogue
+export RAPP_CAT_EXTERNAL_PORT=8680 # RAPP Catalogue container external port (host -> container)
+export RAPP_CAT_INTERNAL_PORT=8080 # RAPP Catalogue container internal port (container -> container)
+export RAPP_CAT_EXTERNAL_SECURE_PORT=8633 # RAPP Catalogue container external secure port (host -> container)
+export RAPP_CAT_INTERNAL_SECURE_PORT=8433 # RAPP Catalogue container internal secure port (container -> container)
export CONTROL_PANEL_APP_NAME="control-panel" # Name of the Control Panel container
export CONTROL_PANEL_EXTERNAL_PORT=8080 # Control Panel container external port (host -> container)
export CONTROL_PANEL_INTERNAL_PORT=8080 # Control Panel container external port (host -> container)
CONTROL_PANEL_LOGPATH="/logs/nonrtric-controlpanel.log" # Path the application log in the Control Panel container
+
+########################################
+# Setting for common curl-base function
+########################################
+
UUID="" # UUID used as prefix to the policy id to simulate a real UUID
# Testscript need to set the UUID to use other this empty prefix is used
@@ -198,4 +258,8 @@
CR_RESTBASE="http://localhost:"$CR_EXTERNAL_PORT # Base url to the Callback receiver REST interface
CR_RESTBASE_SECURE="https://localhost:"$CR_EXTERNAL_SECURE_PORT # Base url to the secure Callback receiver REST interface
CR_ADAPTER=$CR_RESTBASE # Adapter holds the address the CR admin interface (REST only)
- # The values of this var is swiched between the two base url when needed
\ No newline at end of file
+ # The values of this var is swiched between the two base url when needed
+
+RC_RESTBASE="http://localhost:"$RAPP_CAT_EXTERNAL_PORT # Base url to the RAPP Catalogue REST interface
+RC_RESTBASE_SECURE="https://localhost:"$RAPP_CAT_EXTERNAL_SECURE_PORT # Base url to the secure RAPP Catalogue REST interface
+RC_ADAPTER=$RC_RESTBASE # Adapter holds the address the RAPP Catalogue interface
\ No newline at end of file
diff --git a/test/common/test_env-oran-cherry.sh b/test/common/test_env-oran-cherry.sh
index 4650768..a0f8871 100755
--- a/test/common/test_env-oran-cherry.sh
+++ b/test/common/test_env-oran-cherry.sh
@@ -18,94 +18,144 @@
#
#Profile for ORAN Cherry
TEST_ENV_PROFILE="ORAN-CHERRY"
-NEXUS_PROXY_REPO="nexus3.onap.org:10001/"
-# Set up the image and tags for the test. Do not add the image tag to the image names.
+########################################
+## Nexus repo settings
+########################################
-# NOTE: A env var for each container is created by the test script.
-# This var will point to the local or remote var depending on how
-# the test script is started. The name format is <container-name>_IMAGE, ie with 'LOCAL' or 'REMOTE'.
+# Nexus repos for developed images
+NEXUS_PROXY_REPO="nexus3.o-ran-sc.org:10001/"
+NEXUS_RELEASE_REPO="nexus3.o-ran-sc.org:10002/"
+NEXUS_SNAPSHOT_REPO="nexus3.o-ran-sc.org:10003/"
+NEXUS_STAGING_REPO="nexus3.o-ran-sc.org:10004/"
-# Local Policy Agent image and tag
-POLICY_AGENT_LOCAL_IMAGE="o-ran-sc/nonrtric-policy-agent"
-POLICY_AGENT_LOCAL_IMAGE_TAG="2.1.0-SNAPSHOT"
-# Remote Policy Agent image and tag
-POLICY_AGENT_REMOTE_IMAGE="nexus3.o-ran-sc.org:10004/o-ran-sc/nonrtric-policy-agent"
-POLICY_AGENT_REMOTE_IMAGE_TAG="2.1.0"
+# Nexus repos for images used by test (not developed by the project)
+NEXUS_RELEASE_REPO_ONAP="nexus3.onap.org:10002/" # Only for released ONAP images
+NEXUS_RELEASE_REPO_ORAN=$NEXUS_RELEASE_REPO
-# Local ECS image and tag
-ECS_LOCAL_IMAGE="o-ran-sc/nonrtric-enrichment-coordinator-service"
-ECS_LOCAL_IMAGE_TAG="1.0.0-SNAPSHOT"
-# Remote ECS image and tag
-ECS_REMOTE_IMAGE="nexus3.o-ran-sc.org:10004/o-ran-sc/nonrtric-enrichment-coordinator-service"
-ECS_REMOTE_IMAGE_TAG="1.0.0"
+########################################
+# Set up of image and tags for the test.
+########################################
-# Control Panel local image and tag
-CONTROL_PANEL_LOCAL_IMAGE="o-ran-sc/nonrtric-controlpanel"
-CONTROL_PANEL_LOCAL_IMAGE_TAG="2.0.0-SNAPSHOT"
-# Control Panel remote image and tag
-CONTROL_PANEL_REMOTE_IMAGE="nexus3.o-ran-sc.org:10004/o-ran-sc/nonrtric-controlpanel"
-CONTROL_PANEL_REMOTE_IMAGE_TAG="2.0.0"
+# NOTE: One environment variable containing the image name and tag is create by the test script
+# for each image from the env variables below.
+# The variable is created by removing the suffix "_BASE" from the base image variable name.
+# Example: POLICY_AGENT_IMAGE_BASE -> POLICY_AGENT_IMAGE
+# This var will point to the local or remote image depending on cmd line arguments.
+# In addition, the repo and the image tag version are selected from the list of image tags based on the cmd line argurment.
+# For images built by the script, only tag #1 shall be specified
+# For project images, only tag #1, #2, #3 and #4 shall be specified
+# For ORAN images (non project), only tag #5 shall be specified
+# For ONAP images (non project), only tag #6 shall be specified
+# For all other images, only tag #7 shall be specified
+# 1 XXX_LOCAL: local images: <image-name>:<local-tag>
+# 2 XXX_REMOTE_SNAPSHOT: snapshot images: <snapshot-nexus-repo><image-name>:<snapshot-tag>
+# 3 XXX_REMOTE: staging images: <staging-nexus-repo><image-name>:<staging-tag>
+# 4 XXX_REMOTE_RELEASE: release images: <release-nexus-repo><image-name>:<release-tag>
+# 5 XXX_REMOTE_RELEASE_ORAN: ORAN release images: <oran-release-nexus-repo><image-name>:<release-tag>
+# 6 XXX_REMOTE_RELEASE_ONAP: ONAP release images: <onap-release-nexus-repo><image-name>:<release-tag>
+# 7 XXX_PROXY: other images, not produced by the project: <proxy-nexus-repo><mage-name>:<proxy-tag>
-# SDNC A1 Controller local image and tag
-SDNC_A1_CONTROLLER_LOCAL_IMAGE="o-ran-sc/nonrtric-a1-controller"
-SDNC_A1_CONTROLLER_LOCAL_IMAGE_TAG="2.1.0-SNAPSHOT"
-# SDNC A1 Controller remote image and tag
-SDNC_A1_CONTROLLER_REMOTE_IMAGE="nexus3.o-ran-sc.org:10004/o-ran-sc/nonrtric-a1-controller"
-SDNC_A1_CONTROLLER_REMOTE_IMAGE_TAG="2.1.0"
+# Policy Agent base image and tags
+POLICY_AGENT_IMAGE_BASE="o-ran-sc/nonrtric-policy-agent"
+POLICY_AGENT_IMAGE_TAG_LOCAL="2.1.0-SNAPSHOT"
+POLICY_AGENT_IMAGE_TAG_REMOTE_SNAPSHOT="2.1.0-SNAPSHOT"
+POLICY_AGENT_IMAGE_TAG_REMOTE="2.1.0"
+POLICY_AGENT_IMAGE_TAG_REMOTE_RELEASE="2.1.0"
+
+# ECS image and tags
+ECS_IMAGE_BASE="o-ran-sc/nonrtric-enrichment-coordinator-service"
+ECS_IMAGE_TAG_LOCAL="1.0.0-SNAPSHOT"
+ECS_IMAGE_TAG_REMOTE_SNAPSHOT="1.0.0-SNAPSHOT"
+ECS_IMAGE_TAG_REMOTE="1.0.0"
+ECS_IMAGE_TAG_REMOTE_RELEASE="1.0.0"
-# RAPP Catalogue local image and tag
-RAPP_CAT_LOCAL_IMAGE="o-ran-sc/nonrtric-r-app-catalogue"
-RAPP_CAT_LOCAL_IMAGE_TAG="1.0.0-SNAPSHOT"
-# RAPP Catalogue remote image and tag
-RAPP_CAT_REMOTE_IMAGE="nexus3.o-ran-sc.org:10004/o-ran-sc/nonrtric-r-app-catalogue"
-RAPP_CAT_REMOTE_IMAGE_TAG="1.0.0"
+# Control Panel image and tags
+CONTROL_PANEL_IMAGE_BASE="o-ran-sc/nonrtric-controlpanel"
+CONTROL_PANEL_IMAGE_TAG_LOCAL="2.1.0-SNAPSHOT"
+CONTROL_PANEL_IMAGE_TAG_REMOTE_SNAPSHOT="2.1.0-SNAPSHOT"
+CONTROL_PANEL_IMAGE_TAG_REMOTE="2.1.0"
+CONTROL_PANEL_IMAGE_TAG_REMOTE_RELEASE="2.1.0"
+
+
+# SDNC A1 Controller image and tags
+SDNC_A1_CONTROLLER_IMAGE_BASE="o-ran-sc/nonrtric-a1-controller"
+SDNC_A1_CONTROLLER_IMAGE_TAG_LOCAL="2.0.1-SNAPSHOT"
+SDNC_A1_CONTROLLER_IMAGE_TAG_REMOTE_SNAPSHOT="2.0.1-SNAPSHOT"
+SDNC_A1_CONTROLLER_IMAGE_TAG_REMOTE="2.0.1"
+SDNC_A1_CONTROLLER_IMAGE_TAG_REMOTE_RELEASE="2.0.1"
#SDNC DB remote image and tag
-SDNC_DB_REMOTE_IMAGE=$NEXUS_PROXY_REPO"mysql/mysql-server"
-SDNC_DB_REMOTE_IMAGE_TAG="5.6"
-#No local image for DB, remote image always used
+SDNC_DB_IMAGE_BASE="mysql/mysql-server"
+SDNC_DB_IMAGE_TAG_REMOTE_PROXY="5.6"
+#No local image for SSDNC DB, remote image always used
-# Near RT RIC Simulator local image and tag
-RIC_SIM_LOCAL_IMAGE="o-ran-sc/a1-simulator"
-RIC_SIM_LOCAL_IMAGE_TAG="latest"
-# Near RT RIC Simulator remote image and tag
-RIC_SIM_REMOTE_IMAGE="nexus3.o-ran-sc.org:10004/o-ran-sc/a1-simulator"
-RIC_SIM_REMOTE_IMAGE_TAG="2.1.0"
+# RAPP Catalogue image and tags
+RAPP_CAT_IMAGE_BASE="o-ran-sc/nonrtric-r-app-catalogue"
+RAPP_CAT_IMAGE_TAG_LOCAL="1.0.0-SNAPSHOT"
+RAPP_CAT_IMAGE_TAG_REMOTE_SNAPSHOT="1.0.0-SNAPSHOT"
+RAPP_CAT_IMAGE_TAG_REMOTE="1.0.0"
+RAPP_CAT_IMAGE_TAG_REMOTE_RELEASE="1.0.0"
+
+
+# Near RT RIC Simulator image and tags
+RIC_SIM_IMAGE_BASE="o-ran-sc/a1-simulator"
+RIC_SIM_IMAGE_TAG_LOCAL="latest"
+RIC_SIM_IMAGE_TAG_REMOTE_SNAPSHOT="2.1.0-SNAPSHOT"
+RIC_SIM_IMAGE_TAG_REMOTE="2.1.0"
+RIC_SIM_IMAGE_TAG_REMOTE_RELEASE="2.1.0"
#Consul remote image and tag
-CONSUL_REMOTE_IMAGE=$NEXUS_PROXY_REPO"consul"
-CONSUL_REMOTE_IMAGE_TAG="1.7.2"
+CONSUL_IMAGE_BASE="consul"
+CONSUL_IMAGE_TAG_REMOTE_PROXY="1.7.2"
#No local image for Consul, remote image always used
#CBS remote image and tag
-CBS_REMOTE_IMAGE="nexus3.onap.org:10001/onap/org.onap.dcaegen2.platform.configbinding.app-app"
-CBS_REMOTE_IMAGE_TAG="2.3.0"
+CBS_IMAGE_BASE="onap/org.onap.dcaegen2.platform.configbinding.app-app"
+CBS_IMAGE_TAG_REMOTE_RELEASE_ONAP="2.3.0"
#No local image for CBS, remote image always used
#MR stub image and tag
-MRSTUB_LOCAL_IMAGE="mrstub"
-MRSTUB_LOCAL_IMAGE_TAG="latest"
+MRSTUB_IMAGE_BASE="mrstub"
+MRSTUB_IMAGE_TAG_LOCAL="latest"
#No remote image for MR stub, local image always used
+
#Callback receiver image and tag
-CR_LOCAL_IMAGE="callback-receiver"
-CR_LOCAL_IMAGE_TAG="latest"
+CR_IMAGE_BASE="callback-receiver"
+CR_IMAGE_TAG_LOCAL="latest"
#No remote image for CR, local image always used
+
#Producer stub image and tag
-PROD_STUB_LOCAL_IMAGE="producer-stub"
-PROD_STUB_LOCAL_IMAGE_TAG="latest"
+PROD_STUB_IMAGE_BASE="producer-stub"
+PROD_STUB_IMAGE_TAG_LOCAL="latest"
#No remote image for producer stub, local image always used
-# Common env var for auto-test. Vars used by docker-compose need to be exported
+
+# List of app short names produced by the project
+PROJECT_IMAGES_APP_NAMES="PA ECS CP SDNC RC RICSIM"
+
+# List of app short names which images pulled from ORAN
+ORAN_IMAGES_APP_NAMES="" # Not used
+
+# List of app short names which images pulled from ONAP
+ONAP_IMAGES_APP_NAMES="CBS"
+
+
+########################################
+# Detailed settings per app
+########################################
+
+# Vars used by docker-compose need to be exported
+
export DOCKER_SIM_NWNAME="nonrtric-docker-net" # Name of docker private network
export POLICY_AGENT_EXTERNAL_PORT=8081 # Policy Agent container external port (host -> container)
@@ -183,11 +233,11 @@
SDNC_ALIVE_URL="/apidoc/explorer/" # Base url path for SNDC API docs (for alive check)
SDNC_KARAF_LOG="/opt/opendaylight/data/log/karaf.log" # Path to karaf log
+export RAPP_CAT_APP_NAME="rapp-catalogue" # Name for the RAPP Catalogue
export RAPP_CAT_EXTERNAL_PORT=8680 # RAPP Catalogue container external port (host -> container)
export RAPP_CAT_INTERNAL_PORT=8080 # RAPP Catalogue container internal port (container -> container)
export RAPP_CAT_EXTERNAL_SECURE_PORT=8633 # RAPP Catalogue container external secure port (host -> container)
export RAPP_CAT_INTERNAL_SECURE_PORT=8433 # RAPP Catalogue container internal secure port (container -> container)
-export RAPP_CAT_APP_NAME="rapp-catalogue" # Name for the RAPP Catalogue
export CONTROL_PANEL_APP_NAME="control-panel" # Name of the Control Panel container
@@ -195,6 +245,11 @@
export CONTROL_PANEL_INTERNAL_PORT=8080 # Control Panel container external port (host -> container)
CONTROL_PANEL_LOGPATH="/logs/nonrtric-controlpanel.log" # Path the application log in the Control Panel container
+
+########################################
+# Setting for common curl-base function
+########################################
+
UUID="" # UUID used as prefix to the policy id to simulate a real UUID
# Testscript need to set the UUID otherwise this empty prefix is used
diff --git a/test/common/test_env-onap-master.sh b/test/common/test_env-oran-dawn.sh
old mode 100644
new mode 100755
similarity index 65%
copy from test/common/test_env-onap-master.sh
copy to test/common/test_env-oran-dawn.sh
index 29647bd..637e5c1
--- a/test/common/test_env-onap-master.sh
+++ b/test/common/test_env-oran-dawn.sh
@@ -16,83 +16,144 @@
# limitations under the License.
# ============LICENSE_END=================================================
#
-#Profile for ONAP master
-TEST_ENV_PROFILE="ONAP-MASTER"
-NEXUS_PROXY_REPO="nexus3.onap.org:10001/"
+#Profile for ORAN Cherry
+TEST_ENV_PROFILE="ORAN-DAWN"
-# Set up the image and tags for the test. Do not add the image tag to the image names.
+########################################
+## Nexus repo settings
+########################################
-# NOTE: A env var for each container is created by the test script.
-# This var will point to the local or remote var depending on how
-# the test script is started. The name format is <container-name>_IMAGE, ie with 'LOCAL' or 'REMOTE'.
+# Nexus repos for developed images
+NEXUS_PROXY_REPO="nexus3.o-ran-sc.org:10001/"
+NEXUS_RELEASE_REPO="nexus3.o-ran-sc.org:10002/"
+NEXUS_SNAPSHOT_REPO="nexus3.o-ran-sc.org:10003/"
+NEXUS_STAGING_REPO="nexus3.o-ran-sc.org:10004/"
-# Local Policy Agent image and tag
-POLICY_AGENT_LOCAL_IMAGE="onap/ccsdk-oran-a1policymanagementservice"
-POLICY_AGENT_LOCAL_IMAGE_TAG="1.1.0-SNAPSHOT"
-# Remote Policy Agent image and tag
-POLICY_AGENT_REMOTE_IMAGE="nexus3.onap.org:10003/onap/ccsdk-oran-a1policymanagementservice"
-POLICY_AGENT_REMOTE_IMAGE_TAG="1.1.0-SNAPSHOT"
+# Nexus repos for images used by test (not developed by the project)
+NEXUS_RELEASE_REPO_ONAP="nexus3.onap.org:10002/" # Only for released ONAP images
+NEXUS_RELEASE_REPO_ORAN=$NEXUS_RELEASE_REPO
-# Local ECS image and tag
-ECS_LOCAL_IMAGE="o-ran-sc/nonrtric-enrichment-coordinator-service"
-ECS_LOCAL_IMAGE_TAG="1.0.0-SNAPSHOT"
-# Remote ECS image and tag
-ECS_REMOTE_IMAGE="nexus3.o-ran-sc.org:10003/o-ran-sc/nonrtric-enrichment-coordinator-service"
-ECS_REMOTE_IMAGE_TAG="1.0.0-SNAPSHOT"
+########################################
+# Set up of image and tags for the test.
+########################################
-# Control Panel local image and tag
-CONTROL_PANEL_LOCAL_IMAGE="o-ran-sc/nonrtric-controlpanel"
-CONTROL_PANEL_LOCAL_IMAGE_TAG="2.0.0-SNAPSHOT"
-# Control Panel remote image and tag
-CONTROL_PANEL_REMOTE_IMAGE="nexus3.o-ran-sc.org:10004/o-ran-sc/nonrtric-controlpanel"
-CONTROL_PANEL_REMOTE_IMAGE_TAG="2.0.0"
+# NOTE: One environment variable containing the image name and tag is create by the test script
+# for each image from the env variables below.
+# The variable is created by removing the suffix "_BASE" from the base image variable name.
+# Example: POLICY_AGENT_IMAGE_BASE -> POLICY_AGENT_IMAGE
+# This var will point to the local or remote image depending on cmd line arguments.
+# In addition, the repo and the image tag version are selected from the list of image tags based on the cmd line argurment.
+# For images built by the script, only tag #1 shall be specified
+# For project images, only tag #1, #2, #3 and #4 shall be specified
+# For ORAN images (non project), only tag #5 shall be specified
+# For ONAP images (non project), only tag #6 shall be specified
+# For all other images, only tag #7 shall be specified
+# 1 XXX_LOCAL: local images: <image-name>:<local-tag>
+# 2 XXX_REMOTE_SNAPSHOT: snapshot images: <snapshot-nexus-repo><image-name>:<snapshot-tag>
+# 3 XXX_REMOTE: staging images: <staging-nexus-repo><image-name>:<staging-tag>
+# 4 XXX_REMOTE_RELEASE: release images: <release-nexus-repo><image-name>:<release-tag>
+# 5 XXX_REMOTE_RELEASE_ORAN: ORAN release images: <oran-release-nexus-repo><image-name>:<release-tag>
+# 6 XXX_REMOTE_RELEASE_ONAP: ONAP release images: <onap-release-nexus-repo><image-name>:<release-tag>
+# 7 XXX_PROXY: other images, not produced by the project: <proxy-nexus-repo><mage-name>:<proxy-tag>
-# SDNC A1 Controller remote image and tag
-SDNC_A1_CONTROLLER_REMOTE_IMAGE="nexus3.onap.org:10003/onap/sdnc-image"
-SDNC_A1_CONTROLLER_REMOTE_IMAGE_TAG="2.1.0-STAGING-latest"
+# Policy Agent base image and tags
+POLICY_AGENT_IMAGE_BASE="o-ran-sc/nonrtric-policy-agent"
+POLICY_AGENT_IMAGE_TAG_LOCAL="2.2.0-SNAPSHOT"
+POLICY_AGENT_IMAGE_TAG_REMOTE_SNAPSHOT="2.2.0-SNAPSHOT"
+POLICY_AGENT_IMAGE_TAG_REMOTE="2.2.0"
+POLICY_AGENT_IMAGE_TAG_REMOTE_RELEASE="2.2.0"
+
+# ECS image and tags
+ECS_IMAGE_BASE="o-ran-sc/nonrtric-enrichment-coordinator-service"
+ECS_IMAGE_TAG_LOCAL="1.1.0-SNAPSHOT"
+ECS_IMAGE_TAG_REMOTE_SNAPSHOT="1.1.0-SNAPSHOT"
+ECS_IMAGE_TAG_REMOTE="1.1.0"
+ECS_IMAGE_TAG_REMOTE_RELEASE="1.1.0"
+
+
+# Control Panel image and tags
+CONTROL_PANEL_IMAGE_BASE="o-ran-sc/nonrtric-controlpanel"
+CONTROL_PANEL_IMAGE_TAG_LOCAL="2.2.0-SNAPSHOT"
+CONTROL_PANEL_IMAGE_TAG_REMOTE_SNAPSHOT="2.2.0-SNAPSHOT"
+CONTROL_PANEL_IMAGE_TAG_REMOTE="2.2.0"
+CONTROL_PANEL_IMAGE_TAG_REMOTE_RELEASE="2.2.0"
+
+
+# SDNC A1 Controller image and tags
+SDNC_A1_CONTROLLER_IMAGE_BASE="o-ran-sc/nonrtric-a1-controller"
+SDNC_A1_CONTROLLER_IMAGE_TAG_LOCAL="2.1.0-SNAPSHOT"
+SDNC_A1_CONTROLLER_IMAGE_TAG_REMOTE_SNAPSHOT="2.1.0-SNAPSHOT"
+SDNC_A1_CONTROLLER_IMAGE_TAG_REMOTE="2.1.0"
+SDNC_A1_CONTROLLER_IMAGE_TAG_REMOTE_RELEASE="2.1.0"
#SDNC DB remote image and tag
-SDNC_DB_REMOTE_IMAGE=$NEXUS_PROXY_REPO"mysql/mysql-server"
-SDNC_DB_REMOTE_IMAGE_TAG="5.6"
-#No local image for DB, remote image always used
+SDNC_DB_IMAGE_BASE="mysql/mysql-server"
+SDNC_DB_IMAGE_TAG_REMOTE_PROXY="5.6"
+#No local image for SSDNC DB, remote image always used
-# Near RT RIC Simulator local image and tag
-RIC_SIM_LOCAL_IMAGE="o-ran-sc/a1-simulator"
-RIC_SIM_LOCAL_IMAGE_TAG="latest"
-# Near RT RIC Simulator remote image and tag
-RIC_SIM_REMOTE_IMAGE="nexus3.o-ran-sc.org:10004/o-ran-sc/a1-simulator"
-RIC_SIM_REMOTE_IMAGE_TAG="2.1.0"
+
+# RAPP Catalogue image and tags
+RAPP_CAT_IMAGE_BASE="o-ran-sc/nonrtric-r-app-catalogue"
+RAPP_CAT_IMAGE_TAG_LOCAL="1.1.0-SNAPSHOT"
+RAPP_CAT_IMAGE_TAG_REMOTE_SNAPSHOT="1.1.0-SNAPSHOT"
+RAPP_CAT_IMAGE_TAG_REMOTE="1.1.0"
+RAPP_CAT_IMAGE_TAG_REMOTE_RELEASE="1.1.0"
+
+
+# Near RT RIC Simulator image and tags
+RIC_SIM_IMAGE_BASE="o-ran-sc/a1-simulator"
+RIC_SIM_IMAGE_TAG_LOCAL="latest"
+RIC_SIM_IMAGE_TAG_REMOTE_SNAPSHOT="2.1.0-SNAPSHOT"
+RIC_SIM_IMAGE_TAG_REMOTE="2.1.0"
+RIC_SIM_IMAGE_TAG_REMOTE_RELEASE="2.1.0"
#Consul remote image and tag
-CONSUL_REMOTE_IMAGE=$NEXUS_PROXY_REPO"consul"
-CONSUL_REMOTE_IMAGE_TAG="1.7.2"
+CONSUL_IMAGE_BASE="consul"
+CONSUL_IMAGE_TAG_REMOTE_PROXY="1.7.2"
#No local image for Consul, remote image always used
#CBS remote image and tag
-CBS_REMOTE_IMAGE="nexus3.onap.org:10001/onap/org.onap.dcaegen2.platform.configbinding.app-app"
-CBS_REMOTE_IMAGE_TAG="2.3.0"
+CBS_IMAGE_BASE="onap/org.onap.dcaegen2.platform.configbinding.app-app"
+CBS_IMAGE_TAG_REMOTE_RELEASE_ONAP="2.3.0"
#No local image for CBS, remote image always used
#MR stub image and tag
-MRSTUB_LOCAL_IMAGE="mrstub"
-MRSTUB_LOCAL_IMAGE_TAG="latest"
+MRSTUB_IMAGE_BASE="mrstub"
+MRSTUB_IMAGE_TAG_LOCAL="latest"
#No remote image for MR stub, local image always used
+
#Callback receiver image and tag
-CR_LOCAL_IMAGE="callback-receiver"
-CR_LOCAL_IMAGE_TAG="latest"
+CR_IMAGE_BASE="callback-receiver"
+CR_IMAGE_TAG_LOCAL="latest"
#No remote image for CR, local image always used
+
#Producer stub image and tag
-PROD_STUB_LOCAL_IMAGE="producer-stub"
-PROD_STUB_LOCAL_IMAGE_TAG="latest"
+PROD_STUB_IMAGE_BASE="producer-stub"
+PROD_STUB_IMAGE_TAG_LOCAL="latest"
#No remote image for producer stub, local image always used
+
+# List of app short names produced by the project
+PROJECT_IMAGES_APP_NAMES="PA ECS CP SDNC RC RICSIM"
+
+# List of app short names which images pulled from ORAN
+ORAN_IMAGES_APP_NAMES="" # Not used
+
+# List of app short names which images pulled from ONAP
+ONAP_IMAGES_APP_NAMES="CBS"
+
+
+########################################
+# Detailed settings per app
+########################################
+
# Common env var for auto-test. Vars used by docker-compose need to be exported
export DOCKER_SIM_NWNAME="nonrtric-docker-net" # Name of docker private network
@@ -164,28 +225,38 @@
export SDNC_EXTERNAL_SECURE_PORT=8443 # SNDC A1 Controller container external securee port (host -> container)
export SDNC_INTERNAL_SECURE_PORT=8443 # SNDC A1 Controller container internal secure port (container -> container)
export SDNC_DB_APP_NAME="sdnc-db" # Name of the SDNC DB container
-export SDNC_A1_TRUSTSTORE_PASSWORD="a1adapter" # SDNC truststore password
+export SDNC_A1_TRUSTSTORE_PASSWORD="" # SDNC truststore password
SDNC_USER="admin" # SDNC username
SDNC_PWD="Kp8bJ4SXszM0WXlhak3eHlcse2gAw84vaoGGmJvUy2U" # SNDC PWD
SDNC_API_URL="/restconf/operations/A1-ADAPTER-API:" # Base url path for SNDC API
SDNC_ALIVE_URL="/apidoc/explorer/" # Base url path for SNDC API docs (for alive check)
SDNC_KARAF_LOG="/opt/opendaylight/data/log/karaf.log" # Path to karaf log
+export RAPP_CAT_EXTERNAL_PORT=8680 # RAPP Catalogue container external port (host -> container)
+export RAPP_CAT_INTERNAL_PORT=8080 # RAPP Catalogue container internal port (container -> container)
+export RAPP_CAT_EXTERNAL_SECURE_PORT=8633 # RAPP Catalogue container external secure port (host -> container)
+export RAPP_CAT_INTERNAL_SECURE_PORT=8433 # RAPP Catalogue container internal secure port (container -> container)
+export RAPP_CAT_APP_NAME="rapp-catalogue" # Name for the RAPP Catalogue
+
export CONTROL_PANEL_APP_NAME="control-panel" # Name of the Control Panel container
export CONTROL_PANEL_EXTERNAL_PORT=8080 # Control Panel container external port (host -> container)
export CONTROL_PANEL_INTERNAL_PORT=8080 # Control Panel container external port (host -> container)
CONTROL_PANEL_LOGPATH="/logs/nonrtric-controlpanel.log" # Path the application log in the Control Panel container
+
+########################################
+# Setting for common curl-base function
+########################################
+
UUID="" # UUID used as prefix to the policy id to simulate a real UUID
- # Testscript need to set the UUID to use other this empty prefix is used
+ # Testscript need to set the UUID otherwise this empty prefix is used
RESTBASE="http://localhost:"$POLICY_AGENT_EXTERNAL_PORT # Base url to the Agent NB REST interface
RESTBASE_SECURE="https://localhost:"$POLICY_AGENT_EXTERNAL_SECURE_PORT # Base url to the secure Agent NB REST interface
DMAAPBASE="http://localhost:"$MR_EXTERNAL_PORT # Base url to the Dmaap adapter, http
DMAAPBASE_SECURE="https://localhost:"$MR_EXTERNAL_SECURE_PORT # Base url to the Dmaap adapter, https
ADAPTER=$RESTBASE # Adapter holds the address the agent R-APP interface (REST OR DMAAP)
- # The values of this var is swiched between the two base url when needed
# The values of this var is swiched between the four base url when needed
ECS_RESTBASE="http://localhost:"$ECS_EXTERNAL_PORT # Base url to the ECS NB REST interface
@@ -198,4 +269,8 @@
CR_RESTBASE="http://localhost:"$CR_EXTERNAL_PORT # Base url to the Callback receiver REST interface
CR_RESTBASE_SECURE="https://localhost:"$CR_EXTERNAL_SECURE_PORT # Base url to the secure Callback receiver REST interface
CR_ADAPTER=$CR_RESTBASE # Adapter holds the address the CR admin interface (REST only)
- # The values of this var is swiched between the two base url when needed
\ No newline at end of file
+ # The values of this var is swiched between the two base url when needed
+
+RC_RESTBASE="http://localhost:"$RAPP_CAT_EXTERNAL_PORT # Base url to the RAPP Catalogue REST interface
+RC_RESTBASE_SECURE="https://localhost:"$RAPP_CAT_EXTERNAL_SECURE_PORT # Base url to the secure RAPP Catalogue REST interface
+RC_ADAPTER=$RC_RESTBASE # Adapter holds the address the RAPP Catalogue interface
\ No newline at end of file
diff --git a/test/common/testcase_common.sh b/test/common/testcase_common.sh
index f2783f3..cef8188 100755
--- a/test/common/testcase_common.sh
+++ b/test/common/testcase_common.sh
@@ -17,8 +17,44 @@
# ============LICENSE_END=================================================
#
-# This is a script that contains all the functions needed for auto test
-# Arg: local|remote|remote-remove [auto-clean] [--stop-at-error] [--ricsim-prefix <prefix> ] [ --env-file <environment-filename> ] [--use-local-image <app-nam> [<app-name>]*]
+# This is a script that contains all the common functions needed for auto test.
+# Specific test function are defined in scripts XXXX_functions.sh
+
+
+# List of short names for all supported apps, including simulators etc
+APP_SHORT_NAMES="PA RICSIM SDNC CP ECS RC CBS CONSUL RC MRSTUB CR PRODSTUB"
+
+__print_args() {
+ echo "Args: remote|remote-remove --env-file <environment-filename> [release] [auto-clean] [--stop-at-error] "
+ echo " [--ricsim-prefix <prefix> ] [--use-local-image <app-nam>+] [--use-snapshot-image <app-nam>+]"
+ echo " [--use-staging-image <app-nam>+] [--use-release-image <app-nam>+]"
+}
+
+if [ $# -eq 1 ] && [ "$1" == "help" ]; then
+
+ if [ ! -z "$TC_ONELINE_DESCR" ]; then
+ echo "Test script description:"
+ echo $TC_ONELINE_DESCR
+ echo ""
+ fi
+ __print_args
+ echo ""
+ echo "remote - Use images from remote repositories. Can be overridden for individual images using the '--use_xxx' flags"
+ echo "remote-remove - Same as 'remote' but will also try to pull fresh images from remote repositories"
+ echo "--env-file - The script will use the supplied file to read environment variables from"
+ echo "release - If this flag is given the script will use release version of the images"
+ echo "auto-clean - If the function 'auto_clean_containers' is present in the end of the test script then all containers will be stopped and removed. If 'auto-clean' is not given then the function has no effect."
+ echo "--stop-at-error - The script will stop when the first failed test or configuration"
+ echo "--ricsim-prefix - The a1 simulator will use the supplied string as container prefix instead of 'ricsim'"
+ echo "--use-local-image - The script will use local images for the supplied apps, space separated list of app short names"
+ echo "--use-snapshot-image - The script will use images from the nexus snapshot repo for the supplied apps, space separated list of app short names"
+ echo "--use-staging-image - The script will use images from the nexus staging repo for the supplied apps, space separated list of app short names"
+ echo "--use-release-image - The script will use images from the nexus release repo for the supplied apps, space separated list of app short names"
+ echo ""
+ echo "List of app short names supported: "$APP_SHORT_NAMES
+ exit 0
+fi
+
# Create a test case id, ATC (Auto Test Case), from the name of the test case script.
@@ -80,15 +116,29 @@
# Var to hold 'auto' in case containers shall be stopped when test case ends
AUTO_CLEAN=""
-# Var to hold the app names to use local image for when running 'remote' or 'remote-remove'
+# Var to hold the app names to use local images for
USE_LOCAL_IMAGES=""
-# List of available apps to override with local image
-AVAILABLE_LOCAL_IMAGES_OVERRIDE="PA ECS CP SDNC RICSIM RC"
+# Var to hold the app names to use remote snapshot images for
+USE_SNAPSHOT_IMAGES=""
+
+# Var to hold the app names to use remote staging images for
+USE_STAGING_IMAGES=""
+
+# Var to hold the app names to use remote release images for
+USE_RELEASE_IMAGES=""
+
+# List of available apps to override with local or remote staging/snapshot/release image
+AVAILABLE_IMAGES_OVERRIDE="PA ECS CP SDNC RICSIM RC"
# Use this var (STOP_AT_ERROR=1 in the test script) for debugging/trouble shooting to take all logs and exit at first FAIL test case
STOP_AT_ERROR=0
+# The default value "DEV" indicate that development image tags (SNAPSHOT) and nexus repos (nexus port 10002) are used.
+# The value "RELEASE" indicate that relase image tag and nexus repos (nexus port) are used
+# Applies only to images defined in the test-env files with image names and tags defined as XXXX_RELEASE
+IMAGE_CATEGORY="DEV"
+
# Function to indent cmd output with one space
indent1() { sed 's/^/ /'; }
@@ -265,12 +315,16 @@
START_ARG=$1
paramerror=0
+paramerror_str=""
if [ $# -lt 1 ]; then
paramerror=1
fi
if [ $paramerror -eq 0 ]; then
- if [ "$1" != "remote" ] && [ "$1" != "remote-remove" ] && [ "$1" != "local" ]; then
+ if [ "$1" != "remote" ] && [ "$1" != "remote-remove" ]; then
paramerror=1
+ if [ -z "$paramerror_str" ]; then
+ paramerror_str="First arg shall be 'remote' or 'remote-remove'"
+ fi
else
shift;
fi
@@ -279,6 +333,14 @@
while [ $paramerror -eq 0 ] && [ $foundparm -eq 0 ]; do
foundparm=1
if [ $paramerror -eq 0 ]; then
+ if [ "$1" == "release" ]; then
+ IMAGE_CATEGORY="RELEASE"
+ echo "Option set - Release image tags used for applicable images "
+ shift;
+ foundparm=0
+ fi
+ fi
+ if [ $paramerror -eq 0 ]; then
if [ "$1" == "auto-clean" ]; then
AUTO_CLEAN="auto"
echo "Option set - Auto clean at end of test script"
@@ -300,6 +362,9 @@
RIC_SIM_PREFIX=$1
if [ -z "$1" ]; then
paramerror=1
+ if [ -z "$paramerror_str" ]; then
+ paramerror_str="No prefix found for flag: '--ricsim-prefix'"
+ fi
else
echo "Option set - Overriding RIC_SIM_PREFIX with: "$1
shift;
@@ -313,6 +378,9 @@
TEST_ENV_VAR_FILE=$1
if [ -z "$1" ]; then
paramerror=1
+ if [ -z "$paramerror_str" ]; then
+ paramerror_str="No env file found for flag: '--env-file'"
+ fi
else
echo "Option set - Reading test env from: "$1
shift;
@@ -326,16 +394,97 @@
shift
while [ $# -gt 0 ] && [[ "$1" != "--"* ]]; do
USE_LOCAL_IMAGES=$USE_LOCAL_IMAGES" "$1
- if [[ "$AVAILABLE_LOCAL_IMAGES_OVERRIDE" != *"$1"* ]]; then
+ if [[ "$AVAILABLE_IMAGES_OVERRIDE" != *"$1"* ]]; then
paramerror=1
+ if [ -z "$paramerror_str" ]; then
+ paramerror_str="App name $1 is not available for local override for flag: '--use-local-image'"
+ fi
fi
shift;
done
foundparm=0
if [ -z "$USE_LOCAL_IMAGES" ]; then
paramerror=1
+ if [ -z "$paramerror_str" ]; then
+ paramerror_str="No app name found for flag: '--use-local-image'"
+ fi
else
- echo "Option set - Override remote images for app(s):"$USE_LOCAL_IMAGES
+ echo "Option set - Overriding with local images for app(s):"$USE_LOCAL_IMAGES
+ fi
+ fi
+ fi
+ if [ $paramerror -eq 0 ]; then
+ if [ "$1" == "--use-snapshot-image" ]; then
+ USE_SNAPSHOT_IMAGES=""
+ shift
+ while [ $# -gt 0 ] && [[ "$1" != "--"* ]]; do
+ USE_SNAPSHOT_IMAGES=$USE_SNAPSHOT_IMAGES" "$1
+ if [[ "$AVAILABLE_IMAGES_OVERRIDE" != *"$1"* ]]; then
+ paramerror=1
+ if [ -z "$paramerror_str" ]; then
+ paramerror_str="App name $1 is not available for snapshot override for flag: '--use-snapshot-image'"
+ fi
+ fi
+ shift;
+ done
+ foundparm=0
+ if [ -z "$USE_SNAPSHOT_IMAGES" ]; then
+ paramerror=1
+ if [ -z "$paramerror_str" ]; then
+ paramerror_str="No app name found for flag: '--use-snapshot-image'"
+ fi
+ else
+ echo "Option set - Overriding with snapshot images for app(s):"$USE_SNAPSHOT_IMAGES
+ fi
+ fi
+ fi
+ if [ $paramerror -eq 0 ]; then
+ if [ "$1" == "--use-staging-image" ]; then
+ USE_STAGING_IMAGES=""
+ shift
+ while [ $# -gt 0 ] && [[ "$1" != "--"* ]]; do
+ USE_STAGING_IMAGES=$USE_STAGING_IMAGES" "$1
+ if [[ "$AVAILABLE_IMAGES_OVERRIDE" != *"$1"* ]]; then
+ paramerror=1
+ if [ -z "$paramerror_str" ]; then
+ paramerror_str="App name $1 is not available for staging override for flag: '--use-staging-image'"
+ fi
+ fi
+ shift;
+ done
+ foundparm=0
+ if [ -z "$USE_STAGING_IMAGES" ]; then
+ paramerror=1
+ if [ -z "$paramerror_str" ]; then
+ paramerror_str="No app name found for flag: '--use-staging-image'"
+ fi
+ else
+ echo "Option set - Overriding with staging images for app(s):"$USE_STAGING_IMAGES
+ fi
+ fi
+ fi
+ if [ $paramerror -eq 0 ]; then
+ if [ "$1" == "--use-release-image" ]; then
+ USE_RELEASE_IMAGES=""
+ shift
+ while [ $# -gt 0 ] && [[ "$1" != "--"* ]]; do
+ USE_RELEASE_IMAGES=$USE_RELEASE_IMAGES" "$1
+ if [[ "$AVAILABLE_IMAGES_OVERRIDE" != *"$1"* ]]; then
+ paramerror=1
+ if [ -z "$paramerror_str" ]; then
+ paramerror_str="App name $1 is not available for release override for flag: '--use-release-image'"
+ fi
+ fi
+ shift;
+ done
+ foundparm=0
+ if [ -z "$USE_RELEASE_IMAGES" ]; then
+ paramerror=1
+ if [ -z "$paramerror_str" ]; then
+ paramerror_str="No app name found for flag: '--use-release-image'"
+ fi
+ else
+ echo "Option set - Overriding with release images for app(s):"$USE_RELEASE_IMAGES
fi
fi
fi
@@ -345,10 +494,14 @@
#Still params left?
if [ $paramerror -eq 0 ] && [ $# -gt 0 ]; then
paramerror=1
+ if [ -z "$paramerror_str" ]; then
+ paramerror_str="Unknown parameter(s): "$@
+ fi
fi
if [ $paramerror -eq 1 ]; then
- echo -e $RED"Expected arg: local|remote|remote-remove [auto-clean] [--stop-at-error] [--ricsim-prefix <prefix> ] [ --env-file <environment-filename> ] [--use-local-image <app-nam> [<app-name>]*]"$ERED
+ echo -e $RED"Incorrect arg list: "$paramerror_str$ERED
+ __print_args
exit 1
fi
@@ -358,12 +511,13 @@
. $TEST_ENV_VAR_FILE
if [ -z "$TEST_ENV_PROFILE" ] || [ -z "$SUPPORTED_PROFILES" ]; then
- echo -e $YELLOW"This test case may no work with selected test env file. TEST_ENV_PROFILE is missing in test_env file or SUPPORTED_PROFILES is missing in test case file"$EYELLOW
+ echo -e $YELLOW"This test case may not work with selected test env file. TEST_ENV_PROFILE is missing in test_env file or SUPPORTED_PROFILES is missing in test case file"$EYELLOW
else
if [[ "$SUPPORTED_PROFILES" == *"$TEST_ENV_PROFILE"* ]]; then
echo -e $GREEN"Test case support the selected test env file"$EGREEN
else
echo -e $RED"Test case does not support the selected test env file"$ERED
+ echo "Profile: "$TEST_ENV_PROFILE" Supported profiles: "$SUPPORTED_PROFILES
echo -e $RED"Exiting...."$ERED
exit 1
fi
@@ -376,6 +530,12 @@
exit 1
fi
+if [ -z "$PROJECT_IMAGES_APP_NAMES" ]; then
+ echo -e $RED"Var PROJECT_IMAGES_APP_NAMES must be defined in: "$TEST_ENV_VAR_FILE$ERED$ERED
+ exit 1
+fi
+
+
#Vars for A1 interface version and container count
G1_A1_VERSION=""
G2_A1_VERSION=""
@@ -422,13 +582,13 @@
IMAGE_ERR=0
#Create a file with image info for later printing as a table
image_list_file="./tmp/.image-list"
-echo -e " Container\tImage\ttag" > $image_list_file
+echo -e " Container\tImage\ttag\ttag-switch" > $image_list_file
# Check if image env var is set and if so export the env var with image to use (used by docker compose files)
-# arg: <image name> <script start-arg> <target-variable-name> <image-variable-name> <image-tag-variable-name> <app-short-name>
-__check_image_var() {
+# arg: <image name> <target-variable-name> <image-variable-name> <image-tag-variable-name> <tag-suffix> <app-short-name>
+__check_and_create_image_var() {
if [ $# -ne 6 ]; then
- echo "Expected arg: <image name> <script start-arg> <target-variable-name> <image-variable-name> <image-tag-variable-name> <app-short-name>"
+ echo "Expected arg: <image name> <target-variable-name> <image-variable-name> <image-tag-variable-name> <tag-suffix> <app-short-name>"
((IMAGE_ERR++))
return
fi
@@ -440,42 +600,50 @@
fi
tmp=${1}"\t"
#Create var from the input var names
- image="${!4}"
- tag="${!5}"
+ image="${!3}"
+ tmptag=$4"_"$5
+ tag="${!tmptag}"
if [ -z $image ]; then
- echo -e $RED"\$"$4" not set in $TEST_ENV_VAR_FILE"$ERED
- ((IMAGE_ERR++))
+ echo -e $RED"\$"$3" not set in $TEST_ENV_VAR_FILE"$ERED
+ ((IMAGE_ERR++))
echo ""
tmp=$tmp"<no-image>\t"
else
+ #Add repo depending on image type
+ if [ "$5" == "REMOTE_RELEASE" ]; then
+ image=$NEXUS_RELEASE_REPO$image
+ fi
+ if [ "$5" == "REMOTE" ]; then
+ image=$NEXUS_STAGING_REPO$image
+ fi
+ if [ "$5" == "REMOTE_SNAPSHOT" ]; then
+ image=$NEXUS_SNAPSHOT_REPO$image
+ fi
+ if [ "$5" == "REMOTE_PROXY" ]; then
+ image=$NEXUS_PROXY_REPO$image
+ fi
+ if [ "$5" == "REMOTE_RELEASE_ONAP" ]; then
+ image=$NEXUS_RELEASE_REPO_ONAP$image
+ fi
+ if [ "$5" == "REMOTE_RELEASE_ORAN" ]; then
+ image=$NEXUS_RELEASE_REPO_ORAN$image
+ fi
+ #No nexus repo added for local images, tag: LOCAL
tmp=$tmp$image"\t"
fi
if [ -z $tag ]; then
- echo -e $RED"\$"$5" not set in $TEST_ENV_VAR_FILE"$ERED
- ((IMAGE_ERR++))
+ echo -e $RED"\$"$tmptag" not set in $TEST_ENV_VAR_FILE"$ERED
+ ((IMAGE_ERR++))
echo ""
tmp=$tmp"<no-tag>\t"
else
tmp=$tmp$tag
fi
+ tmp=$tmp"\t"$5
echo -e "$tmp" >> $image_list_file
#Export the env var
- export "${3}"=$image":"$tag
-
- #echo " Configured image for ${1} (script start arg=${2}): "$image":"$tag
-}
-
-
-#Check if app local image shall override remote image
-# Possible IDs for local image override: PA, CP, SDNC, RICSIM, ECS
-__check_image_local_override() {
- for im in $USE_LOCAL_IMAGES; do
- if [ "$1" == "$im" ]; then
- return 1
- fi
- done
- return 0
+ export "${2}"=$image":"$tag
}
# Check if app uses image included in this test run
@@ -490,93 +658,142 @@
return 1
}
+__check_image_local_override() {
+ for im in $USE_LOCAL_IMAGES; do
+ if [ "$1" == "$im" ]; then
+ return 1
+ fi
+ done
+ return 0
+}
+
+# Check if app uses image override
+# Returns the image/tag suffix LOCAL for local image or REMOTE/REMOTE_RELEASE/REMOTE_SNAPSHOT for staging/release/snapshot image
+__check_image_override() {
+
+ for im in $ORAN_IMAGES_APP_NAMES; do
+ if [ "$1" == "$im" ]; then
+ echo "REMOTE_RELEASE_ORAN"
+ return 0
+ fi
+ done
+
+ for im in $ONAP_IMAGES_APP_NAMES; do
+ if [ "$1" == "$im" ]; then
+ echo "REMOTE_RELEASE_ONAP"
+ return 0
+ fi
+ done
+
+ found=0
+ for im in $PROJECT_IMAGES_APP_NAMES; do
+ if [ "$1" == "$im" ]; then
+ found=1
+ fi
+ done
+
+ if [ $found -eq 0 ]; then
+ echo "REMOTE_PROXY"
+ return 0
+ fi
+
+ suffix=""
+ if [ $IMAGE_CATEGORY == "RELEASE" ]; then
+ suffix="REMOTE_RELEASE"
+ fi
+ if [ $IMAGE_CATEGORY == "DEV" ]; then
+ suffix="REMOTE"
+ fi
+ CTR=0
+ for im in $USE_STAGING_IMAGES; do
+ if [ "$1" == "$im" ]; then
+ suffix="REMOTE"
+ ((CTR++))
+ fi
+ done
+ for im in $USE_RELEASE_IMAGES; do
+ if [ "$1" == "$im" ]; then
+ suffix="REMOTE_RELEASE"
+ ((CTR++))
+ fi
+ done
+ for im in $USE_SNAPSHOT_IMAGES; do
+ if [ "$1" == "$im" ]; then
+ suffix="REMOTE_SNAPSHOT"
+ ((CTR++))
+ fi
+ done
+ for im in $USE_LOCAL_IMAGES; do
+ if [ "$1" == "$im" ]; then
+ suffix="LOCAL"
+ ((CTR++))
+ fi
+ done
+ echo $suffix
+ if [ $CTR -gt 1 ]; then
+ exit 1
+ fi
+ return 0
+}
+
# Check that image env setting are available
echo ""
-if [ $START_ARG == "local" ]; then
-
- #Local agent image
- __check_image_var " Policy Agent" $START_ARG "POLICY_AGENT_IMAGE" "POLICY_AGENT_LOCAL_IMAGE" "POLICY_AGENT_LOCAL_IMAGE_TAG" PA
-
- #Local Control Panel image
- __check_image_var " Control Panel" $START_ARG "CONTROL_PANEL_IMAGE" "CONTROL_PANEL_LOCAL_IMAGE" "CONTROL_PANEL_LOCAL_IMAGE_TAG" CP
-
- #Local SNDC image
- __check_image_var " SDNC A1 Controller" $START_ARG "SDNC_A1_CONTROLLER_IMAGE" "SDNC_A1_CONTROLLER_LOCAL_IMAGE" "SDNC_A1_CONTROLLER_LOCAL_IMAGE_TAG" SDNC
-
- #Local ric sim image
- __check_image_var " RIC Simulator" $START_ARG "RIC_SIM_IMAGE" "RIC_SIM_LOCAL_IMAGE" "RIC_SIM_LOCAL_IMAGE_TAG" RICSIM
-
-elif [ $START_ARG == "remote" ] || [ $START_ARG == "remote-remove" ]; then
-
- __check_image_local_override 'PA'
- if [ $? -eq 0 ]; then
- #Remote agent image
- __check_image_var " Policy Agent" $START_ARG "POLICY_AGENT_IMAGE" "POLICY_AGENT_REMOTE_IMAGE" "POLICY_AGENT_REMOTE_IMAGE_TAG" PA
- else
- #Local agent image
- __check_image_var " Policy Agent" $START_ARG "POLICY_AGENT_IMAGE" "POLICY_AGENT_LOCAL_IMAGE" "POLICY_AGENT_LOCAL_IMAGE_TAG" PA
- fi
-
- __check_image_local_override 'CP'
- if [ $? -eq 0 ]; then
- #Remote Control Panel image
- __check_image_var " Control Panel" $START_ARG "CONTROL_PANEL_IMAGE" "CONTROL_PANEL_REMOTE_IMAGE" "CONTROL_PANEL_REMOTE_IMAGE_TAG" CP
- else
- #Local Control Panel image
- __check_image_var " Control Panel" $START_ARG "CONTROL_PANEL_IMAGE" "CONTROL_PANEL_LOCAL_IMAGE" "CONTROL_PANEL_LOCAL_IMAGE_TAG" CP
- fi
-
- __check_image_local_override 'SDNC'
- if [ $? -eq 0 ]; then
- #Remote SDNC image
- __check_image_var " SDNC A1 Controller" $START_ARG "SDNC_A1_CONTROLLER_IMAGE" "SDNC_A1_CONTROLLER_REMOTE_IMAGE" "SDNC_A1_CONTROLLER_REMOTE_IMAGE_TAG" SDNC
- else
- #Local SNDC image
- __check_image_var " SDNC A1 Controller" $START_ARG "SDNC_A1_CONTROLLER_IMAGE" "SDNC_A1_CONTROLLER_LOCAL_IMAGE" "SDNC_A1_CONTROLLER_LOCAL_IMAGE_TAG" SDNC
- fi
-
- __check_image_local_override 'RICSIM'
- if [ $? -eq 0 ]; then
- #Remote ric sim image
- __check_image_var " RIC Simulator" $START_ARG "RIC_SIM_IMAGE" "RIC_SIM_REMOTE_IMAGE" "RIC_SIM_REMOTE_IMAGE_TAG" RICSIM
- else
- #Local ric sim image
- __check_image_var " RIC Simulator" $START_ARG "RIC_SIM_IMAGE" "RIC_SIM_LOCAL_IMAGE" "RIC_SIM_LOCAL_IMAGE_TAG" RICSIM
- fi
-
- __check_image_local_override 'ECS'
- if [ $? -eq 0 ]; then
- #Remote ecs image
- __check_image_var " ECS" $START_ARG "ECS_IMAGE" "ECS_REMOTE_IMAGE" "ECS_REMOTE_IMAGE_TAG" ECS
- else
- #Local ecs image
- __check_image_var " ECS" $START_ARG "ECS_IMAGE" "ECS_LOCAL_IMAGE" "ECS_LOCAL_IMAGE_TAG" ECS
- fi
-
- __check_image_local_override 'RC'
- if [ $? -eq 0 ]; then
- #Remote ecs image
- __check_image_var " RC" $START_ARG "RAPP_CAT_IMAGE" "RAPP_CAT_REMOTE_IMAGE" "RAPP_CAT_REMOTE_IMAGE_TAG" RC
- else
- #Local ecs image
- __check_image_var " RC" $START_ARG "RAPP_CAT_IMAGE" "RAPP_CAT_LOCAL_IMAGE" "RAPP_CAT_LOCAL_IMAGE_TAG" RC
- fi
-
-else
- #Should never get here....
- echo "Unknow args: "$@
- exit 1
+#Agent image
+IMAGE_SUFFIX=$(__check_image_override 'PA')
+if [ $? -ne 0 ]; then
+ echo -e $RED"Image setting from cmd line not consistent for PA."$ERED
+ ((IMAGE_ERR++))
fi
+__check_and_create_image_var " Policy Agent" "POLICY_AGENT_IMAGE" "POLICY_AGENT_IMAGE_BASE" "POLICY_AGENT_IMAGE_TAG" $IMAGE_SUFFIX PA
+#Remote Control Panel image
+IMAGE_SUFFIX=$(__check_image_override 'CP')
+if [ $? -ne 0 ]; then
+ echo -e $RED"Image setting from cmd line not consistent for CP."$ERED
+ ((IMAGE_ERR++))
+fi
+__check_and_create_image_var " Control Panel" "CONTROL_PANEL_IMAGE" "CONTROL_PANEL_IMAGE_BASE" "CONTROL_PANEL_IMAGE_TAG" $IMAGE_SUFFIX CP
+
+#Remote SDNC image
+IMAGE_SUFFIX=$(__check_image_override 'SDNC')
+if [ $? -ne 0 ]; then
+ echo -e $RED"Image setting from cmd line not consistent for SDNC."$ERED
+ ((IMAGE_ERR++))
+fi
+__check_and_create_image_var " SDNC A1 Controller" "SDNC_A1_CONTROLLER_IMAGE" "SDNC_A1_CONTROLLER_IMAGE_BASE" "SDNC_A1_CONTROLLER_IMAGE_TAG" $IMAGE_SUFFIX SDNC
+
+#Remote ric sim image
+IMAGE_SUFFIX=$(__check_image_override 'RICSIM')
+if [ $? -ne 0 ]; then
+ echo -e $RED"Image setting from cmd line not consistent for RICSIM."$ERED
+ ((IMAGE_ERR++))
+fi
+__check_and_create_image_var " RIC Simulator" "RIC_SIM_IMAGE" "RIC_SIM_IMAGE_BASE" "RIC_SIM_IMAGE_TAG" $IMAGE_SUFFIX RICSIM
+
+#Remote ecs image
+IMAGE_SUFFIX=$(__check_image_override 'ECS')
+if [ $? -ne 0 ]; then
+ echo -e $RED"Image setting from cmd line not consistent for ECS."$EREDs
+ ((IMAGE_ERR++))
+fi
+__check_and_create_image_var " ECS" "ECS_IMAGE" "ECS_IMAGE_BASE" "ECS_IMAGE_TAG" $IMAGE_SUFFIX ECS
+
+#Remote rc image
+IMAGE_SUFFIX=$(__check_image_override 'RC')
+if [ $? -ne 0 ]; then
+ echo -e $RED"Image setting from cmd line not consistent for RC."$ERED
+ ((IMAGE_ERR++))
+fi
+__check_and_create_image_var " RC" "RAPP_CAT_IMAGE" "RAPP_CAT_IMAGE_BASE" "RAPP_CAT_IMAGE_TAG" $IMAGE_SUFFIX RC
# These images are not built as part of this project official images, just check that env vars are set correctly
-__check_image_var " Message Router" $START_ARG "MRSTUB_IMAGE" "MRSTUB_LOCAL_IMAGE" "MRSTUB_LOCAL_IMAGE_TAG" MR
-__check_image_var " Callback Receiver" $START_ARG "CR_IMAGE" "CR_LOCAL_IMAGE" "CR_LOCAL_IMAGE_TAG" CR
-__check_image_var " Producer stub" $START_ARG "PROD_STUB_IMAGE" "PROD_STUB_LOCAL_IMAGE" "PROD_STUB_LOCAL_IMAGE_TAG" PRODSTUB
-__check_image_var " Consul" $START_ARG "CONSUL_IMAGE" "CONSUL_REMOTE_IMAGE" "CONSUL_REMOTE_IMAGE_TAG" CONSUL
-__check_image_var " CBS" $START_ARG "CBS_IMAGE" "CBS_REMOTE_IMAGE" "CBS_REMOTE_IMAGE_TAG" CBS
-__check_image_var " SDNC DB" $START_ARG "SDNC_DB_IMAGE" "SDNC_DB_REMOTE_IMAGE" "SDNC_DB_REMOTE_IMAGE_TAG" SDNC #Uses sdnc app name
+__check_and_create_image_var " Message Router" "MRSTUB_IMAGE" "MRSTUB_IMAGE_BASE" "MRSTUB_IMAGE_TAG" LOCAL MR
+__check_and_create_image_var " Callback Receiver" "CR_IMAGE" "CR_IMAGE_BASE" "CR_IMAGE_TAG" LOCAL CR
+__check_and_create_image_var " Producer stub" "PROD_STUB_IMAGE" "PROD_STUB_IMAGE_BASE" "PROD_STUB_IMAGE_TAG" LOCAL PRODSTUB
+__check_and_create_image_var " Consul" "CONSUL_IMAGE" "CONSUL_IMAGE_BASE" "CONSUL_IMAGE_TAG" REMOTE_PROXY CONSUL
+__check_and_create_image_var " CBS" "CBS_IMAGE" "CBS_IMAGE_BASE" "CBS_IMAGE_TAG" REMOTE_RELEASE_ONAP CBS
+__check_and_create_image_var " SDNC DB" "SDNC_DB_IMAGE" "SDNC_DB_IMAGE_BASE" "SDNC_DB_IMAGE_TAG" REMOTE_PROXY SDNC #Uses sdnc app name
#Errors in image setting - exit
if [ $IMAGE_ERR -ne 0 ]; then
@@ -656,35 +873,52 @@
fi
fi
echo -e " Attempt to stop and remove container(s), if running - "$GREEN"stopped removed"$EGREEN
- echo -ne " Removing image - ${SAMELINE}"
- tmp="$(docker images -q ${4})" &> /dev/null
- if [ $? -eq 0 ] && [ ! -z "$tmp" ]; then
- docker rmi --force $4 &> ./tmp/.dockererr
- if [ $? -ne 0 ]; then
- ((IMAGE_ERR++))
- echo ""
- echo -e $RED" Image could not be removed - try manual removal of the image"$ERED
- cat ./tmp/.dockererr
- return 1
- fi
- echo -e " Removing image - "$GREEN"removed"$EGREEN
- else
- echo -e " Removing image - "$GREEN"image not in repository"$EGREEN
- fi
+ # echo -ne " Removing image - ${SAMELINE}"
+ # tmp="$(docker images -q ${4})" &> /dev/null
+ # if [ $? -eq 0 ] && [ ! -z "$tmp" ]; then
+ # docker rmi --force $4 &> ./tmp/.dockererr
+ # if [ $? -ne 0 ]; then
+ # ((IMAGE_ERR++))
+ # echo ""
+ # echo -e $RED" Image could not be removed - try manual removal of the image"$ERED
+ # cat ./tmp/.dockererr
+ # return 1
+ # fi
+ # echo -e " Removing image - "$GREEN"removed"$EGREEN
+ # else
+ # echo -e " Removing image - "$GREEN"image not in repository"$EGREEN
+ # fi
tmp_im=""
fi
if [ -z "$tmp_im" ]; then
echo -ne " Pulling image${SAMELINE}"
- docker pull $4 &> ./tmp/.dockererr
- tmp_im=$(docker images ${4} | grep -v REPOSITORY)
- if [ -z "$tmp_im" ]; then
+ # docker pull $4 &> ./tmp/.dockererr
+ # tmp_im=$(docker images ${4} | grep -v REPOSITORY)
+ # if [ -z "$tmp_im" ]; then
+ # echo ""
+ # echo -e " Pulling image -$RED could not be pulled"$ERED
+ # ((IMAGE_ERR++))
+ # cat ./tmp/.dockererr
+ # return 1
+ # fi
+ # echo -e " Pulling image -$GREEN Pulled $EGREEN"
+ out=$(docker pull $4)
+ if [ $? -ne 0 ]; then
echo ""
echo -e " Pulling image -$RED could not be pulled"$ERED
((IMAGE_ERR++))
- cat ./tmp/.dockererr
+ echo $out > ./tmp/.dockererr
+ echo $out
return 1
fi
- echo -e " Pulling image -$GREEN Pulled $EGREEN"
+ echo $out > ./tmp/.dockererr
+ if [[ $out == *"up to date"* ]]; then
+ echo -e " Pulling image -$GREEN Image is up to date $EGREEN"
+ elif [[ $out == *"Downloaded newer image"* ]]; then
+ echo -e " Pulling image -$GREEN Newer image pulled $EGREEN"
+ else
+ echo -e " Pulling image -$GREEN Pulled $EGREEN"
+ fi
else
echo -e " Pulling image -$GREEN OK $EGREEN(exists in local repository)"
fi
@@ -789,6 +1023,10 @@
echo "#################################################################################################"
echo -e $RED"One or more images could not be pulled or containers using the images could not be stopped/removed"$ERED
echo -e $RED"Or local image, overriding remote image, does not exist"$ERED
+ if [ $IMAGE_CATEGORY == "DEV" ]; then
+ echo -e $RED"Note that SNAPSHOT images may be purged from nexus after a certain period."$ERED
+ echo -e $RED"In that case, switch to use a released image instead."$ERED
+ fi
echo "#################################################################################################"
echo ""
exit 1
@@ -803,8 +1041,8 @@
if [ $? -eq 0 ]; then
cd $curdir
cd ../mrstub
- echo " Building mrstub image: $MRSTUB_LOCAL_IMAGE:$MRSTUB_LOCAL_IMAGE_TAG"
- docker build --build-arg NEXUS_PROXY_REPO=$NEXUS_PROXY_REPO -t $MRSTUB_LOCAL_IMAGE . &> .dockererr
+ echo " Building mrstub image: $MRSTUB_IMAGE:$MRSTUB_IMAGE_TAG_LOCAL"
+ docker build --build-arg NEXUS_PROXY_REPO=$NEXUS_PROXY_REPO -t $MRSTUB_IMAGE . &> .dockererr
if [ $? -eq 0 ]; then
echo -e $GREEN" Build Ok"$EGREEN
else
@@ -822,8 +1060,8 @@
__check_included_image 'CR'
if [ $? -eq 0 ]; then
cd ../cr
- echo " Building Callback Receiver image: $CR_LOCAL_IMAGE:$CR_IMAGE_TAG"
- docker build --build-arg NEXUS_PROXY_REPO=$NEXUS_PROXY_REPO -t $CR_LOCAL_IMAGE . &> .dockererr
+ echo " Building Callback Receiver image: $CR_IMAGE:$CR_IMAGE_TAG_LOCAL"
+ docker build --build-arg NEXUS_PROXY_REPO=$NEXUS_PROXY_REPO -t $CR_IMAGE . &> .dockererr
if [ $? -eq 0 ]; then
echo -e $GREEN" Build Ok"$EGREEN
else
@@ -841,8 +1079,8 @@
__check_included_image 'PRODSTUB'
if [ $? -eq 0 ]; then
cd ../prodstub
- echo " Building Producer stub image: $PROD_STUB_LOCAL_IMAGE:$PROD_STUB_LOCAL_IMAGE_TAG"
- docker build --build-arg NEXUS_PROXY_REPO=$NEXUS_PROXY_REPO -t $PROD_STUB_LOCAL_IMAGE . &> .dockererr
+ echo " Building Producer stub image: $PROD_STUB_IMAGE:$PROD_STUB_IMAGE_TAG_LOCAL"
+ docker build --build-arg NEXUS_PROXY_REPO=$NEXUS_PROXY_REPO -t $PROD_STUB_IMAGE . &> .dockererr
if [ $? -eq 0 ]; then
echo -e $GREEN" Build Ok"$EGREEN
else
@@ -895,7 +1133,7 @@
fi
__check_included_image 'PRODSTUB'
if [ $? -eq 0 ]; then
- echo -e " Produccer stub\t$(docker images --format $format_string $PROD_STUB_IMAGE)" >> $docker_tmp_file
+ echo -e " Producer stub\t$(docker images --format $format_string $PROD_STUB_IMAGE)" >> $docker_tmp_file
fi
__check_included_image 'CONSUL'
if [ $? -eq 0 ]; then