---
-# file: roles/aws/tasks/main.yaml
+# file: tasks/main.yaml
- name: Edit repositories
include_tasks: "{{ ansible_distribution|lower }}_{{ ansible_distribution_release }}.yaml"
---
-# file: roles/aws/tasks/ubuntu_jammy.yaml
+# file: tasks/ubuntu_jammy.yaml
- name: Enable deb-src APT Repository
ansible.builtin.apt_repository:
tags:
- aws-enable-src-repo
-- name: Enable deb-src APT Repository Focal
+- name: Enable deb APT Repository Focal
ansible.builtin.apt_repository:
repo: "deb http://archive.ubuntu.com/ubuntu focal main"
state: "present"
tags: python_env
- role: vpp
tags: vpp
- - role: dpdk
- tags: dpdk
- role: iperf
tags: iperf
- role: docker
tags: docker
+# - role: dpdk
+# tags: dpdk
- role: aws
tags: aws
- role: cleanup
tags: common
- role: python_env
tags: python_env
- - role: dpdk
- tags: dpdk
- role: docker
tags: docker
- role: iperf
tags: iperf
+# - role: dpdk
+# tags: dpdk
- role: aws
tags: aws
- role: trex
-
packer {
required_plugins {
amazon = {
- version = ">= 1.0.1"
+ version = ">= 1.2.6"
source = "github.com/hashicorp/amazon"
}
}
}
+
variable "first_run_commands" {
description = "Commands to run before deployment via remote-exec"
type = list(string)
""
]
}
+
variable "last_run_commands" {
description = "Commands to run after deployment via remote-exec"
type = list(string)
"sudo sed -i 's/Unattended-Upgrade \"1\"/Unattended-Upgrade \"0\"/g' /etc/apt/apt.conf.d/20auto-upgrades"
]
}
+
variable "ansible_file_path" {
description = "Path to Ansible playbook"
type = string
default = "../../fdio.infra.ansible/site.yaml"
}
+
variable "ansible_python_executable" {
description = "Path to Python interpreter"
type = string
default = "/usr/bin/python3"
}
+
variable "ansible_topology_path" {
description = "Path to Ansible playbook which creates a topology file"
type = string
default = "../../fdio.infra.ansible/cloud_topology.yaml"
}
+
variable "ansible_provision_pwd" {
description = "Password used for ansible provisioning (ansible_ssh_pass)"
type = string
default = "Csit1234"
}
+
source "amazon-ebs" "csit_c6gn_ubuntu_jammy_sut" {
ami_name = "csit_c6gn_ubuntu_jammy_sut"
ami_description = "CSIT SUT image based on Ubuntu jammy"
source_ami = "ami-0a875db8a031a9efb"
ssh_username = "ubuntu"
}
+
source "amazon-ebs" "csit_c6gn_ubuntu_jammy_tg" {
ami_name = "csit_c6gn_ubuntu_jammy_tg"
ami_description = "CSIT TG image based on Ubuntu jammy"
source_ami = "ami-0a875db8a031a9efb"
ssh_username = "ubuntu"
}
+
build {
name = "csit_c6gn_ubuntu_jammy_sut-packer"
sources = [
inline = var.last_run_commands
}
}
+
build {
name = "csit_c6gn_ubuntu_jammy_tg-packer"
sources = [
packer {
required_plugins {
amazon = {
- version = ">= 1.0.1"
+ version = ">= 1.2.6"
source = "github.com/hashicorp/amazon"
}
}
force_deregister = true
region = "eu-central-1"
skip_create_ami = false
- source_ami = "ami-065deacbcaac64cf2"
+ source_ami = "ami-04e601abe3e1a910f"
ssh_username = "ubuntu"
}
force_deregister = true
region = "eu-central-1"
skip_create_ami = false
- source_ami = "ami-065deacbcaac64cf2"
+ source_ami = "ami-04e601abe3e1a910f"
ssh_username = "ubuntu"
}