[CORD-2561]
Move E-CORD local test to profile repo
Change-Id: I1d6bc46e616e21981516c3227a9c02b00c613b48
diff --git a/ecord-test-subscriber-playbook.yml b/ecord-test-subscriber-playbook.yml
deleted file mode 100644
index f8451de..0000000
--- a/ecord-test-subscriber-playbook.yml
+++ /dev/null
@@ -1,29 +0,0 @@
----
-# Copyright 2017-present Open Networking Foundation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-# ecord-test-subscriber-playbook.yml
-# Configures and enables an E-CORD subscriber
-
-- name: Create test subscriber
- hosts: head
- roles:
- - test-ecord-subscriber-config
-
-- name: Enable the test subscriber
- hosts: head
- roles:
- - test-ecord-subscriber-enable
-
-
diff --git a/roles/test-ecord-subscriber-config/defaults/main.yml b/roles/test-ecord-subscriber-config/defaults/main.yml
deleted file mode 100644
index ddb934d..0000000
--- a/roles/test-ecord-subscriber-config/defaults/main.yml
+++ /dev/null
@@ -1,20 +0,0 @@
-
-# Copyright 2017-present Open Networking Foundation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-
----
-# test-ecord-subscriber-config/defaults/main.yml
-
-head_cord_profile_dir: "/opt/cord_profile"
diff --git a/roles/test-ecord-subscriber-config/tasks/main.yml b/roles/test-ecord-subscriber-config/tasks/main.yml
deleted file mode 100644
index 4386a77..0000000
--- a/roles/test-ecord-subscriber-config/tasks/main.yml
+++ /dev/null
@@ -1,26 +0,0 @@
-
-# Copyright 2017-present Open Networking Foundation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-
----
-# test-ecord-subscriber-config/tasks/main.yml
-
-- name: Create test-ecord-subscriber.yaml TOSCA config
- template:
- src: test-ecord-subscriber.yaml.j2
- dest: "{{ head_cord_profile_dir }}/test-ecord-subscriber.yaml"
- owner: "{{ ansible_user_id }}"
- mode: 0644
-
diff --git a/roles/test-ecord-subscriber-config/templates/test-ecord-subscriber.yaml.j2 b/roles/test-ecord-subscriber-config/templates/test-ecord-subscriber.yaml.j2
deleted file mode 100644
index e0c7ffb..0000000
--- a/roles/test-ecord-subscriber-config/templates/test-ecord-subscriber.yaml.j2
+++ /dev/null
@@ -1,125 +0,0 @@
-{#
-Copyright 2017-present Open Networking Foundation
-
-Licensed under the Apache License, Version 2.0 (the "License");
-you may not use this file except in compliance with the License.
-You may obtain a copy of the License at
-
-http://www.apache.org/licenses/LICENSE-2.0
-
-Unless required by applicable law or agreed to in writing, software
-distributed under the License is distributed on an "AS IS" BASIS,
-WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-See the License for the specific language governing permissions and
-limitations under the License.
-#}
-
-tosca_definitions_version: tosca_simple_yaml_1_0
-
-description: Creates a CORD test subscriber, created by platform-install
-
-imports:
- - custom_types/xos.yaml
- - custom_types/vee.yaml
- - custom_types/veg.yaml
-
-topology_template:
- node_templates:
-
-# site, fully created in deployment.yaml
- {{ site_name }}:
- type: tosca.nodes.Site
- properties:
- no-delete: true
- no-create: true
- no-update: true
-# vsg slice, volt service, fully created in cord-services.yaml
- {{ site_name }}_veg:
- type: tosca.nodes.Slice
- properties:
- no-delete: true
- no-create: true
- no-update: true
-
- service#vee:
- type: tosca.nodes.VEEService
- properties:
- no-delete: true
- no-create: true
- no-update: true
-
- service#vrouter:
- type: tosca.nodes.VRouterService
- properties:
- no-delete: true
- no-create: true
- no-update: true
-
- service#veg:
- type: tosca.nodes.VEGService
- requirements:
- properties:
- no-delete: true
- no-create: true
- no-update: true
-
-# Test subscriber
-
- # Let's add a user who can be administrator of the household
- johndoe@myhouse.com:
- type: tosca.nodes.User
- properties:
- password: letmein
- firstname: john
- lastname: doe
- requirements:
- - site:
- node: {{ site_name }}
- relationship: tosca.relationships.MemberOfSite
- - dependency:
- node: {{ site_name }}_veg
- relationship: tosca.relationships.DependsOn
-
- # Subscribers require a service in 4.0, so make sure we have an ecordlocal service.
- # FIXME: Move to a different tosca recipe?
- service#ecordlocal:
- type: tosca.nodes.Service
-
- # A subscriber
- My Enterprise:
- type: tosca.nodes.Tenant
- properties:
- service_specific_id: 123
- requirements:
- - provider_service:
- node: service#ecordlocal
- relationship: tosca.relationships.MemberOfService
-
- My vEG:
- type: tosca.nodes.VEGTenant
- properties:
- service_specific_id: 123
- requirements:
- - provider_service:
- node: service#veg
- relationship: tosca.relationships.MemberOfService
- - subscriber_tenant:
- node: My vEE
- relationship: tosca.relationships.BelongsToTenant
-
- My vEE:
- type: tosca.nodes.VEEServiceInstance
- properties:
- service_specific_id: 123
- s_tag: 123
- c_tag: 123
- requirements:
- - provider_service:
- node: service#vee
- relationship: tosca.relationships.MemberOfService
- - subscriber:
- node: My Enterprise
- relationship: tosca.relationships.BelongsToSubscriber
-# - dependency:
-# node: {{ site_name }}_veg
-# relationship: tosca.relationships.DependsOn
diff --git a/roles/test-ecord-subscriber-enable/defaults/main.yml b/roles/test-ecord-subscriber-enable/defaults/main.yml
deleted file mode 100644
index e7f2be1..0000000
--- a/roles/test-ecord-subscriber-enable/defaults/main.yml
+++ /dev/null
@@ -1,26 +0,0 @@
----
-# Copyright 2017-present Open Networking Foundation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-# test-ecord-subscriber-enable/defaults/main.yml
-
-xos_tosca_url: "http://xos-tosca/xos-tosca"
-
-head_credentials_dir: "/opt/credentials"
-
-head_cord_profile_dir: "/opt/cord_profile"
-
-xos_admin_user: "xosadmin@opencord.org"
-head_xos_admin_pass: "{{ lookup('file', head_credentials_dir ~ '/' ~ xos_admin_user) }}"
-
diff --git a/roles/test-ecord-subscriber-enable/tasks/main.yml b/roles/test-ecord-subscriber-enable/tasks/main.yml
deleted file mode 100644
index 5630c43..0000000
--- a/roles/test-ecord-subscriber-enable/tasks/main.yml
+++ /dev/null
@@ -1,35 +0,0 @@
----
-# Copyright 2017-present Open Networking Foundation
-#
-# Licensed under the Apache License, Version 2.0 (the "License");
-# you may not use this file except in compliance with the License.
-# You may obtain a copy of the License at
-#
-# http://www.apache.org/licenses/LICENSE-2.0
-#
-# Unless required by applicable law or agreed to in writing, software
-# distributed under the License is distributed on an "AS IS" BASIS,
-# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-# See the License for the specific language governing permissions and
-# limitations under the License.
-
-# test-ecord-subscriber-enable/tasks/main.yml
-
-- name: Run TOSCA to add E-CORD test-subscriber
- uri:
- url: "{{ xos_tosca_url }}/run"
- method: POST
- headers:
- xos-username: "{{ xos_admin_user }}"
- xos-password: "{{ head_xos_admin_pass }}"
- body: "{{ lookup('file', head_cord_profile_dir + '/' + item ) }}"
- status_code: 200
- register: result
- until: result | success
- retries: 50
- delay: 5
- with_items:
- - "test-ecord-subscriber.yaml"
- tags:
- - skip_ansible_lint # TOSCA loading should be idempotent
-