This adds shell runner script and HOT setup to
deploy and run it.
Change-Id: I88b9b516f38dac789da1caa050192358829e9357
Issue-ID: INT-1661
Signed-off-by: Bartek Grzybowski <b.grzybowski@partner.samsung.com>
- docker-ce
- docker-ce-cli
- containerd.io
- docker-ce
- docker-ce-cli
- containerd.io
+ - docker-compose
+ - python3-virtualenv
+ - python3-pip
# Docker's apt key needs to be injected early in the boot as 'apt' cloud-init
# Docker's apt key needs to be injected early in the boot as 'apt' cloud-init
-# module doesn't support configuring key from file
+# module doesn't support configuring key from file
bootcmd:
- [curl, "https://download.docker.com/linux/ubuntu/gpg", -o, /run/docker.key]
- [apt-key, add, /run/docker.key]
bootcmd:
- [curl, "https://download.docker.com/linux/ubuntu/gpg", -o, /run/docker.key]
- [apt-key, add, /run/docker.key]
sources:
docker:
source: "deb [arch=amd64] https://download.docker.com/linux/ubuntu $RELEASE stable"
sources:
docker:
source: "deb [arch=amd64] https://download.docker.com/linux/ubuntu $RELEASE stable"
+runcmd:
+ - [pip3, install, tox]
+ - [bash, /root/mass-pnf-sim_run.sh]
properties:
config:
get_file: cloud-config.yaml
properties:
config:
get_file: cloud-config.yaml
+ sim_script:
+ type: OS::Heat::SoftwareConfig
+ properties:
+ config:
+ get_file: mass-pnf-sim_run.sh
+ sim_script_file:
+ type: OS::Heat::CloudConfig
+ properties:
+ cloud_config:
+ write_files:
+ - path: /root/mass-pnf-sim_run.sh
+ content:
+ get_attr: [sim_script, config]
simulator_floating_ip:
type: OS::Neutron::FloatingIP
properties:
simulator_floating_ip:
type: OS::Neutron::FloatingIP
properties:
get_param: float_net_id
port_id:
get_attr: [simulator, addresses, get_param: instance_net_id, 0, port]
get_param: float_net_id
port_id:
get_attr: [simulator, addresses, get_param: instance_net_id, 0, port]
+ cloud_config:
+ type: OS::Heat::MultipartMime
+ properties:
+ parts:
+ - config:
+ get_resource: config
+ - config:
+ get_resource: sim_script_file
simulator:
type: OS::Nova::Server
properties:
simulator:
type: OS::Nova::Server
properties:
get_param: instance_net_id
user_data_format: RAW
user_data:
get_param: instance_net_id
user_data_format: RAW
user_data:
+ get_resource: cloud_config
outputs:
simulator_instance_id:
description: ID of the simulator instance
outputs:
simulator_instance_id:
description: ID of the simulator instance
--- /dev/null
+#!/bin/bash
+pushd /root
+git clone https://git.onap.org/integration
+pushd integration/test/mocks/mass-pnf-sim
+./setup.sh
+source .tox/MassPnfSim-runtime/bin/activate