Skip to content

Commit

Permalink
Merge pull request #10 from clouddrove/PROX-68
Browse files Browse the repository at this point in the history
update in 0.15
  • Loading branch information
Nikita Dugar authored Jun 18, 2021
2 parents e73bfbc + 973df32 commit 45863b7
Show file tree
Hide file tree
Showing 9 changed files with 51 additions and 17 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/readme.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
python-version: '3.x'

- name: 'create readme'
uses: 'clouddrove/github-actions@v6.0'
uses: 'clouddrove/github-actions@v7.0'
with:
actions_subcommand: 'readme'
github_token: '${{ secrets.GITHUB}}'
Expand All @@ -35,7 +35,7 @@ jobs:
continue-on-error: true

- name: 'push readme'
uses: 'clouddrove/github-actions@v6.0'
uses: 'clouddrove/github-actions@v7.0'
continue-on-error: true
with:
actions_subcommand: 'push'
Expand Down
41 changes: 36 additions & 5 deletions .github/workflows/terraform.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
uses: actions/checkout@v2.3.4

- name: 'Terraform Format'
uses: 'clouddrove/github-actions@v6.0'
uses: 'clouddrove/github-actions@v7.0'
with:
actions_subcommand: 'fmt'

Expand All @@ -32,13 +32,13 @@ jobs:
aws-region: us-east-2

- name: 'Terraform init'
uses: 'clouddrove/github-actions@v6.0'
uses: 'clouddrove/github-actions@v7.0'
with:
actions_subcommand: 'init'
tf_actions_working_dir: ./_example

- name: 'Terraform validate'
uses: 'clouddrove/github-actions@v6.0'
uses: 'clouddrove/github-actions@v7.0'
with:
actions_subcommand: 'validate'
tf_actions_working_dir: ./_example
Expand All @@ -51,7 +51,7 @@ jobs:
uses: actions/checkout@v2.3.4

- name: 'Terraform init'
uses: 'clouddrove/github-actions@v6.0'
uses: 'clouddrove/github-actions@v7.0'
with:
actions_subcommand: 'init'
tf_actions_working_dir: ./_example
Expand All @@ -64,7 +64,38 @@ jobs:
aws-region: us-east-2

- name: 'Terraform plan'
uses: 'clouddrove/github-actions@v6.0'
uses: 'clouddrove/github-actions@v7.0'
with:
actions_subcommand: 'plan'
tf_actions_working_dir: ./_example

pre-commit:
name: 'Pre-Commit'
needs:
- fmt
- plan
- validate

runs-on: ubuntu-latest
steps:
- name: 'Checkout'
uses: actions/checkout@v2.3.4

- name: 'Install Tflint'
run: |
curl https://raw.githubusercontent.com/terraform-linters/tflint/master/install_linux.sh | bash
- name: 'Pre-Commit 🔎'
uses: pre-commit/action@v2.0.3
continue-on-error: true

- name: 'Slack Notification'
uses: clouddrove/action-slack@v2
with:
status: ${{ job.status }}
fields: repo,author
author_name: 'CloudDrove'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # required
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_TERRAFORM }} # required
if: always()
2 changes: 1 addition & 1 deletion .github/workflows/terratest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
aws-region: us-east-2

- name: 'Terratest'
uses: 'clouddrove/github-actions@v6.0'
uses: 'clouddrove/github-actions@v7.0'
with:
actions_subcommand: 'terratest'
if: ${{ github.event.label.name == 'terratest' }}
Expand Down
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
Terraform AWS Iam User
</h1>

<p align="center" style="font-size: 1.2rem;">
<p align="center" style="font-size: 1.2rem;">
Terraform module to create Iam user resource on AWS.
</p>

Expand Down Expand Up @@ -38,7 +38,7 @@
<hr>


We eat, drink, sleep and most importantly love **DevOps**. We are working towards strategies for standardizing architecture while ensuring security for the infrastructure. We are strong believer of the philosophy <b>Bigger problems are always solved by breaking them into smaller manageable problems</b>. Resonating with microservices architecture, it is considered best-practice to run database, cluster, storage in smaller <b>connected yet manageable pieces</b> within the infrastructure.
We eat, drink, sleep and most importantly love **DevOps**. We are working towards strategies for standardizing architecture while ensuring security for the infrastructure. We are strong believer of the philosophy <b>Bigger problems are always solved by breaking them into smaller manageable problems</b>. Resonating with microservices architecture, it is considered best-practice to run database, cluster, storage in smaller <b>connected yet manageable pieces</b> within the infrastructure.

This module is basically combination of [Terraform open source](https://www.terraform.io/) and includes automatation tests and examples. It also helps to create and improve your infrastructure with minimalistic code instead of maintaining the whole infrastructure code yourself.

Expand All @@ -49,7 +49,7 @@ We have [*fifty plus terraform modules*][terraform_modules]. A few of them are c

## Prerequisites

This module has a few dependencies:
This module has a few dependencies:

- [Terraform 0.13](https://learn.hashicorp.com/terraform/getting-started/install.html)
- [Go](https://golang.org/doc/install)
Expand Down Expand Up @@ -133,7 +133,7 @@ Here is an example of how you can use this module in your inventory structure:


## Testing
In this module testing is performed with [terratest](https://github.com/gruntwork-io/terratest) and it creates a small piece of infrastructure, matches the output like ARN, ID and Tags name etc and destroy infrastructure in your AWS account. This testing is written in GO, so you need a [GO environment](https://golang.org/doc/install) in your system.
In this module testing is performed with [terratest](https://github.com/gruntwork-io/terratest) and it creates a small piece of infrastructure, matches the output like ARN, ID and Tags name etc and destroy infrastructure in your AWS account. This testing is written in GO, so you need a [GO environment](https://golang.org/doc/install) in your system.

You need to run the following command in the testing folder:
```hcl
Expand All @@ -142,7 +142,7 @@ You need to run the following command in the testing folder:



## Feedback
## Feedback
If you come accross a bug or have any feedback, please log it in our [issue tracker](https://github.com/clouddrove/terraform-aws-iam-user/issues), or feel free to drop us an email at [hello@clouddrove.com](mailto:hello@clouddrove.com).

If you have found it worth your time, go ahead and give us a ★ on [our GitHub](https://github.com/clouddrove/terraform-aws-iam-user)!
Expand Down
4 changes: 2 additions & 2 deletions README.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ github_repo: clouddrove/terraform-aws-iam-user
# Badges to display
badges:
- name: "Terraform"
image: "https://img.shields.io/badge/Terraform-v0.14-green"
image: "https://img.shields.io/badge/Terraform-v0.15-green"
url: "https://www.terraform.io"
- name: "Licence"
image: "https://img.shields.io/badge/License-MIT-blue.svg"
Expand All @@ -38,7 +38,7 @@ usage : |-
```hcl
module "iam-user" {
source = "clouddrove/iam-user/aws"
version = "0.14.0"
version = "0.15.0"
name = "iam-user"
environment = "test"
label_order = ["name","environment"]
Expand Down
1 change: 1 addition & 0 deletions _example/outputs.tf
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ output "key_id" {
output "secret" {
value = module.iam-user.*.secret
description = "The ARN assigned by AWS for this user."
sensitive = true
}

output "tags" {
Expand Down
3 changes: 2 additions & 1 deletion main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@


module "labels" {
source = "git::https://github.com/clouddrove/terraform-labels.git?ref=tags/0.14.0"
source = "clouddrove/labels/aws"
version = "0.15.0"

name = var.name
environment = var.environment
Expand Down
1 change: 1 addition & 0 deletions outputs.tf
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ output "key_id" {
output "secret" {
value = var.pgp_key == "" ? join("", aws_iam_access_key.default.*.secret) : join("", aws_iam_access_key.default.*.encrypted_secret)
description = "The secret access key. Note that this will be written to the state file. Please supply a pgp_key instead, which will prevent the secret from being stored in plain text."
sensitive = true
}

output "tags" {
Expand Down
2 changes: 1 addition & 1 deletion variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ variable "name" {
}
variable "repository" {
type = string
default = "https://registry.terraform.io/modules/clouddrove/iam-user/aws"
default = "https://github.com/clouddrove/terraform-aws-iam-user"
description = "Terraform current module repo"
}

Expand Down

0 comments on commit 45863b7

Please sign in to comment.