Skip to content

Commit

Permalink
Merge pull request #161 from stelligent/develop
Browse files Browse the repository at this point in the history
release 0.2.5
  • Loading branch information
cplee authored Aug 16, 2017
2 parents 52c2b8e + ebe25cc commit 80b6b4b
Show file tree
Hide file tree
Showing 10 changed files with 106 additions and 14 deletions.
3 changes: 3 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
<img src="https://github.com/stelligent/mu/wiki/img/mu.png" width="150">
<br/>

# Contributing to Mu

Help wanted! We'd love your contributions to Mu. Please review the following guidelines before contributing. Also, feel free to propose changes to these guidelines by updating this file and submitting a pull request.
Expand Down
5 changes: 5 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,11 @@ lint: fmt
go vet $(SRC_FILES)
glide novendor | xargs -n1 golint -set_exit_status

nag:
@echo "=== cfn_nag ==="
grep -l AWSTemplateFormatVersion: templates/assets/*.yml |xargs -t -n 1 cfn_nag


test: lint gen
@echo "=== testing ==="
ifneq ($(CIRCLE_TEST_REPORTS),)
Expand Down
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
<img src="https://github.com/stelligent/mu/wiki/img/mu.png" width="150">
<br/>

[![Build Status](https://circleci.com/gh/stelligent/mu.svg?style=shield)](https://circleci.com/gh/stelligent/mu) [![Join the chat at https://gitter.im/stelligent/mu](https://badges.gitter.im/stelligent/mu.svg)](https://gitter.im/stelligent/mu?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) [![Go Report Card](https://goreportcard.com/badge/github.com/stelligent/mu)](https://goreportcard.com/report/github.com/stelligent/mu)


Expand Down Expand Up @@ -35,6 +38,7 @@ Check out the [examples](examples) to see snippets of `mu.yml` configuration fil
* **[HTTPS](examples/elb-https)** - Enable HTTPS on the ALB for an environment
* **[DNS](examples/elb-dns)** - Associate Route53 resource record with ALB for an environment
* **[VPC Target](examples/vpc-target)** - Targeting an existing VPC for an environment
* **[VPN Connection](examples/vpn)** - Demonstration of adding VPN via CloudFormation
* **[Custom CloudFormation](examples/custom-cloudformation)** - Demonstration of adding custom AWS resources via CloudFormation
* **[Traditional Infrastructure](examples/ec2-provider)** - Demonstration of using EC2 + CodeDeploy rather than ECS for running services

Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.2.4
0.2.5
5 changes: 5 additions & 0 deletions examples/vpn/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Examples
These examples are not intended to be run directly. Rather, they serve as a reference that can be consulted when creating your own `mu.yml` files.

For detailed steps to create your own project, check out the [quickstart](https://github.com/stelligent/mu/wiki/Quickstart#steps).

70 changes: 70 additions & 0 deletions examples/vpn/mu.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
---

environments:
- name: prod

templates:
mu-vpc-prod:
Resources:
CustomerGateway:
Type: "AWS::EC2::CustomerGateway"
Properties:
BgpAsn: 65000
IpAddress: 1.1.1.1 # Public IP of remote VPN device
Type: ipsec.1
VirtualPrivateGateway:
Type: "AWS::EC2::VPNGateway"
Properties:
Type: ipsec.1
VPNconnection:
Type: "AWS::EC2::VPNConnection"
Properties:
Type: ipsec.1
CustomerGatewayId:
Ref: CustomerGateway
StaticRoutesOnly: true
VpnGatewayId:
Ref: VirtualPrivateGateway
DependsOn: VPCGatewayAttachment
VPCGatewayAttachment:
Type: "AWS::EC2::VPCGatewayAttachment"
Properties:
VpcId:
Ref: VPC
VpnGatewayId:
Ref: VirtualPrivateGateway
DependsOn: VirtualPrivateGateway
VPNInstanceInboundNetworkAclEntry1:
Type: AWS::EC2::NetworkAclEntry
Properties:
NetworkAclId:
Ref: InstanceNetworkAcl
RuleNumber: '105'
Protocol: '6'
RuleAction: allow
Egress: 'false'
CidrBlock: 10.50.0.0/24 # CIDR at remote network
PortRange:
From: '0'
To: '65535'
VPNInstanceOutboundUdpNetworkAclEntry1:
Type: AWS::EC2::NetworkAclEntry
Properties:
NetworkAclId:
Ref: InstanceNetworkAcl
RuleNumber: '105'
Protocol: '17'
RuleAction: allow
Egress: 'true'
CidrBlock: 10.50.0.0/24 # CIDR at remote network
PortRange:
From: '0'
To: '65535'
VPNRoutePropagation:
Type: "AWS::EC2::VPNGatewayRoutePropagation"
DependsOn: VPCGatewayAttachment
Properties:
RouteTableIds:
- Ref: InstanceRouteTable
VpnGatewayId:
Ref: VirtualPrivateGateway
8 changes: 4 additions & 4 deletions templates/assets.go

Large diffs are not rendered by default.

14 changes: 7 additions & 7 deletions templates/assets/vpc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ Resources:
AvailabilityZone:
Fn::Select:
- 0
- !GetAZs ''
- Fn::GetAZs: ""
Tags:
- Key: Network
Value: Public
Expand Down Expand Up @@ -293,7 +293,7 @@ Resources:
AvailabilityZone:
Fn::Select:
- 0
- !GetAZs ''
- Fn::GetAZs: ""
Tags:
- Key: Network
Value: Private
Expand All @@ -309,7 +309,7 @@ Resources:
AvailabilityZone:
Fn::Select:
- 1
- !GetAZs ''
- Fn::GetAZs: ""
Tags:
- Key: Network
Value: Private
Expand All @@ -325,7 +325,7 @@ Resources:
AvailabilityZone:
Fn::Select:
- 2
- !GetAZs ''
- Fn::GetAZs: ""
Tags:
- Key: Network
Value: Private
Expand Down Expand Up @@ -463,7 +463,7 @@ Resources:
AvailabilityZone:
Fn::Select:
- 0
- !GetAZs ''
- Fn::GetAZs: ""
Tags:
- Key: Network
Value: !If [ IsPublicElb, "Public", "Private" ]
Expand All @@ -479,7 +479,7 @@ Resources:
AvailabilityZone:
Fn::Select:
- 1
- !GetAZs ''
- Fn::GetAZs: ""
Tags:
- Key: Network
Value: !If [ IsPublicElb, "Public", "Private" ]
Expand All @@ -495,7 +495,7 @@ Resources:
AvailabilityZone:
Fn::Select:
- 2
- !GetAZs ''
- Fn::GetAZs: ""
Tags:
- Key: Network
Value: !If [ IsPublicElb, "Public", "Private" ]
Expand Down
2 changes: 1 addition & 1 deletion wiki
Submodule wiki updated from 1ed7aa to dbc502
7 changes: 6 additions & 1 deletion workflows/service_deploy.go
Original file line number Diff line number Diff line change
Expand Up @@ -112,8 +112,13 @@ func (workflow *serviceWorkflow) serviceApplyEc2Params(params map[string]string)
"ConsulServerAutoScalingGroup",
"ElbSecurityGroup",
"ConsulRpcClientSecurityGroup",
"InstanceSubnetIds",
"InstanceSecurityGroup",
} {
params[key] = workflow.envStack.Outputs[key]
}

for _, key := range [...]string{
"InstanceSubnetIds",
} {
params[key] = workflow.envStack.Parameters[key]
}
Expand Down

0 comments on commit 80b6b4b

Please sign in to comment.