Skip to content

Commit

Permalink
tested version
Browse files Browse the repository at this point in the history
  • Loading branch information
vijay-stephen committed Dec 10, 2024
1 parent 8a881ef commit ab3198a
Show file tree
Hide file tree
Showing 15 changed files with 328 additions and 124 deletions.
54 changes: 0 additions & 54 deletions .github/workflows/pre-commit.yaml

This file was deleted.

16 changes: 8 additions & 8 deletions .github/workflows/snyk.yaml
Original file line number Diff line number Diff line change
@@ -1,35 +1,35 @@
---
name: snyk

on: # yamllint disable-line rule:truthy
on: # yamllint disable-line rule:truthy
push:
branches:
- "**" # matches every branch
- "!main" # excludes main
- '**' # matches every branch
- '!main' # excludes main
pull_request:
branches:
- main

jobs:
security:
runs-on:
- arc
- ubuntu-latest
name: snyk
steps:
- name: checkout
uses: actions/checkout@v3
uses: actions/checkout@v2
- name: Vulnerability scan
uses: snyk/actions/iac@master
with:
command: monitor
args: --severity-threshold=low
- name: Set up Node 18
- name: Set up Node 16
uses: actions/setup-node@v3
with:
node-version: 18
node-version: 16
- name: install Snyk CLI
run: npm install -g snyk
- name: snyk monitor
run: snyk iac test --report --severity-threshold=medium
run: snyk iac test --report
env:
SNYK_TOKEN: ${{ secrets.ARC_SNYK_TOKEN }}
2 changes: 1 addition & 1 deletion .github/workflows/tag-release.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
name: Bump version
on: # yamllint disable-line rule:truthy
on: # yamllint disable-line rule:truthy
push:
branches:
- main
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/tflint.yml → .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
---
name: Test

on: # yamllint disable-line rule:truthy
on: # yamllint disable-line rule:truthy
push:
branches:
- "**" # matches every branch
- "!main" # excludes main
- '**' # matches every branch
- '!main' # excludes main
pull_request:
branches:
- main

jobs:
tflint:
runs-on:
- arc
- ubuntu-latest
name: tflint
steps:
- uses: actions/checkout@master
Expand Down
50 changes: 50 additions & 0 deletions .github/workflows/update-docs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
---
name: Update-docs
on: # yamllint disable-line rule:truthy
push:
branches:
- main
jobs:
transfer-file:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Pushes Readme file
uses: dmnemec/copy_file_to_another_repo_action@main
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
API_TOKEN_GITHUB: ${{ secrets.ARC_DOCS_API_TOKEN_GITHUB }}
with:
source_file: 'README.md'
destination_repo: 'sourcefuse/arc-docs'
destination_folder: 'docs/arc-iac-docs/modules/terraform-aws-arc-db'
user_email: '[email protected]'
user_name: ${{ github.actor }}
commit_message: ${{ github.event.head_commit.message }}
- name: Pushes to another repository
uses: cpina/github-action-push-to-another-repository@main
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
API_TOKEN_GITHUB: ${{ secrets.ARC_DOCS_API_TOKEN_GITHUB }}
with:
source-directory: 'static'
destination-github-username: 'sourcefuse'
destination-repository-name: 'arc-docs'
target-directory: 'docs/arc-iac-docs/modules/terraform-aws-arc-db/static'
user-email: '[email protected]'
user-name: ${{ github.actor }}
target-branch: main
commit-message: ${{ github.event.head_commit.message }}
- name: Pushes Module Usage Guide
uses: dmnemec/copy_file_to_another_repo_action@main
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
API_TOKEN_GITHUB: ${{ secrets.ARC_DOCS_API_TOKEN_GITHUB }}
with:
source_file: 'docs/module-usage-guide/README.md'
destination_repo: 'sourcefuse/arc-docs'
destination_folder: 'docs/arc-iac-docs/modules/terraform-aws-arc-db/docs/module-usage-guide'
user_email: '[email protected]'
user_name: ${{ github.actor }}
commit_message: ${{ github.event.head_commit.message }}
34 changes: 17 additions & 17 deletions .terraform.lock.hcl

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

27 changes: 21 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,28 +19,43 @@ module "this" {

| Name | Version |
|------|---------|
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | ~> 1.3, < 2.0.0 |
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | ~> 4.0 |
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | > 1.4, < 2.0.0 |
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | ~> 5.0 |

## Providers

No providers.
| Name | Version |
|------|---------|
| <a name="provider_aws"></a> [aws](#provider\_aws) | 5.80.0 |

## Modules

No modules.

## Resources

No resources.
| Name | Type |
|------|------|
| [aws_security_group.this](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/security_group) | resource |
| [aws_vpc_security_group_egress_rule.this](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/vpc_security_group_egress_rule) | resource |
| [aws_vpc_security_group_ingress_rule.this](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/resources/vpc_security_group_ingress_rule) | resource |

## Inputs

No inputs.
| Name | Description | Type | Default | Required |
|------|-------------|------|---------|:--------:|
| <a name="input_description"></a> [description](#input\_description) | (optional) Description of Security Group | `string` | `null` | no |
| <a name="input_egress_rules"></a> [egress\_rules](#input\_egress\_rules) | (optional) List of egress rules for the security group. | <pre>list(object({<br> description = optional(string, null)<br> cidr_block = optional(string, null)<br> destination_security_group_id = optional(string, null)<br> from_port = number<br> ip_protocol = string<br> to_port = string<br> prefix_list_id = optional(string, null)<br> }))</pre> | `[]` | no |
| <a name="input_ingress_rules"></a> [ingress\_rules](#input\_ingress\_rules) | (optional) List of ingress rules for the security group. | <pre>list(object({<br> description = optional(string, null)<br> cidr_block = optional(string, null)<br> source_security_group_id = optional(string, null)<br> from_port = number<br> ip_protocol = string<br> to_port = string<br> self = optional(bool, false)<br> }))</pre> | `[]` | no |
| <a name="input_name"></a> [name](#input\_name) | Security Group name | `string` | n/a | yes |
| <a name="input_tags"></a> [tags](#input\_tags) | A map of tags to assign to the DB Cluster. | `map(string)` | `{}` | no |
| <a name="input_vpc_id"></a> [vpc\_id](#input\_vpc\_id) | VPC Id for creating security group | `string` | n/a | yes |

## Outputs

No outputs.
| Name | Description |
|------|-------------|
| <a name="output_id"></a> [id](#output\_id) | Security Groupo ID |
<!-- END OF PRE-COMMIT-TERRAFORM DOCS HOOK -->

## Versioning
Expand Down
34 changes: 17 additions & 17 deletions example/.terraform.lock.hcl

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

20 changes: 15 additions & 5 deletions example/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,25 +5,35 @@

| Name | Version |
|------|---------|
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | ~> 1.3, < 2.0.0 |
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | ~> 4.0 |
| <a name="requirement_terraform"></a> [terraform](#requirement\_terraform) | > 1.4, < 2.0.0 |
| <a name="requirement_aws"></a> [aws](#requirement\_aws) | ~> 5.0 |

## Providers

No providers.
| Name | Version |
|------|---------|
| <a name="provider_aws"></a> [aws](#provider\_aws) | 5.80.0 |

## Modules

No modules.
| Name | Source | Version |
|------|--------|---------|
| <a name="module_arc_security_group"></a> [arc\_security\_group](#module\_arc\_security\_group) | ../ | n/a |
| <a name="module_tags"></a> [tags](#module\_tags) | sourcefuse/arc-tags/aws | 1.2.3 |

## Resources

No resources.
| Name | Type |
|------|------|
| [aws_security_group.default](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/security_group) | data source |
| [aws_vpc.this](https://registry.terraform.io/providers/hashicorp/aws/latest/docs/data-sources/vpc) | data source |

## Inputs

| Name | Description | Type | Default | Required |
|------|-------------|------|---------|:--------:|
| <a name="input_environment"></a> [environment](#input\_environment) | ID element. Usually used for region e.g. 'uw2', 'us-west-2', OR role 'prod', 'staging', 'dev', 'UAT' | `string` | `"poc"` | no |
| <a name="input_namespace"></a> [namespace](#input\_namespace) | ID element. Usually an abbreviation of your organization name, e.g. 'eg' or 'cp', to help ensure generated IDs are globally unique | `string` | `"arc"` | no |
| <a name="input_region"></a> [region](#input\_region) | AWS region | `string` | `"us-east-1"` | no |

## Outputs
Expand Down
Loading

0 comments on commit ab3198a

Please sign in to comment.