mirror of
https://github.com/OpenNebula/one.git
synced 2026-12-03 21:52:31 +09:00
M #-: OneProvision: move ami search to cluster (#1865)
Otherwise there will be duplicites for multiple hosts
This commit is contained in:
1 parent
88c48e2a52
commit
1bcc970ba3
2 files changed
+17
-17
No files matched your search
@@ -1,3 +1,20 @@
|
||||
data "aws_ami" "ubuntu2004" {
|
||||
|
||||
most_recent = true
|
||||
|
||||
filter {
|
||||
name = "name"
|
||||
values = ["ubuntu/images/hvm-ssd/ubuntu-focal-20.04-amd64-server-*"]
|
||||
}
|
||||
|
||||
filter {
|
||||
name = "virtualization-type"
|
||||
values = ["hvm"]
|
||||
}
|
||||
|
||||
owners = ["099720109477"]
|
||||
}
|
||||
|
||||
resource "aws_vpc" "device_<%= obj['ID'] %>" {
|
||||
cidr_block = "<%= provision['CIDR'] ? provision['CIDR'] : '10.0.0.0/16'%>"
|
||||
|
||||
|
||||
@@ -1,20 +1,3 @@
|
||||
data "aws_ami" "ubuntu2004" {
|
||||
|
||||
most_recent = true
|
||||
|
||||
filter {
|
||||
name = "name"
|
||||
values = ["ubuntu/images/hvm-ssd/ubuntu-focal-20.04-amd64-server-*"]
|
||||
}
|
||||
|
||||
filter {
|
||||
name = "virtualization-type"
|
||||
values = ["hvm"]
|
||||
}
|
||||
|
||||
owners = ["099720109477"]
|
||||
}
|
||||
|
||||
resource "aws_instance" "device_<%= obj['ID'] %>" {
|
||||
|
||||
<% if provision['AMI'] == 'default' %>
|
||||
|
||||
Reference in new issue
Block a user