Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
itminedu
synnefo
Commits
0dbcf9c2
Commit
0dbcf9c2
authored
Jul 26, 2013
by
Ilias Tsitsimpis
Browse files
ci: Include commands between $()
parent
2296e2f6
Changes
1
Hide whitespace changes
Inline
Side-by-side
ci/utils.py
View file @
0dbcf9c2
...
...
@@ -208,8 +208,8 @@ class SynnefoCI(object):
accept_ssh_from
=
self
.
config
.
get
(
'Global'
,
'filter_access_network'
)
self
.
logger
.
debug
(
"Block ssh except from %s"
%
accept_ssh_from
)
cmd
=
"""
local_ip=/sbin/ifconfig eth0 | grep 'inet addr:' |
\
cut -d':' -f2 | cut -d' ' -f1
local_ip=
$(
/sbin/ifconfig eth0 | grep 'inet addr:' |
\
cut -d':' -f2 | cut -d' ' -f1
)
iptables -A INPUT -s localhost -j ACCEPT
iptables -A INPUT -s $local_ip -j ACCEPT
iptables -A INPUT -s {0} -p tcp --dport 22 -j ACCEPT
...
...
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