Skip to content

Commit

Permalink
add logs group
Browse files Browse the repository at this point in the history
  • Loading branch information
anmolnagpal committed Oct 14, 2021
1 parent 0181dd3 commit d970727
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 14 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/readme.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: 'Checkout'
uses: actions/checkout@master
uses: actions/checkout@v2.3.4

- name: Set up Python 3.7.
uses: actions/setup-python@v2
with:
python-version: '3.x'

- name: 'create readme'
uses: 'clouddrove/github-actions@v7.0'
uses: 'clouddrove/github-actions@v8.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@v7.0'
uses: 'clouddrove/github-actions@v8.0'
continue-on-error: true
with:
actions_subcommand: 'push'
Expand All @@ -51,4 +51,4 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # required
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_TERRAFORM }} # required
if: always()
if: always()
14 changes: 6 additions & 8 deletions .github/workflows/terraform.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

name: 'Terraform GitHub Actions'
on:
pull_request:
Expand All @@ -14,7 +13,7 @@ jobs:
uses: actions/checkout@v2.3.4

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

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

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

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

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

- name: 'Terraform plan'
uses: 'clouddrove/github-actions@v7.0'
uses: 'clouddrove/github-actions@v8.0'
with:
actions_subcommand: 'plan'
tf_actions_working_dir: ./_example
Expand All @@ -84,7 +83,6 @@ jobs:
- 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
Expand All @@ -98,4 +96,4 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # required
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_WEBHOOK_TERRAFORM }} # required
if: always()
if: always()
4 changes: 2 additions & 2 deletions main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,8 @@ resource "aws_cloudtrail" "default" {
enable_log_file_validation = var.enable_log_file_validation
is_multi_region_trail = true
include_global_service_events = var.include_global_service_events
cloud_watch_logs_role_arn = aws_iam_role.cloudtrail_cloudwatch_role.arn
cloud_watch_logs_group_arn = "${aws_cloudwatch_log_group.cloudtrail.arn}:*"
cloud_watch_logs_role_arn = var.cloud_watch_logs_role_arn
cloud_watch_logs_group_arn = var.cloud_watch_logs_group_arn
kms_key_id = aws_kms_key.cloudtrail.arn
is_organization_trail = var.is_organization_trail
tags = module.labels.tags
Expand Down

0 comments on commit d970727

Please sign in to comment.