Skip to content

Commit 656ea3f

Browse files
Merge pull request #1 from SamuelBagattin/feature/v1
A module that works fine
2 parents 5eda9ff + 75c50c7 commit 656ea3f

File tree

22 files changed

+1004
-110
lines changed

22 files changed

+1004
-110
lines changed
Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
name: "lint"
22
on:
33
push:
4-
pull_request:
54

65
jobs:
76
terraform:
@@ -11,8 +10,15 @@ jobs:
1110
- uses: actions/checkout@v2
1211
- name: Setup Terraform
1312
uses: hashicorp/setup-terraform@v1
13+
- name: Cache terraform folder
14+
uses: actions/cache@v2
15+
with:
16+
path: ./.terraform
17+
key: terraform
1418
- name: terraform fmt
1519
run: terraform fmt -recursive -check=true
20+
- name: "terraform init"
21+
run: terraform init
1622
- name: terraform validate
1723
run: terraform validate
1824
tflint:
@@ -28,7 +34,7 @@ jobs:
2834
- uses: terraform-linters/setup-tflint@v1
2935
name: Setup TFLint
3036
- name: Init TFLint
31-
run: tflint --init
37+
run: tflint --init --config tflint.hcl
3238
- name: Run TFLint
3339
run: tflint -f compact --config tflint.hcl
3440
tfsec:
@@ -42,5 +48,3 @@ jobs:
4248
github_token: ${{ secrets.github_token }}
4349
level: info
4450
fail_on_error: true
45-
46-

.github/workflows/publish.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: Publish
2+
3+
on:
4+
workflow_run:
5+
workflows: ["lint"]
6+
types:
7+
- completed
8+
9+
jobs:
10+
publish:
11+
runs-on: ubuntu-latest
12+
if: github.ref == 'refs/heads/main'
13+
steps:
14+
- uses: actions/checkout@v2
15+
16+
- name: gh cli auth
17+
run: echo "${{ secrets.GITHUB_TOKEN }}" | gh auth login --with-token
18+
19+
- uses: actions/setup-dotnet@v1
20+
21+
- name: Install GitVersion
22+
run: git fetch --unshallow && dotnet tool install --global GitVersion.Tool
23+
24+
- name: Get semver
25+
id: semver
26+
run: echo "SEMVER=$(dotnet gitversion | jq -r '.FullSemVer')" >> $GITHUB_ENV
27+
28+
- name: Create release
29+
run: gh release create v${{ env.SEMVER }} -t v${{ env.SEMVER }}

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -298,4 +298,4 @@ $RECYCLE.BIN/
298298
# Windows shortcuts
299299
*.lnk
300300

301-
# End of https://www.toptal.com/developers/gitignore/api/windows,linux,macos,vim,emacs,terraform,terragrunt,intellij+all,visualstudiocode
301+
# End of https://www.toptal.com/developers/gitignore/api/windows,linux,macos,vim,emacs,terraform,terragrunt,intellij+all,visualstudiocode

.pre-commit-config.yaml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
repos:
2+
- repo: https://github.com/antonbabenko/pre-commit-terraform
3+
rev: v1.62.3
4+
hooks:
5+
- id: terraform_fmt
6+
- id: terraform_validate
7+
- id: terraform_docs
8+
- id: terraform_tflint
9+
args:
10+
- '--args=--config=tflint.hcl'
11+
- id: terraform_tfsec

.terraform-docs.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,10 @@ output:
66
file: "./README.md"
77
mode: replace
88

9+
recursive:
10+
enabled: true
11+
path: modules
12+
913
sections:
1014
hide:
11-
- providers
15+
- providers

.terraform.lock.hcl

Lines changed: 13 additions & 13 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Brewfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,4 +4,4 @@ brew "pre-commit"
44
55
brew "tflint"
66
brew "tfsec"
7-
brew "terraform-docs"
7+
brew "terraform-docs"

Brewfile.lock.json

Lines changed: 27 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -2,40 +2,40 @@
22
"entries": {
33
"brew": {
44
"awscli": {
5-
"version": "2.4.16",
5+
"version": "2.4.17",
66
"bottle": {
77
"rebuild": 0,
88
"root_url": "https://ghcr.io/v2/homebrew/core",
99
"files": {
1010
"arm64_monterey": {
1111
"cellar": ":any",
12-
"url": "https://ghcr.io/v2/homebrew/core/awscli/blobs/sha256:a01facecbe1096b0aa6478c99b93ecd57e03d6f4de4ed7ac9748366af010a09f",
13-
"sha256": "a01facecbe1096b0aa6478c99b93ecd57e03d6f4de4ed7ac9748366af010a09f"
12+
"url": "https://ghcr.io/v2/homebrew/core/awscli/blobs/sha256:445d65f36c68f3a236287d6a56ed869f56fb08ed4a5d5e4a6685a8fe7c3e5b25",
13+
"sha256": "445d65f36c68f3a236287d6a56ed869f56fb08ed4a5d5e4a6685a8fe7c3e5b25"
1414
},
1515
"arm64_big_sur": {
1616
"cellar": ":any",
17-
"url": "https://ghcr.io/v2/homebrew/core/awscli/blobs/sha256:a37594d769e4a9d1bef8ab5b61a802a475c64f17b434e1cb1a74ddd27e316549",
18-
"sha256": "a37594d769e4a9d1bef8ab5b61a802a475c64f17b434e1cb1a74ddd27e316549"
17+
"url": "https://ghcr.io/v2/homebrew/core/awscli/blobs/sha256:a5c801f9c95fd099819935a977552cf0c3e90679b0cef3236014996dcd1d8581",
18+
"sha256": "a5c801f9c95fd099819935a977552cf0c3e90679b0cef3236014996dcd1d8581"
1919
},
2020
"monterey": {
2121
"cellar": ":any",
22-
"url": "https://ghcr.io/v2/homebrew/core/awscli/blobs/sha256:ccfdfcc56ba657fa501737465a112ec2c611be23fe0b1ea40f726674eef4d750",
23-
"sha256": "ccfdfcc56ba657fa501737465a112ec2c611be23fe0b1ea40f726674eef4d750"
22+
"url": "https://ghcr.io/v2/homebrew/core/awscli/blobs/sha256:37dbf924d5c420037e55e4a20a200a084fedba5954b3836cb9e72a4cff24dc83",
23+
"sha256": "37dbf924d5c420037e55e4a20a200a084fedba5954b3836cb9e72a4cff24dc83"
2424
},
2525
"big_sur": {
2626
"cellar": ":any",
27-
"url": "https://ghcr.io/v2/homebrew/core/awscli/blobs/sha256:053fd0eb37931e6105f1b177fbe2a7e5b342df74e92f0810f10c2a851c8877e9",
28-
"sha256": "053fd0eb37931e6105f1b177fbe2a7e5b342df74e92f0810f10c2a851c8877e9"
27+
"url": "https://ghcr.io/v2/homebrew/core/awscli/blobs/sha256:5fa5af6c8a99054b6b1245ee6e4cd93bbab8a5a516204426125af85e329914ee",
28+
"sha256": "5fa5af6c8a99054b6b1245ee6e4cd93bbab8a5a516204426125af85e329914ee"
2929
},
3030
"catalina": {
3131
"cellar": ":any",
32-
"url": "https://ghcr.io/v2/homebrew/core/awscli/blobs/sha256:01381e41a464059712b3ce5b0a6caa1f4a1a966cba38e63fc0c5876f46866a78",
33-
"sha256": "01381e41a464059712b3ce5b0a6caa1f4a1a966cba38e63fc0c5876f46866a78"
32+
"url": "https://ghcr.io/v2/homebrew/core/awscli/blobs/sha256:de88dae7d628d1ca327fb6e9f3c4878b45af90bb1ddee493c209570a88a91100",
33+
"sha256": "de88dae7d628d1ca327fb6e9f3c4878b45af90bb1ddee493c209570a88a91100"
3434
},
3535
"x86_64_linux": {
3636
"cellar": ":any_skip_relocation",
37-
"url": "https://ghcr.io/v2/homebrew/core/awscli/blobs/sha256:6629e2bad223cbed622effdf2982e6de58562fdcad69b75c36e3a7b58a37437a",
38-
"sha256": "6629e2bad223cbed622effdf2982e6de58562fdcad69b75c36e3a7b58a37437a"
37+
"url": "https://ghcr.io/v2/homebrew/core/awscli/blobs/sha256:542a9a2ae4cd1453b8c53e7b86e015b84749ff6ea1e09afa13c7139618801d93",
38+
"sha256": "542a9a2ae4cd1453b8c53e7b86e015b84749ff6ea1e09afa13c7139618801d93"
3939
}
4040
}
4141
}
@@ -172,40 +172,40 @@
172172
}
173173
},
174174
"tfsec": {
175-
"version": "1.0.11",
175+
"version": "1.1.3",
176176
"bottle": {
177177
"rebuild": 0,
178178
"root_url": "https://ghcr.io/v2/homebrew/core",
179179
"files": {
180180
"arm64_monterey": {
181181
"cellar": ":any_skip_relocation",
182-
"url": "https://ghcr.io/v2/homebrew/core/tfsec/blobs/sha256:5af669f1a188fa075efa45c30cf768e14a028066e2a82b8997141a4c61830418",
183-
"sha256": "5af669f1a188fa075efa45c30cf768e14a028066e2a82b8997141a4c61830418"
182+
"url": "https://ghcr.io/v2/homebrew/core/tfsec/blobs/sha256:21aeafb0f4354015c36058c314d49794a635086ef1b9c811b6f4e4bc1cb60441",
183+
"sha256": "21aeafb0f4354015c36058c314d49794a635086ef1b9c811b6f4e4bc1cb60441"
184184
},
185185
"arm64_big_sur": {
186186
"cellar": ":any_skip_relocation",
187-
"url": "https://ghcr.io/v2/homebrew/core/tfsec/blobs/sha256:9d6f66df6e491ce4191fa6204f00f9028a148bd0ded01852aa58181b2bc6e586",
188-
"sha256": "9d6f66df6e491ce4191fa6204f00f9028a148bd0ded01852aa58181b2bc6e586"
187+
"url": "https://ghcr.io/v2/homebrew/core/tfsec/blobs/sha256:4e65e6cf5c57c610bcf036e1a22957a082bc00f19665ceed71adb19064f9164f",
188+
"sha256": "4e65e6cf5c57c610bcf036e1a22957a082bc00f19665ceed71adb19064f9164f"
189189
},
190190
"monterey": {
191191
"cellar": ":any_skip_relocation",
192-
"url": "https://ghcr.io/v2/homebrew/core/tfsec/blobs/sha256:6a8d4e07f54a77139c8563a0d91481d32feb0ab36b71f3b628c5f669aa876eda",
193-
"sha256": "6a8d4e07f54a77139c8563a0d91481d32feb0ab36b71f3b628c5f669aa876eda"
192+
"url": "https://ghcr.io/v2/homebrew/core/tfsec/blobs/sha256:9768796bbbb53e11693944aa81acd9f489a61bc26dc8d07f4da7a5247d614941",
193+
"sha256": "9768796bbbb53e11693944aa81acd9f489a61bc26dc8d07f4da7a5247d614941"
194194
},
195195
"big_sur": {
196196
"cellar": ":any_skip_relocation",
197-
"url": "https://ghcr.io/v2/homebrew/core/tfsec/blobs/sha256:5ab0c68a27f6baa9cf2d7984e682659d9bf89fe95cd5a4ac443862be6f573191",
198-
"sha256": "5ab0c68a27f6baa9cf2d7984e682659d9bf89fe95cd5a4ac443862be6f573191"
197+
"url": "https://ghcr.io/v2/homebrew/core/tfsec/blobs/sha256:b352989fe3eae690728aa0c5278200ff05b6973afa4edcc09c6c1a33ac82eee7",
198+
"sha256": "b352989fe3eae690728aa0c5278200ff05b6973afa4edcc09c6c1a33ac82eee7"
199199
},
200200
"catalina": {
201201
"cellar": ":any_skip_relocation",
202-
"url": "https://ghcr.io/v2/homebrew/core/tfsec/blobs/sha256:936ff4daf9fc5cb1cf92ceca7912656553e1d2b7f1a3a1bc955aa436f1446eba",
203-
"sha256": "936ff4daf9fc5cb1cf92ceca7912656553e1d2b7f1a3a1bc955aa436f1446eba"
202+
"url": "https://ghcr.io/v2/homebrew/core/tfsec/blobs/sha256:c942554654880f8b3c065b1977f94ff4c6bdf389ae2abcaeac28cf3365fe2e4b",
203+
"sha256": "c942554654880f8b3c065b1977f94ff4c6bdf389ae2abcaeac28cf3365fe2e4b"
204204
},
205205
"x86_64_linux": {
206206
"cellar": ":any_skip_relocation",
207-
"url": "https://ghcr.io/v2/homebrew/core/tfsec/blobs/sha256:cb64c6f93d02b6ff001d5a600b38f22721a64e5a231cd814c6f67469eb3cfe8f",
208-
"sha256": "cb64c6f93d02b6ff001d5a600b38f22721a64e5a231cd814c6f67469eb3cfe8f"
207+
"url": "https://ghcr.io/v2/homebrew/core/tfsec/blobs/sha256:2cdd320054f6a313bb87f4a1d427cf439e9a98f87f30d219750d9da71e1584e6",
208+
"sha256": "2cdd320054f6a313bb87f4a1d427cf439e9a98f87f30d219750d9da71e1584e6"
209209
}
210210
}
211211
}
@@ -261,7 +261,7 @@
261261
"monterey": {
262262
"HOMEBREW_VERSION": "3.3.14",
263263
"HOMEBREW_PREFIX": "/opt/homebrew",
264-
"Homebrew/homebrew-core": "5ea596db0b8786e885641b490851961de784a22b",
264+
"Homebrew/homebrew-core": "697041701f8ddc5293da5c520d42631ecc9d8d4b",
265265
"CLT": "13.2.0.0.1.1638488800",
266266
"Xcode": "13.2.1",
267267
"macOS": "12.1"

GitVersion.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
mode: Mainline
2+
branches:
3+
master:
4+
increment: Minor
5+
regex: ^master$|^main$

0 commit comments

Comments
 (0)