diff options
Diffstat (limited to 'roles/xtesting-onap-vnf')
13 files changed, 549 insertions, 0 deletions
diff --git a/roles/xtesting-onap-vnf/tasks/launch.yaml b/roles/xtesting-onap-vnf/tasks/launch.yaml new file mode 100644 index 0000000..4220647 --- /dev/null +++ b/roles/xtesting-onap-vnf/tasks/launch.yaml @@ -0,0 +1,75 @@ +--- +# tasks file for functest (tests) + +## +- block: + - name: generate pre command to run + ansible.builtin.set_fact: + command: "mkdir -p /var/lib/xtesting/results/{{ run_type }}" + + - name: generate command to run + ansible.builtin.set_fact: + command: "{{ command }} && run_tests --test {{ run_type }} --report" + + - name: add S3 upload to command + ansible.builtin.set_fact: + command: "{{ command }} --push" + when: use_s3 | bool + + - name: generate a random number between 0 and 600 + ansible.builtin.set_fact: + before_launch_wait_time: "{{ 600 | random }}" + when: random_wait and before_launch_wait_time is not defined + + - name: "wait {{ before_launch_wait_time }}s in order to allow 'sequential' tests" + run_once: yes + wait_for: + timeout: "{{ before_launch_wait_time }}" + delegate_to: localhost + when: random_wait + + - name: "launch onap-vnf docker for {{ run_type }}" + community.general.docker_container: + container_default_behavior: no_defaults + name: "{{ docker_vnf_name }}-{{ run_type }}" + image: "{{ docker_vnf_image }}:{{ docker_vnf_version }}" + env_file: "{{ exec_local_path }}/env" + state: started + command: "/bin/bash -c '{{ command }}'" + pull: yes + recreate: yes + volumes: "{{ volumes }}" + etc_hosts: "{{ etc_hosts }}" + detach: yes + keep_volumes: no + + - name: wait for test docker to be finished + community.docker.docker_container_info: + name: "{{ docker_vnf_name }}-{{ run_type }}" + register: container_info + until: container_info.container.State.Status == "exited" + retries: "{{ run_timeout }}" + delay: 1 + + - name: "{{ run_type }} has failed" + ansible.builtin.fail: + msg: "The test {{ run_type }} has failed" + when: container_info.container.State.ExitCode != 0 + always: + - name: retrieve container logs + shell: "docker logs {{ docker_vnf_name }}-{{ run_type }}" + register: container_logs + ignore_errors: True + + - name: display container logs + debug: + msg: "{{ container_logs.stdout }}" + ignore_errors: True + - name: "save VNF results for artifacts" + ansible.posix.synchronize: + src: "{{ res_local_path }}/{{ run_tiers }}/{{ run_type }}" + dest: "./results/{{ run_tiers }}" + mode: pull + use_ssh_args: true + ignore_errors: True + when: not use_s3 | bool diff --git a/roles/xtesting-onap-vnf/tasks/main.yaml b/roles/xtesting-onap-vnf/tasks/main.yaml new file mode 100644 index 0000000..db10573 --- /dev/null +++ b/roles/xtesting-onap-vnf/tasks/main.yaml @@ -0,0 +1,5 @@ +--- +- import_tasks: prepare_cnf_test.yaml + when: run_type == "basic_cnf" +- import_tasks: prepare.yaml +- import_tasks: launch.yaml diff --git a/roles/xtesting-onap-vnf/tasks/prepare.yaml b/roles/xtesting-onap-vnf/tasks/prepare.yaml new file mode 100644 index 0000000..addab8c --- /dev/null +++ b/roles/xtesting-onap-vnf/tasks/prepare.yaml @@ -0,0 +1,57 @@ +--- +# tasks file for roles/prepare_test + +## +# Prepare config +## +- name: Clean directory + ansible.builtin.file: + path: "{{ exec_local_path }}" + state: absent + +- name: Create directory + ansible.builtin.file: + path: "{{ exec_local_path }}/vnf-services" + state: directory + mode: 0755 + +- name: Create env file + ansible.builtin.template: + src: env-os.j2 + dest: "{{ exec_local_path }}/env" + mode: "0644" + +- name: copy pythonsdk-tests configuration file + ansible.builtin.template: + src: settings.py.j2 + dest: "{{ exec_local_path }}/settings.py" + mode: "0644" + +- name: create basic_vm configuration file + ansible.builtin.template: + src: basic_vm-service-{{ onap_version }}.yaml.j2 + dest: "{{ exec_local_path }}/basic_vm-service.yaml" + mode: "0644" + +- name: create basic_vm_macro configuration file + ansible.builtin.template: + src: basic_vm_macro-service-{{ onap_version }}.yaml.j2 + dest: "{{ exec_local_path }}/basic_vm_macro-service.yaml" + mode: "0644" + +- name: create directories as root + become: yes + ansible.builtin.file: + path: "{{ res_local_path }}/{{ run_tiers }}/{{ run_type }}" + state: directory + mode: 0755 +- name: Delete old logs + become: yes + ansible.builtin.file: + state: absent + path: "{{ res_local_path }}/{{ run_tiers }}/{{ run_type }}" + +- name: clean onap-vnf docker + community.general.docker_container: + name: "{{ docker_vnf_name }}-{{ run_type }}" + state: absent diff --git a/roles/xtesting-onap-vnf/tasks/prepare_cnf_test.yaml b/roles/xtesting-onap-vnf/tasks/prepare_cnf_test.yaml new file mode 100644 index 0000000..47ee366 --- /dev/null +++ b/roles/xtesting-onap-vnf/tasks/prepare_cnf_test.yaml @@ -0,0 +1,86 @@ +--- +- name: Check that cloud-site service does not exist + community.kubernetes.k8s_service: + name: cloud-site + namespace: onap + state: absent + +- name: Expose nodePort with created cloud-site service + shell: kubectl -n onap expose svc so-catalog-db-adapter --name cloud-site --type=NodePort + +- name: Get nodePort for cloud-site service + community.kubernetes.k8s_info: + kind: service + namespace: onap + name: cloud-site + register: output + +- name: set variable for api port + ansible.builtin.set_fact: + cloudsite_port: "{{ output.resources[0].spec.ports[0].nodePort }}" + +- name: Get DEFAULT Cloud Site + ansible.builtin.uri: + url: "{{ so_url }}:{{ cloudsite_port }}/\ + cloudSite/DEFAULT" + method: GET + status_code: 200 + body_format: json + validate_certs: "no" + return_content: "yes" + headers: + authorization: Basic YnBlbDpwYXNzd29yZDEk + Accept: application/json + Cache-Control: no-cache + register: output + +- name: Add cloud site CloudRegion + ansible.builtin.uri: + url: "{{ so_url }}:{{ cloudsite_port }}/\ + cloudSite/{{ k8sRegionID }}" + method: PUT + status_code: + - 200 + - 201 + body_format: json + validate_certs: "no" + return_content: "yes" + headers: + authorization: Basic YnBlbDpwYXNzd29yZDEk + Accept: application/json + Cache-Control: no-cache + body: + id: "{{ k8sRegionID }}" + region_id: "{{ k8sRegionID }}" + aic_version: 2.5 + clli: "{{ datacenter_id }}" + orchestrator: multicloud + identity_service_id: DEFAULT_KEYSTONE + identityService: "{{ output.json.identityService }}" + +- name: Remove created cloud-site service with NodePort + community.kubernetes.k8s_service: + name: cloud-site + namespace: onap + state: absent + +- name: delete cnf namespace + community.kubernetes.k8s: + state: absent + definition: + apiVersion: v1 + kind: Namespace + metadata: + name: "{{ cnf_namespace }}" + +- name: wait for cnf namespace full deletion + shell: | + set -o pipefail && kubectl get namespace | + grep -c {{ cnf_namespace }} || true + args: + executable: /bin/bash + register: kube + changed_when: kube.stdout == '0' + until: kube.stdout == '0' + retries: 600 + delay: 1 diff --git a/roles/xtesting-onap-vnf/templates/basic_vm-service-istanbul.yaml.j2 b/roles/xtesting-onap-vnf/templates/basic_vm-service-istanbul.yaml.j2 new file mode 100644 index 0000000..53ffc91 --- /dev/null +++ b/roles/xtesting-onap-vnf/templates/basic_vm-service-istanbul.yaml.j2 @@ -0,0 +1,2 @@ +{% extends "basic_vm-service-master.yaml.j2" %} +{% block heat_file_path %}onaptests/templates/heat-files/ubuntu20/ubuntu20agent.zip{% endblock %}
\ No newline at end of file diff --git a/roles/xtesting-onap-vnf/templates/basic_vm-service-jakarta.yaml.j2 b/roles/xtesting-onap-vnf/templates/basic_vm-service-jakarta.yaml.j2 new file mode 100644 index 0000000..d0ca6f2 --- /dev/null +++ b/roles/xtesting-onap-vnf/templates/basic_vm-service-jakarta.yaml.j2 @@ -0,0 +1,40 @@ +--- +basic_vm: + vnfs: + - vnf_name: basic_vm + heat_files_to_upload: {% block heat_file_path %}templates/heat-files/ubuntu20/ubuntu20agent.zip{% endblock %} + + vnf_parameters: [ + {"name": "ubuntu20_image_name", + "value": "Ubuntu_2004" + }, + {"name": "ubuntu20_key_name", + "value": "onap_dt" + }, + {"name": "ubuntu20_pub_key", + "value": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAA\ +BAQDY15cdBmIs2XOpe4EiFCsaY6bmUmK/GysMoLl4UG51JCfJwvwoWCoA+6mDIbymZxhxq9IGx\ +ilp/yTA6WQ9s/5pBag1cUMJmFuda9PjOkXl04jgqh5tR6I+GZ97AvCg93KAECis5ubSqw1xOCj4\ +utfEUtPoF1OuzqM/lE5mY4N6VKXn+fT7pCD6cifBEs6JHhVNvs5OLLp/tO8Pa3kKYQOdyS0xc3r\ +h+t2lrzvKUSWGZbX+dLiFiEpjsUL3tDqzkEMNUn4pdv69OJuzWHCxRWPfdrY9Wg0j3mJesP29EBh\ +t+w+EC9/kBKq+1VKdmsXUXAcjEvjovVL8l1BrX3BY0R8D imported-openssh-key" + }, + {"name": "ubuntu20_flavor_name", + "value": "m1.small" + }, + {"name": "VM_name", + "value": "ubuntu20agent-VM-01" + }, + {"name": "vnf_id", + "value": "ubuntu20agent-VNF-instance" + }, + {"name": "vf_module_id", + "value": "ubuntu20agent-vfmodule-instance" + }, + {"name": "vnf_name", + "value": "ubuntu20agent-VNF" + }, + {"name": "admin_plane_net_name", + "value": "{{ openstack_public_net_id }}" + } + ] diff --git a/roles/xtesting-onap-vnf/templates/basic_vm-service-master.yaml.j2 b/roles/xtesting-onap-vnf/templates/basic_vm-service-master.yaml.j2 new file mode 100644 index 0000000..d0ca6f2 --- /dev/null +++ b/roles/xtesting-onap-vnf/templates/basic_vm-service-master.yaml.j2 @@ -0,0 +1,40 @@ +--- +basic_vm: + vnfs: + - vnf_name: basic_vm + heat_files_to_upload: {% block heat_file_path %}templates/heat-files/ubuntu20/ubuntu20agent.zip{% endblock %} + + vnf_parameters: [ + {"name": "ubuntu20_image_name", + "value": "Ubuntu_2004" + }, + {"name": "ubuntu20_key_name", + "value": "onap_dt" + }, + {"name": "ubuntu20_pub_key", + "value": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAA\ +BAQDY15cdBmIs2XOpe4EiFCsaY6bmUmK/GysMoLl4UG51JCfJwvwoWCoA+6mDIbymZxhxq9IGx\ +ilp/yTA6WQ9s/5pBag1cUMJmFuda9PjOkXl04jgqh5tR6I+GZ97AvCg93KAECis5ubSqw1xOCj4\ +utfEUtPoF1OuzqM/lE5mY4N6VKXn+fT7pCD6cifBEs6JHhVNvs5OLLp/tO8Pa3kKYQOdyS0xc3r\ +h+t2lrzvKUSWGZbX+dLiFiEpjsUL3tDqzkEMNUn4pdv69OJuzWHCxRWPfdrY9Wg0j3mJesP29EBh\ +t+w+EC9/kBKq+1VKdmsXUXAcjEvjovVL8l1BrX3BY0R8D imported-openssh-key" + }, + {"name": "ubuntu20_flavor_name", + "value": "m1.small" + }, + {"name": "VM_name", + "value": "ubuntu20agent-VM-01" + }, + {"name": "vnf_id", + "value": "ubuntu20agent-VNF-instance" + }, + {"name": "vf_module_id", + "value": "ubuntu20agent-vfmodule-instance" + }, + {"name": "vnf_name", + "value": "ubuntu20agent-VNF" + }, + {"name": "admin_plane_net_name", + "value": "{{ openstack_public_net_id }}" + } + ] diff --git a/roles/xtesting-onap-vnf/templates/basic_vm_macro-service-istanbul.yaml.j2 b/roles/xtesting-onap-vnf/templates/basic_vm_macro-service-istanbul.yaml.j2 new file mode 100644 index 0000000..ada0289 --- /dev/null +++ b/roles/xtesting-onap-vnf/templates/basic_vm_macro-service-istanbul.yaml.j2 @@ -0,0 +1,2 @@ +{% extends "basic_vm_macro-service-master.yaml.j2" %} +{% block heat_file_path %}onaptests/templates/heat-files/ubuntu20/ubuntu20agent.zip{% endblock %}
\ No newline at end of file diff --git a/roles/xtesting-onap-vnf/templates/basic_vm_macro-service-jakarta.yaml.j2 b/roles/xtesting-onap-vnf/templates/basic_vm_macro-service-jakarta.yaml.j2 new file mode 100644 index 0000000..c35ca34 --- /dev/null +++ b/roles/xtesting-onap-vnf/templates/basic_vm_macro-service-jakarta.yaml.j2 @@ -0,0 +1,55 @@ +--- +basic_vm_macro: + instantiation_type: "Macro" + vnfs: + - vnf_name: basic_vm_macro + properties: + controller_actor: "CDS" + skip_post_instantiation_configuration: False + sdnc_artifact_name: "vnf" + sdnc_model_version: "1.0.0" + sdnc_model_name: "ubuntu20" + vnf_artifact_type: "CONTROLLER_BLUEPRINT_ARCHIVE" + vnf_artifact_name: "BASIC_VM_enriched.zip" + vnf_artifact_label: "vnfcds" + vnf_artifact_file_path: "/tmp/BASIC_VM_enriched.zip" + heat_files_to_upload: {% block heat_file_path %}templates/heat-files/ubuntu20/ubuntu20agent.zip{% endblock %} + + vf_module_parameters: + - vf_module_name: base_ubuntu20 + parameters: [ + {"name": "ubuntu20_image_name", + "value": "Ubuntu_2004" + }, + {"name": "ubuntu20_key_name", + "value": "onap_dt" + }, + {"name": "ubuntu20_pub_key", + "value": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAA\ + BAQDY15cdBmIs2XOpe4EiFCsaY6bmUmK/GysMoLl4UG51JCfJwvwoWCoA+6mDIbymZxhxq9IGx\ + ilp/yTA6WQ9s/5pBag1cUMJmFuda9PjOkXl04jgqh5tR6I+GZ97AvCg93KAECis5ubSqw1xOCj4\ + utfEUtPoF1OuzqM/lE5mY4N6VKXn+fT7pCD6cifBEs6JHhVNvs5OLLp/tO8Pa3kKYQOdyS0xc3r\ + h+t2lrzvKUSWGZbX+dLiFiEpjsUL3tDqzkEMNUn4pdv69OJuzWHCxRWPfdrY9Wg0j3mJesP29EBh\ + t+w+EC9/kBKq+1VKdmsXUXAcjEvjovVL8l1BrX3BY0R8D imported-openssh-key" + }, + {"name": "ubuntu20_flavor_name", + "value": "m1.small" + }, + {"name": "VM_name", + "value": "basic_vm_macro-VM-01" + }, + {"name": "vnf_id", + "value": "basic_vm_macro-VNF-instance" + }, + {"name": "vf_module_id", + "value": "basic_vm_macro-vfmodule-instance" + }, + {"name": "vnf_name", + "value": "basic_vm_macro-VNF" + }, + {"name": "admin_plane_net_name", + "value": "{{ openstack_public_net_id }}" + }, + {"name": "ubuntu20_name_0", + "value": "ubuntu20agent-VNF"} + ] diff --git a/roles/xtesting-onap-vnf/templates/basic_vm_macro-service-master.yaml.j2 b/roles/xtesting-onap-vnf/templates/basic_vm_macro-service-master.yaml.j2 new file mode 100644 index 0000000..c35ca34 --- /dev/null +++ b/roles/xtesting-onap-vnf/templates/basic_vm_macro-service-master.yaml.j2 @@ -0,0 +1,55 @@ +--- +basic_vm_macro: + instantiation_type: "Macro" + vnfs: + - vnf_name: basic_vm_macro + properties: + controller_actor: "CDS" + skip_post_instantiation_configuration: False + sdnc_artifact_name: "vnf" + sdnc_model_version: "1.0.0" + sdnc_model_name: "ubuntu20" + vnf_artifact_type: "CONTROLLER_BLUEPRINT_ARCHIVE" + vnf_artifact_name: "BASIC_VM_enriched.zip" + vnf_artifact_label: "vnfcds" + vnf_artifact_file_path: "/tmp/BASIC_VM_enriched.zip" + heat_files_to_upload: {% block heat_file_path %}templates/heat-files/ubuntu20/ubuntu20agent.zip{% endblock %} + + vf_module_parameters: + - vf_module_name: base_ubuntu20 + parameters: [ + {"name": "ubuntu20_image_name", + "value": "Ubuntu_2004" + }, + {"name": "ubuntu20_key_name", + "value": "onap_dt" + }, + {"name": "ubuntu20_pub_key", + "value": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAA\ + BAQDY15cdBmIs2XOpe4EiFCsaY6bmUmK/GysMoLl4UG51JCfJwvwoWCoA+6mDIbymZxhxq9IGx\ + ilp/yTA6WQ9s/5pBag1cUMJmFuda9PjOkXl04jgqh5tR6I+GZ97AvCg93KAECis5ubSqw1xOCj4\ + utfEUtPoF1OuzqM/lE5mY4N6VKXn+fT7pCD6cifBEs6JHhVNvs5OLLp/tO8Pa3kKYQOdyS0xc3r\ + h+t2lrzvKUSWGZbX+dLiFiEpjsUL3tDqzkEMNUn4pdv69OJuzWHCxRWPfdrY9Wg0j3mJesP29EBh\ + t+w+EC9/kBKq+1VKdmsXUXAcjEvjovVL8l1BrX3BY0R8D imported-openssh-key" + }, + {"name": "ubuntu20_flavor_name", + "value": "m1.small" + }, + {"name": "VM_name", + "value": "basic_vm_macro-VM-01" + }, + {"name": "vnf_id", + "value": "basic_vm_macro-VNF-instance" + }, + {"name": "vf_module_id", + "value": "basic_vm_macro-vfmodule-instance" + }, + {"name": "vnf_name", + "value": "basic_vm_macro-VNF" + }, + {"name": "admin_plane_net_name", + "value": "{{ openstack_public_net_id }}" + }, + {"name": "ubuntu20_name_0", + "value": "ubuntu20agent-VNF"} + ] diff --git a/roles/xtesting-onap-vnf/templates/clearwater-ims-service.yaml.j2 b/roles/xtesting-onap-vnf/templates/clearwater-ims-service.yaml.j2 new file mode 100644 index 0000000..bf950a7 --- /dev/null +++ b/roles/xtesting-onap-vnf/templates/clearwater-ims-service.yaml.j2 @@ -0,0 +1,55 @@ +--- +ims: + tosca_file_from_SDC: service-Ims-template + version: "1.0" + subscription_type: "ims" + vnfs: + - vnf_name: Clearwater_vnf + heat_files_to_upload: onaptests/templates/heat-files/clearwater_ims/clearwater_ims.zip + vnf_parameters: [ + {"vnf-parameter-name":"public_net_id", + "vnf-parameter-value":"{{ openstack_public_net_id }}"}, + {"vnf-parameter-name":"bono_image_name", + "vnf-parameter-value":"Ubuntu_1404"}, + {"vnf-parameter-name":"bono_flavor_name", + "vnf-parameter-value":"m1.medium"}, + {"vnf-parameter-name":"dime_image_name", + "vnf-parameter-value":"Ubuntu_1404"}, + {"vnf-parameter-name":"dime_flavor_name", + "vnf-parameter-value":"m1.medium"}, + {"vnf-parameter-name":"dns_image_name", + "vnf-parameter-value":"Ubuntu_1404"}, + {"vnf-parameter-name":"dns_flavor_name", + "vnf-parameter-value":"m1.medium"}, + {"vnf-parameter-name":"ellis_image_name", + "vnf-parameter-value":"Ubuntu_1404"}, + {"vnf-parameter-name":"ellis_flavor_name", + "vnf-parameter-value":"m1.medium"}, + {"vnf-parameter-name":"homer_image_name", + "vnf-parameter-value":"Ubuntu_1404"}, + {"vnf-parameter-name":"homer_flavor_name", + "vnf-parameter-value":"m1.medium"}, + {"vnf-parameter-name":"robot_image_name", + "vnf-parameter-value":"Ubuntu_1404"}, + {"vnf-parameter-name":"robot_flavor_name", + "vnf-parameter-value":"m1.medium"}, + {"vnf-parameter-name":"sprout_image_name", + "vnf-parameter-value":"Ubuntu_1404"}, + {"vnf-parameter-name":"sprout_flavor_name", + "vnf-parameter-value":"m1.medium"}, + {"vnf-parameter-name":"vellum_image_name", + "vnf-parameter-value":"Ubuntu_1404"}, + {"vnf-parameter-name":"vellum_flavor_name", + "vnf-parameter-value":"m1.medium"}, + {"vnf-parameter-name":"dns_ip", + "vnf-parameter-value":"8.8.8.8"}, + {"vnf-parameter-name": "clearwater_pub_key", + "vnf-parameter-value":"ssh-rsa AAAAB3NzaC1yc2EAAAABJQAAAQEAr0If\ +62QHgf/xKzomkwBD9c1ol7edWpyG5+p9UBRE0D/bJcA5lyRpaYlcjxp3pfnN+WiVYfzjwHDjeDlyAO\ +pH2o3yrBCA9U+sU6PjhIH/BXFVkVQBY4xAmtjQnN3QCzjn8BA6PbaEt53OvvaYqtgg0yc5OOA0nyDl\ +cg/FU88I1MnhZvjTU90V4QEYKCMAyYcz6NdjGfC7PmpKIVmSWgHOdR59d5CGIRv6BnIWIBqXy+z+el\ +dbSKBrRVo/dv/H8Q0uwS6/rA2gLXeXhsQmEFZXsxwovypWm6t5hWMK/4cXA88AwylMd9xSroic398R\ +ZiO3QygZ9L7aQN2rnuAQHHOOaw==" + }, + {"vnf-parameter-name":"clearwater_key_name", + "vnf-parameter-value":"onap_key"}] diff --git a/roles/xtesting-onap-vnf/templates/env-os.j2 b/roles/xtesting-onap-vnf/templates/env-os.j2 new file mode 100644 index 0000000..5bbcdd4 --- /dev/null +++ b/roles/xtesting-onap-vnf/templates/env-os.j2 @@ -0,0 +1,14 @@ +INSTALLER_TYPE={{ deployment_name }} +TEST_DB_URL={{ test_result_url }} +NODE_NAME={{ node_name }} +BUILD_TAG={{ build_tag }} +DEBUG=False +OS_TEST_CLOUD={{ os_test_cloud }} +ONAP_PYTHON_SDK_SETTINGS={{ vnf_settings }} +{% if use_s3 | bool %} +S3_ENDPOINT_URL={{ s3_endpoint }} +S3_DST_URL={{ s3_dst }} +HTTP_DST_URL={{ s3_http_url_endpoint }} +AWS_ACCESS_KEY_ID={{ s3_access_key }} +AWS_SECRET_ACCESS_KEY={{ s3_secret_key }} +{% endif %} diff --git a/roles/xtesting-onap-vnf/templates/settings.py.j2 b/roles/xtesting-onap-vnf/templates/settings.py.j2 new file mode 100644 index 0000000..c5eaba3 --- /dev/null +++ b/roles/xtesting-onap-vnf/templates/settings.py.j2 @@ -0,0 +1,63 @@ +"""Specific settings module.""" # pylint: disable=bad-whitespace + +###################### +# # +# ONAP INPUTS DATAS # +# # +###################### + + +# Variables to set logger information +# Possible values for logging levels in onapsdk: INFO, DEBUG , WARNING, ERROR +LOG_CONFIG = { + "version": 1, + "disable_existing_loggers": False, + "formatters": { + "default": { + "class": "logging.Formatter", + "format": "%(asctime)s %(levelname)s %(lineno)d:%(filename)s(%(process)d) - %(message)s" + } + }, + "handlers": { + "console": { + "level": "INFO", + "class": "logging.StreamHandler", + "formatter": "default" + }, + "file": { + "level": "DEBUG", + "class": "logging.FileHandler", + "formatter": "default", + "filename": "/var/lib/xtesting/results/{{ run_type }}/pythonsdk.debug.log", + "mode": "w" + } + }, + "root": { + "level": "DEBUG", + "handlers": ["console", "file"] + } +} +CLEANUP_FLAG = False + +# SOCK_HTTP = "socks5h://127.0.0.1:8080" +REPORTING_FILE_PATH = "/var/lib/xtesting/results/{{ run_type }}/reporting.html" +K8S_REGION_TYPE = "k8s" +TILLER_HOST = "localhost" +K8S_CONFIG = None # None means it will use default config (~/.kube/config) +K8S_NAMESPACE = "onap" # Kubernetes namespace +K8S_ONAP_NAMESPACE = "onap" # ONAP Kubernetes namespace +K8S_ADDITIONAL_RESOURCES_NAMESPACE = K8S_ONAP_NAMESPACE # Resources created on tests namespac +ORCHESTRATION_REQUEST_TIMEOUT = 60.0 * 30 # 30 minutes in seconds +{% if use_ingress | bool %} +AAI_URL = "https://aai-api.simpledemo.onap.org" +CDS_URL = "https://cds-blueprintsprocessor-api.simpledemo.onap.org" +MSB_URL = "https://msb-iag-ui.simpledemo.onap.org" +SDC_BE_URL = "https://sdc-be-api.simpledemo.onap.org" +SDC_FE_URL = "https://sdc-fe-ui.simpledemo.onap.org" +SDNC_URL = "https://sdnc-api.simpledemo.onap.org" +SO_URL = "https://so-api.simpledemo.onap.org" +CLAMP_URL = "https://policy-ui.simpledemo.onap.org" +VES_URL = "https://dcae-ves-collector-api.simpledemo.onap.org" +DMAAP_URL = "https://dmaap-mr-api.simpledemo.onap.org" +{% endif %} + |