-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathmain.tf-jenkins
148 lines (123 loc) · 3.06 KB
/
main.tf-jenkins
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
// Mandatory variables for terracumber
variable "URL_PREFIX" {
type = "string"
default = "https://ci.suse.de/view/Manager/view/Uyuni/job/uyuni-master-cucumber-NUE"
}
variable "CUCUMBER_COMMAND" {
type = "string"
default = "export PRODUCT='Uyuni' && cd /root/spacewalk/testsuite && rake cucumber:testsuite"
}
variable "CUCUMBER_GITREPO" {
type = "string"
default = "https://github.com/uyuni-project/uyuni.git"
}
variable "CUCUMBER_BRANCH" {
type = "string"
default = "master"
}
variable "CUCUMBER_RESULTS" {
type = "string"
default = "/root/spacewalk/testsuite"
}
variable "MAIL_SUBJECT" {
type = "string"
default = "Results Uyuni-Master $status: $tests scenarios ($failures failed, $errors errors, $skipped skipped, $passed passed)"
}
variable "MAIL_TEMPLATE" {
type = "string"
default = "templates/mail-template-jenkins.txt"
}
variable "MAIL_SUBJECT_ENV_FAIL" {
type = "string"
default = "Results Uyuni-Master: Environment setup failed"
}
variable "MAIL_TEMPLATE_ENV_FAIL" {
type = "string"
default = "templates/mail-template-jenkins-env-fail.txt"
}
variable "MAIL_FROM" {
type = "string"
default = "[email protected]"
}
variable "MAIL_TO" {
type = "string"
default = "juliogonzalez@localhost"
}
// sumaform specific variables
variable "SCC_USER" {
type = "string"
}
variable "SCC_PASSWORD" {
type = "string"
}
variable "GIT_USER" {
type = "string"
default = null // Not needed for master, as it is public
}
variable "GIT_PASSWORD" {
type = "string"
default = null // Not needed for master, as it is public
}
provider "libvirt" {
uri = "qemu:///system"
}
module "cucumber_testsuite" {
source = "./modules/cucumber_testsuite"
product_version = "uyuni-master"
// Cucumber repository configuration for the controller
git_username = var.GIT_USER
git_password = var.GIT_PASSWORD
git_repo = var.CUCUMBER_GITREPO
branch = var.CUCUMBER_BRANCH
cc_username = var.SCC_USER
cc_password = var.SCC_PASSWORD
images = ["centos7o", "opensuse150o", "opensuse151o", "opensuse152o", "sles15sp1o", "sles15sp2o", "ubuntu1804o"]
use_avahi = false
name_prefix = "uyuni-master-"
domain = "tf.local"
from_email = "[email protected]"
// portus_uri = "portus.mgr.suse.de:5000/cucutest"
// portus_username = "cucutest"
// portus_password = "cucusecret"
// server_http_proxy = "galaxy-proxy.mgr.suse.de:3128"
host_settings = {
ctl = {
}
srv = {
}
pxy = {
}
cli-sles12sp4 = {
image = "sles15sp1"
name = "cli-sles15"
}
min-sles12sp4 = {
image = "sles15sp1"
name = "min-sles15"
}
minssh-sles12sp4 = {
image = "sles15sp1"
name = "minssh-sles15"
}
min-centos7 = {
}
min-ubuntu1804 = {
}
min-pxeboot = {
present = true
image = "sles15sp1"
}
min-kvm = {
image = "opensuse151"
}
}
provider_settings = {
bridge = null
pool = "default"
network_name = "default"
additional_network = null
}
}
output "configuration" {
value = module.cucumber_testsuite.configuration
}