Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
T
tun
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Locked Files
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Security & Compliance
Security & Compliance
Dependency List
License Compliance
Packages
Packages
List
Container Registry
Analytics
Analytics
CI / CD
Code Review
Insights
Issues
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Railgun
tun
Commits
1feb0cf7
Commit
1feb0cf7
authored
Mar 30, 2022
by
nanahira
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add prepare
parent
49d7ca7d
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
26 additions
and
47 deletions
+26
-47
ansible/configure.yaml
ansible/configure.yaml
+2
-21
ansible/refresh-localnet.yaml
ansible/refresh-localnet.yaml
+2
-6
ansible/routing.yaml
ansible/routing.yaml
+2
-20
ansible/tasks/prepare.yaml
ansible/tasks/prepare.yaml
+20
-0
No files found.
ansible/configure.yaml
View file @
1feb0cf7
---
---
-
hosts
:
wg
-
hosts
:
wg
tasks
:
tasks
:
-
name
:
load vars
-
name
:
prepare
include_vars
:
import_tasks
:
./tasks/prepare.yaml
file
:
'
../result/{{item}}.yaml'
with_items
:
-
global-vars
-
vars-{{inventory_hostname_short}}
-
name
:
directory
-
name
:
directory
file
:
file
:
path
:
'
{{ansible_user_dir}}/nextgen-network/{{item}}'
path
:
'
{{ansible_user_dir}}/nextgen-network/{{item}}'
...
@@ -16,21 +12,6 @@
...
@@ -16,21 +12,6 @@
-
scripts
-
scripts
-
services
-
services
-
ipsets
-
ipsets
-
name
:
check iptables Type
become
:
true
shell
:
iptables --version | grep nf_tables
register
:
iptables_type_result
failed_when
:
iptables_type_result.rc >
1
changed_when
:
false
when
:
iptables_type == 'auto'
-
name
:
use iptables-legacy
set_fact
:
iptables_type
:
legacy
when
:
iptables_type == 'auto' and iptables_type_result.rc ==
1
-
name
:
use iptables-nft
set_fact
:
iptables_type
:
nft
when
:
iptables_type == 'auto' and iptables_type_result.rc ==
0
-
name
:
post scripts
-
name
:
post scripts
template
:
template
:
src
:
scripts/{{item}}.sh.j2
src
:
scripts/{{item}}.sh.j2
...
...
ansible/refresh-localnet.yaml
View file @
1feb0cf7
---
---
-
hosts
:
wg
-
hosts
:
wg
tasks
:
tasks
:
-
name
:
load vars
-
name
:
prepare
include_vars
:
import_tasks
:
./tasks/prepare.yaml
file
:
'
../result/{{item}}.yaml'
with_items
:
-
global-vars
-
vars-{{inventory_hostname_short}}
-
name
:
post scripts
-
name
:
post scripts
template
:
template
:
src
:
scripts/{{item}}.sh.j2
src
:
scripts/{{item}}.sh.j2
...
...
ansible/routing.yaml
View file @
1feb0cf7
-
hosts
:
wg
-
hosts
:
wg
remote_user
:
root
remote_user
:
root
tasks
:
tasks
:
-
name
:
load vars
-
name
:
prepare
include_vars
:
import_tasks
:
./tasks/prepare.yaml
file
:
'
../result/{{item}}.yaml'
with_items
:
-
global-vars
-
vars-{{inventory_hostname_short}}
-
name
:
check iptables Type
become
:
true
shell
:
iptables --version | grep nf_tables
register
:
iptables_type_result
failed_when
:
iptables_type_result.rc >
1
when
:
iptables_type == 'auto'
-
name
:
use iptables-legacy
set_fact
:
iptables_type
:
legacy
when
:
iptables_type == 'auto' and iptables_type_result.rc ==
1
-
name
:
use iptables-nft
set_fact
:
iptables_type
:
nft
when
:
iptables_type == 'auto' and iptables_type_result.rc ==
0
-
name
:
post scripts
-
name
:
post scripts
template
:
template
:
src
:
scripts/{{item}}.sh.j2
src
:
scripts/{{item}}.sh.j2
...
...
ansible/tasks/prepare.yaml
0 → 100644
View file @
1feb0cf7
-
name
:
load vars
include_vars
:
file
:
'
../../result/{{item}}.yaml'
with_items
:
-
global-vars
-
vars-{{inventory_hostname_short}}
-
name
:
check iptables Type
become
:
true
shell
:
iptables --version | grep nf_tables
register
:
iptables_type_result
failed_when
:
iptables_type_result.rc >
1
when
:
iptables_type == 'auto'
-
name
:
use iptables-legacy
set_fact
:
iptables_type
:
legacy
when
:
iptables_type == 'auto' and iptables_type_result.rc ==
1
-
name
:
use iptables-nft
set_fact
:
iptables_type
:
nft
when
:
iptables_type == 'auto' and iptables_type_result.rc ==
0
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment