Reputation: 11017
I need to trigger a Jenkins build that will access a Chef server installed on an EC2 instance which is behind a VPN.
Potentially the security group could be relaxed to allow the Jenkins server's IP, but I hope to avoid that.
Is there a way to connect Jenkins to a VPN while executing a build?
A Google search of this yielded this plugin on github but in its Jenkins page there's no real information nor is it downloadable.
Upvotes: 1
Views: 1659
Reputation: 161
create OpenVPN ec2 instance from aws marketplace and create ec2 instance for ur jenkin and add the security group of ur openvpn instance to jenkin instance .. so that once u connect your openvpn then only u access ur jenkin instance...
Note: Openvpn instance is not free of cost
Upvotes: 0
Reputation: 7246
You should create a NAT gateway in the account where Jenkins is installed. NAT Gateway will have Elastic IP and all the resources in this VPC (including Jenkins) will reach to Internet using this EIP. Then you configure your target security group to allow connections from this Elastic IP.
Upvotes: 1
Reputation: 58768
One way to do this is to have a well-secured bastion server acting as an interface into the VPC and having access to tunnel (with SSH, VPN or something else) only the kind of requests you want to allow in.
Upvotes: 1