You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cloudstack.apache.org by isoutham <gi...@git.apache.org> on 2015/05/19 21:12:57 UTC
[GitHub] cloudstack pull request: Pep8 and some unit tests
GitHub user isoutham opened a pull request:
https://github.com/apache/cloudstack/pull/265
Pep8 and some unit tests
Fixes up a bunch of pep8 failure (trying to get rid of some jenkins failures)
Also the first steps to a unit testing framework for the python code in the systemvm
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/isoutham/cloudstack feature_fix_pep8
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/cloudstack/pull/265.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #265
----
commit ab915b6c921452fa7999c1f882add4ea3a82419a
Author: Ian Southam <is...@schubergphilis.com>
Date: 2015-05-19T12:54:38Z
Allow forward to fix port forwarding rules
----
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] cloudstack pull request: Pep8 and some unit tests
Posted by wilderrodrigues <gi...@git.apache.org>.
Github user wilderrodrigues commented on the pull request:
https://github.com/apache/cloudstack/pull/265#issuecomment-103829579
@bhaisaab
For some reason this PR got the same commit of the previous PR (#262). @isoutham told me to ignore the previous one.
So I'm now testing this and it LGTM so far. I will just test redundant VPC and merge it. Below few details of the tests I have done manually:
* Create VPC
* Create Tier
* Create ACL + 2 rules
* Associate ACL with Tier
* Create VM
* Acquire new IP + Add PF rule
Then ping + ssh
[wrodrigues@mct-wrodrigues cloudstack]$ ping 192.168.23.8
PING 192.168.23.8 (192.168.23.8) 56(84) bytes of data.
64 bytes from 192.168.23.8: icmp_seq=1 ttl=64 time=3.24 ms
64 bytes from 192.168.23.8: icmp_seq=2 ttl=64 time=3.76 ms
64 bytes from 192.168.23.8: icmp_seq=3 ttl=64 time=3.96 ms
64 bytes from 192.168.23.8: icmp_seq=4 ttl=64 time=4.08 ms
^C
--- 192.168.23.8 ping statistics ---
4 packets transmitted, 4 received, 0% packet loss, time 3004ms
rtt min/avg/max/mdev = 3.241/3.762/4.080/0.330 ms
[wrodrigues@mct-wrodrigues cloudstack]$ ssh root@192.168.23.8
The authenticity of host '192.168.23.8 (192.168.23.8)' can't be established.
ECDSA key fingerprint is 3f:64:cc:0f:72:09:9a:e4:dd:c3:1b:a0:0c:17:f7:db.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added '192.168.23.8' (ECDSA) to the list of known hosts.
root@192.168.23.8's password:
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] cloudstack pull request: Pep8 and some unit tests
Posted by asfgit <gi...@git.apache.org>.
Github user asfgit closed the pull request at:
https://github.com/apache/cloudstack/pull/265
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] cloudstack pull request: Pep8 and some unit tests
Posted by bhaisaab <gi...@git.apache.org>.
Github user bhaisaab commented on a diff in the pull request:
https://github.com/apache/cloudstack/pull/265#discussion_r30681931
--- Diff: systemvm/patches/debian/config/opt/cloud/bin/configure.py ---
@@ -555,35 +558,47 @@ def forward_vr(self, rule):
self.portsToString(rule['internal_ports'], '-')
)
fw4 = "-j SNAT --to-source %s -A POSTROUTING -s %s -d %s/32 -o %s -p %s -m %s --dport %s" % \
- ( self.getGatewayByIp(rule['internal_ip']),
+ (
+ self.getGatewayByIp(rule['internal_ip']),
self.getNetworkByIp(rule['internal_ip']),
rule['internal_ip'],
self.getDeviceByIp(rule['internal_ip']),
rule['protocol'],
rule['protocol'],
self.portsToString(rule['internal_ports'], ':')
- )
+ )
fw5 = "-A PREROUTING -d %s/32 -i %s -p %s -m %s --dport %s -j MARK --set-xmark %s/0xffffffff" % \
- ( rule['public_ip'],
+ (
+ rule['public_ip'],
self.getDeviceByIp(rule['public_ip']),
rule['protocol'],
rule['protocol'],
self.portsToString(rule['public_ports'], ':'),
hex(int(self.getDeviceByIp(rule['public_ip'])[3:]))
- )
+ )
fw6 = "-A PREROUTING -d %s/32 -i %s -p %s -m %s --dport %s -m state --state NEW -j CONNMARK --save-mark --nfmask 0xffffffff --ctmask 0xffffffff" % \
- ( rule['public_ip'],
+ (
+ rule['public_ip'],
self.getDeviceByIp(rule['public_ip']),
rule['protocol'],
rule['protocol'],
self.portsToString(rule['public_ports'], ':'),
- )
+ )
+ fw7 = "-A FORWARD -i %s -o %s -p %s -m %s --dport %s -m state --state NEW -j ACCEPT" % \
--- End diff --
@isoutham this PR says pep8/unit test fixes, why are we adding a forwarding rule here?
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] cloudstack pull request: Pep8 and some unit tests
Posted by wilderrodrigues <gi...@git.apache.org>.
Github user wilderrodrigues commented on the pull request:
https://github.com/apache/cloudstack/pull/265#issuecomment-103640249
It seems this PR came with the same commit as the previous one, that's why Travis is now building the #262 again.
Did you create a second PR with the same commit + extra fixes? Should we just ignore the previous one?
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---
[GitHub] cloudstack pull request: Pep8 and some unit tests
Posted by isoutham <gi...@git.apache.org>.
Github user isoutham commented on the pull request:
https://github.com/apache/cloudstack/pull/265#issuecomment-103648791
It looks like I have somehow managed to put the second PR in the first (was
a seperate branch) not quite sure what I did here.
Ignore the first and treat it as one I would say but if you feel otherwise,
let me know.
On 19 May 2015 at 21:20, Wilder Rodrigues <no...@github.com> wrote:
> It seems this PR came with the same commit as the previous one, that's why
> Travis is now building the #262
> <https://github.com/apache/cloudstack/pull/262> again.
>
> Did you create a second PR with the same commit + extra fixes? Should we
> just ignore the previous one?
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/apache/cloudstack/pull/265#issuecomment-103640249>.
>
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---