Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
O
otree-ansible
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
wiso-forschungslabor
otree-ansible
Commits
e4c70e59
Commit
e4c70e59
authored
5 years ago
by
Gallenkamp, Fabian
Browse files
Options
Downloads
Patches
Plain Diff
Make ufw incoming ssh connection ip-ranges configurable;
parent
f9e86b69
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
configure_ufw.yml
+7
-18
7 additions, 18 deletions
configure_ufw.yml
group_vars/otree_servers.yml.example
+3
-0
3 additions, 0 deletions
group_vars/otree_servers.yml.example
with
10 additions
and
18 deletions
configure_ufw.yml
+
7
−
18
View file @
e4c70e59
...
@@ -3,43 +3,32 @@
...
@@ -3,43 +3,32 @@
become
:
true
become
:
true
hosts
:
all
hosts
:
all
tasks
:
tasks
:
# setup ufw ssh rules
# setup ufw ssh
exception/limiting
rules
-
name
:
allow ssh access from
uni-hamburg
ip range
-
name
:
allow ssh access from
specified
ip range
s
ufw
:
ufw
:
rule
:
allow
rule
:
allow
app
:
OpenSSH
app
:
OpenSSH
from_ip
:
134.100.0.0/16
from_ip
:
"
{{
item
}}"
with_items
:
"
{{
ufw_ssh_allowed_from
}}"
-
name
:
allow ssh access from internal ip range a)
ufw
:
rule
:
allow
app
:
OpenSSH
from_ip
:
192.168.0.0/16
-
name
:
allow ssh access from internal ip range b)
ufw
:
rule
:
allow
app
:
OpenSSH
from_ip
:
172.16.0.0/12
-
name
:
rate limiting ssh access
-
name
:
rate limiting ssh access
ufw
:
ufw
:
rule
:
limit
rule
:
limit
app
:
OpenSSH
app
:
OpenSSH
# setup nginx web server rule
# setup nginx web server
exception
rule
-
name
:
allow access of nginx webserver from everywhere
-
name
:
allow access of nginx webserver from everywhere
ufw
:
ufw
:
rule
:
allow
rule
:
allow
name
:
Nginx Full
name
:
Nginx Full
# set default rules
# set default
deny
rules
-
name
:
deny any other incoming traffic by default
-
name
:
deny any other incoming traffic by default
ufw
:
ufw
:
state
:
enabled
state
:
enabled
default
:
deny
default
:
deny
direction
:
incoming
direction
:
incoming
# set default allow rule for outgoing, FIXME: do it more granulary (only http/https)
-
name
:
allow any outgoing traffic by default
-
name
:
allow any outgoing traffic by default
ufw
:
ufw
:
state
:
enabled
state
:
enabled
...
...
This diff is collapsed.
Click to expand it.
group_vars/otree_servers.yml.example
+
3
−
0
View file @
e4c70e59
...
@@ -53,3 +53,6 @@ otree_users:
...
@@ -53,3 +53,6 @@ otree_users:
ssl_certificate_path: "/etc/ssl/certs/{{ otree_domain }}.crt"
ssl_certificate_path: "/etc/ssl/certs/{{ otree_domain }}.crt"
ssl_certificate_key_path: "/etc/ssl/private/{{ otree_domain }}.key"
ssl_certificate_key_path: "/etc/ssl/private/{{ otree_domain }}.key"
ufw_ssh_allowed_from:
- "192.168.0.0/16"
- "172.16.0.0/12"
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