Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
K
kypo-interface
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Terraform modules
Analyze
Contributor analytics
Repository analytics
Insights
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
MUNI-KYPO-CRP
backend-python
ansible-networking-stage
kypo-interface
Commits
0d874a34
Commit
0d874a34
authored
1 year ago
by
Zdeněk Vydra
Browse files
Options
Downloads
Patches
Plain Diff
OPNsense use static networking for all interfaces
parent
6ddb1541
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
tasks/FreeBSD.yml
+2
-10
2 additions, 10 deletions
tasks/FreeBSD.yml
tasks/interface-FreeBSD.yml
+0
-16
0 additions, 16 deletions
tasks/interface-FreeBSD.yml
with
2 additions
and
26 deletions
tasks/FreeBSD.yml
+
2
−
10
View file @
0d874a34
...
...
@@ -10,14 +10,6 @@
loop
:
'
{{
kypo_interface_interfaces
}}'
when
:
kypo_interface_clean is defined and kypo_interface_clean
-
name
:
configure interfaces
include_tasks
:
interface-FreeBSD.yml
vars
:
kypo_interface_device
:
'
{{
kypo_interface_item.kypo_interface_device
}}'
loop_control
:
loop_var
:
kypo_interface_item
loop
:
'
{{
kypo_interface_interfaces
}}'
-
name
:
get default gateway
set_fact
:
kypo_interface_default_gateway
:
'
{{
kypo_interface_interfaces
|
selectattr("kypo_interface_default_gateway",
"defined")
|
first
}}'
...
...
@@ -68,7 +60,7 @@
delegate_to
:
localhost
-
set_fact
:
interfaces
:
"
{{
ansible_interfaces
|
select('match',
'^(vtnet)[
2
-9]+')
|
list
}}"
interfaces
:
"
{{
ansible_interfaces
|
select('match',
'^(vtnet)[
0
-9]+')
|
list
}}"
-
set_fact
:
interface_configs
:
|-
...
...
@@ -78,7 +70,7 @@
{%- endfor -%}
]
-
name
:
set static addressing on
user defined
networks
-
name
:
set static addressing on
all
networks
xml
:
path
:
'
{{
kypo_interface_opnsense_local_config_file
}}'
xpath
:
'
/opnsense/interfaces/{{
item.0.if
}}/{{
item.1.key
}}'
...
...
This diff is collapsed.
Click to expand it.
tasks/interface-FreeBSD.yml
deleted
100644 → 0
+
0
−
16
View file @
6ddb1541
-
name
:
prepare interface configuration
set_fact
:
kypo_interface_config
:
if
:
'
{{
kypo_interface_device
}}'
ipaddr
:
dhcp
mtu
:
'
{{
kypo_interface_mtu
}}'
enable
:
1
-
name
:
configure interface
xml
:
path
:
'
{{
kypo_interface_opnsense_local_config_file
}}'
xpath
:
'
/opnsense/interfaces/{{
kypo_interface_device
}}/{{
item.key
}}'
value
:
'
{{
item.value
}}'
pretty_print
:
yes
delegate_to
:
localhost
loop
:
'
{{
kypo_interface_config
|
dict2items
}}'
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