Skip to content

Commit 682af13

Browse files
authored
Initial commit
0 parents  commit 682af13

26 files changed

+899
-0
lines changed

.coderabbit.yaml

+90
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,90 @@
1+
# Docs: https://docs.coderabbit.ai/configure-coderabbit
2+
# Schema: https://coderabbit.ai/integrations/schema.v2.json
3+
# Support: https://discord.gg/GsXnASn26c
4+
5+
language: en
6+
7+
tone_instructions: |
8+
Provide feedback in a professional, friendly, constructive, and concise tone.
9+
Offer clear, specific suggestions and best practices to help enhance the code quality and promote learning.
10+
11+
early_access: true
12+
13+
knowledge_base:
14+
# The scope of learnings to use for the knowledge base.
15+
# `local` uses the repository's learnings,
16+
# `global` uses the organization's learnings,
17+
# `auto` uses repository's learnings for public repositories and organization's learnings for private repositories.
18+
# Default value: `auto`
19+
learnings:
20+
scope: global
21+
issues:
22+
scope: global
23+
pull_requests:
24+
scope: global
25+
26+
reviews:
27+
profile: chill
28+
auto_review:
29+
# Ignore reviewing if the title of the pull request contains any of these keywords (case-insensitive)
30+
ignore_title_keywords:
31+
- wip
32+
- draft
33+
- test
34+
# Set the commit status to 'pending' when the review is in progress and 'success' when it is complete.
35+
commit_status: false
36+
# Post review details on each review. Additionally, post a review status when a review is skipped in certain cases.
37+
review_status: false
38+
path_instructions:
39+
- path: "**/*.tf"
40+
instructions: |
41+
You're a Terraform expert who has thoroughly studied all the documentation from Hashicorp https://developer.hashicorp.com/terraform/docs and OpenTofu https://opentofu.org/docs/.
42+
You have a strong grasp of Terraform syntax and prioritize providing accurate and insightful code suggestions.
43+
As a fan of the Cloud Posse / SweetOps ecosystem, you incorporate many of their best practices https://docs.cloudposse.com/best-practices/terraform/ while balancing them with general Terraform guidelines.
44+
tools:
45+
# By default, all tools are enabled.
46+
# Masterpoint uses Trunk (https://trunk.io) so we do not need a lot of this feedback due to overlap.
47+
shellcheck:
48+
enabled: false
49+
ruff:
50+
enabled: false
51+
markdownlint:
52+
enabled: false
53+
github-checks:
54+
enabled: false
55+
languagetool:
56+
enabled: false
57+
biome:
58+
enabled: false
59+
hadolint:
60+
enabled: false
61+
swiftlint:
62+
enabled: false
63+
phpstan:
64+
enabled: false
65+
golangci-lint:
66+
enabled: false
67+
yamllint:
68+
enabled: false
69+
gitleaks:
70+
enabled: false
71+
checkov:
72+
enabled: false
73+
detekt:
74+
enabled: false
75+
eslint:
76+
enabled: false
77+
rubocop:
78+
enabled: false
79+
buf:
80+
enabled: false
81+
regal:
82+
enabled: false
83+
actionlint:
84+
enabled: false
85+
pmd:
86+
enabled: false
87+
cppcheck:
88+
enabled: false
89+
circleci:
90+
enabled: false

.editorconfig

+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# Unix-style newlines with a newline ending every file
2+
[*]
3+
charset = utf-8
4+
end_of_line = lf
5+
indent_size = 2
6+
indent_style = space
7+
insert_final_newline = true
8+
trim_trailing_whitespace = true
9+
10+
[*.md]
11+
max_line_length = 0
12+
13+
[COMMIT_EDITMSG]
14+
max_line_length = 0

.github/CODEOWNERS

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# Use this file to define individuals or teams that are responsible for code in a repository.
2+
# Read more: <https://help.github.com/articles/about-codeowners/>
3+
#
4+
# Order is important: the last matching pattern takes the most precedence
5+
6+
# These owners will be the default owners for everything
7+
* @masterpointio/masterpoint-internal

.github/PULL_REQUEST_TEMPLATE.md

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
## what
2+
3+
- Describe high-level what changed as a result of these commits (i.e. in plain-english, what do these changes mean?)
4+
- Use bullet points to be concise and to the point.
5+
6+
## why
7+
8+
- Provide the justifications for the changes (e.g. business case).
9+
- Describe why these changes were made (e.g. why do these commits fix the problem?)
10+
- Use bullet points to be concise and to the point.
11+
12+
## references
13+
14+
- Link to any supporting GitHub issues or helpful documentation to add some context (e.g. Stackoverflow).
15+
- Use `closes #123`, if this PR closes a GitHub issue `#123`

.github/workflows/lint.yaml

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
name: Lint
2+
3+
on: pull_request
4+
5+
permissions:
6+
actions: read
7+
checks: write
8+
contents: read
9+
pull-requests: read
10+
11+
jobs:
12+
lint:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- name: Check out Git repository
16+
uses: actions/checkout@v4
17+
- name: Trunk Check
18+
uses: trunk-io/trunk-action@v1

.github/workflows/release-please.yaml

+18
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
name: Release Please
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
permissions:
9+
contents: write
10+
pull-requests: write
11+
12+
jobs:
13+
release-please:
14+
runs-on: ubuntu-latest
15+
steps:
16+
- uses: googleapis/release-please-action@7987652d64b4581673a76e33ad5e98e3dd56832f #v4.1.3
17+
with:
18+
release-type: terraform-module

.github/workflows/trunk-upgrade.yaml

+34
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: Trunk Upgrade
2+
3+
on:
4+
schedule:
5+
# On the first day of every month @ 8am
6+
- cron: 0 8 1 * *
7+
workflow_dispatch: {}
8+
9+
permissions: read-all
10+
11+
jobs:
12+
trunk-upgrade:
13+
runs-on: ubuntu-latest
14+
permissions:
15+
# For trunk to create PRs
16+
contents: write
17+
pull-requests: write
18+
steps:
19+
- name: Checkout
20+
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 #v4.1.7
21+
22+
- name: Create Token for MasterpointBot App
23+
uses: tibdex/github-app-token@3beb63f4bd073e61482598c45c71c1019b59b73a #v2.1.0
24+
id: generate-token
25+
with:
26+
app_id: ${{ secrets.MP_BOT_APP_ID }}
27+
private_key: ${{ secrets.MP_BOT_APP_PRIVATE_KEY }}
28+
29+
- name: Upgrade
30+
uses: trunk-io/trunk-action/upgrade@86b68ffae610a05105e90b1f52ad8c549ef482c2 #v1.1.16
31+
with:
32+
github-token: ${{ steps.generate-token.outputs.token }}
33+
reviewers: "@masterpointio/masterpoint-internal"
34+
prefix: "chore: "

.gitignore

+42
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
# Ignore override files as they are usually used to override resources locally
2+
*override.tf
3+
*override.tf.json
4+
5+
# .tfstate files
6+
*.tfstate
7+
*.tfstate.*
8+
9+
# Local .terraform directories
10+
**/.terraform/*
11+
12+
# IDE/Editor settings
13+
**/.idea
14+
**/*.iml
15+
.vscode/
16+
*.orig
17+
*.draft
18+
*~
19+
20+
# Build Harness https://github.com/cloudposse/build-harness
21+
**/.build-harness
22+
**/build-harness
23+
24+
# Log files
25+
*.log
26+
27+
# Output from other tools that might be used alongside Terraform/OpenTofu
28+
*.tfvars.json
29+
backend.tf.json
30+
31+
# Taskit files
32+
.taskit/
33+
.task/
34+
.env.taskit-secrets
35+
36+
# Other
37+
**/*.backup
38+
***/*.tmp
39+
**/*.temp
40+
**/*.bak
41+
**/*.*swp
42+
**/.DS_Store

.pre-commit-config.yaml

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# Prerequisites:
2+
# brew install pre-commit terraform-docs
3+
repos:
4+
- repo: https://github.com/antonbabenko/pre-commit-terraform
5+
rev: v1.88.0
6+
hooks:
7+
- id: terraform_docs

.trunk/.gitignore

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
*out
2+
*logs
3+
*actions
4+
*notifications
5+
*tools
6+
plugins
7+
user_trunk.yaml
8+
user.yaml
9+
tmp

.trunk/configs/.checkov.yaml

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
skip-check:
2+
- CKV_TF_1 # Ensure module references are pinned to a commit SHA.

.trunk/configs/.markdownlint.yaml

+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# Autoformatter friendly markdownlint config (all formatting rules disabled)
2+
default: true
3+
blank_lines: false
4+
bullet: false
5+
html: false
6+
indentation: false
7+
line_length: false
8+
spaces: false
9+
url: false
10+
whitespace: false
11+
12+
# Ignore MD041/first-line-heading/first-line-h1
13+
# Error: First line in a file should be a top-level heading
14+
MD041: false

.trunk/configs/.yamllint.yaml

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
rules:
2+
quoted-strings:
3+
required: only-when-needed
4+
extra-allowed: ["{|}"]
5+
key-duplicates: {}
6+
octal-values:
7+
forbid-implicit-octal: true

.trunk/trunk.yaml

+42
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
# This file controls the behavior of Trunk: https://docs.trunk.io/cli
2+
# To learn more about the format of this file, see https://docs.trunk.io/reference/trunk-yaml
3+
version: 0.1
4+
cli:
5+
version: 1.22.7
6+
# Trunk provides extensibility via plugins. (https://docs.trunk.io/plugins)
7+
plugins:
8+
sources:
9+
- id: trunk
10+
ref: v1.6.4
11+
uri: https://github.com/trunk-io/plugins
12+
# Many linters and tools depend on runtimes - configure them here. (https://docs.trunk.io/runtimes)
13+
runtimes:
14+
enabled:
15+
16+
17+
# This is the section where you manage your linters. (https://docs.trunk.io/check/configuration)
18+
lint:
19+
disabled:
20+
# Incompatible with some Terraform features: https://github.com/tenable/terrascan/issues/1331
21+
- terrascan
22+
enabled:
23+
24+
25+
26+
- git-diff-check
27+
28+
29+
30+
31+
32+
33+
ignore:
34+
- linters: [tofu]
35+
paths:
36+
- "**/backend.tf.json"
37+
actions:
38+
enabled:
39+
- trunk-announce
40+
- trunk-check-pre-push
41+
- trunk-fmt-pre-commit
42+
- trunk-upgrade-available

CHANGELOG.md

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# Changelog
2+
3+
## [0.2.0](https://github.com/masterpointio/terraform-module-template/compare/v0.1.1...v0.2.0) (2024-11-14)
4+
5+
6+
### Features
7+
8+
* adds GH + CRabbit configs ([d86d463](https://github.com/masterpointio/terraform-module-template/commit/d86d463385d501db5465b02de13d60c925b5815d))
9+
10+
## [0.1.1](https://github.com/masterpointio/terraform-module-template/compare/0.1.0...v0.1.1) (2024-08-15)
11+
12+
13+
### Bug Fixes
14+
15+
* remove markdown trailing whitespace ([d609646](https://github.com/masterpointio/terraform-module-template/commit/d6096463b916eb536603d4ca3b2f3315e3fec9f2))
16+
* removes redundant editorconfig settings ([bbe0050](https://github.com/masterpointio/terraform-module-template/commit/bbe0050450cece8074f3d9ff5c3bd72ff01d8a1b))

0 commit comments

Comments
 (0)