Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
K
Kayobe
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Very Demiurge Very Mindful
Kayobe
Commits
735b10f3
Commit
735b10f3
authored
5 years ago
by
Zuul
Committed by
Gerrit Code Review
5 years ago
Browse files
Options
Downloads
Plain Diff
Merge "Fix kayobe overcloud provision without seed in limit"
parents
3bae0fd2
e0ff12ea
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
ansible/kolla-bifrost-hostvars.yml
+28
-34
28 additions, 34 deletions
ansible/kolla-bifrost-hostvars.yml
with
28 additions
and
34 deletions
ansible/kolla-bifrost-hostvars.yml
+
28
−
34
View file @
735b10f3
---
---
# Update the Bifrost inventory with the IP allocation and other variables.
# Update the Bifrost inventory with the IP allocation and other variables.
-
name
:
Ensure the Bifrost overcloud inventory is initialised
hosts
:
seed
gather_facts
:
no
tags
:
-
kolla-bifrost-hostvars
tasks
:
-
name
:
Ensure the Bifrost host variables directory exists
file
:
path
:
"
/etc/kolla/bifrost/inventory/host_vars"
state
:
directory
become
:
True
-
name
:
Ensure the Bifrost inventory exists
file
:
path
:
"
/etc/kolla/bifrost/inventory/bifrost_inventory.py"
src
:
"
/bifrost/playbooks/inventory/bifrost_inventory.py"
state
:
link
# This file should only exist within the bifrost_deploy container.
force
:
True
become
:
True
-
name
:
Ensure the Bifrost overcloud inventory is populated
-
name
:
Ensure the Bifrost overcloud inventory is populated
hosts
:
overcloud
hosts
:
overcloud
gather_facts
:
no
gather_facts
:
no
tags
:
tags
:
-
kolla-bifrost-hostvars
-
kolla-bifrost-hostvars
become
:
true
vars
:
vars
:
seed_host
:
"
{{
groups['seed'][0]
}}"
seed_host
:
"
{{
groups['seed'][0]
}}"
# NOTE: Without this, the seed's ansible_host variable will not be
# respected when using delegate_to.
ansible_host
:
"
{{
hostvars[seed_host].ansible_host
|
default(seed_host)
}}"
bifrost_hostvars
:
bifrost_hostvars
:
addressing_mode
:
static
addressing_mode
:
static
ipv4_interface_mac
:
"
{%
raw
%}{{
extra.pxe_interface_mac
|
default
}}{%
endraw
%}"
ipv4_interface_mac
:
"
{%
raw
%}{{
extra.pxe_interface_mac
|
default
}}{%
endraw
%}"
...
@@ -42,17 +25,28 @@
...
@@ -42,17 +25,28 @@
network_mtu
:
"
{{
admin_oc_net_name
|
net_mtu
or
'1500'
}}"
network_mtu
:
"
{{
admin_oc_net_name
|
net_mtu
or
'1500'
}}"
vlan_id
:
"
{{
''
if
admin_oc_net_name
==
provision_oc_net_name
else
(admin_oc_net_name
|
net_vlan)
}}"
vlan_id
:
"
{{
''
if
admin_oc_net_name
==
provision_oc_net_name
else
(admin_oc_net_name
|
net_vlan)
}}"
tasks
:
tasks
:
-
name
:
Ensure the Bifrost host variable files exist
-
block
:
copy
:
-
name
:
Ensure the Bifrost host variables directory exists
content
:
|
file
:
---
path
:
"
/etc/kolla/bifrost/inventory/host_vars"
# This file is managed via Ansible. Do not edit.
state
:
directory
# Bifrost host variables for {{ inventory_hostname }}
run_once
:
true
{{ bifrost_hostvars | to_nice_yaml }}
dest
:
"
/etc/kolla/bifrost/inventory/host_vars/{{
inventory_hostname
}}"
-
name
:
Ensure the Bifrost inventory exists
file
:
path
:
"
/etc/kolla/bifrost/inventory/bifrost_inventory.py"
src
:
"
/bifrost/playbooks/inventory/bifrost_inventory.py"
state
:
link
# This file should only exist within the bifrost_deploy container.
force
:
True
run_once
:
true
-
name
:
Ensure the Bifrost host variable files exist
copy
:
content
:
|
---
# This file is managed via Ansible. Do not edit.
# Bifrost host variables for {{ inventory_hostname }}
{{ bifrost_hostvars | to_nice_yaml }}
dest
:
"
/etc/kolla/bifrost/inventory/host_vars/{{
inventory_hostname
}}"
delegate_to
:
"
{{
seed_host
}}"
delegate_to
:
"
{{
seed_host
}}"
vars
:
# NOTE: Without this, the seed's ansible_host variable will not be
# respected when using delegate_to.
ansible_host
:
"
{{
hostvars[seed_host].ansible_host
|
default(seed_host)
}}"
become
:
True
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment