Skip to content
This repository was archived by the owner on Apr 9, 2025. It is now read-only.

Commit 487c4a3

Browse files
chore: initial
0 parents  commit 487c4a3

22 files changed

+1415
-0
lines changed

.github/commitlint.config.js

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
const Configuration = {
2+
3+
extends: ['@commitlint/config-conventional'],
4+
5+
/*
6+
* Any rules defined here will override rules from @commitlint/config-conventional
7+
*/
8+
rules: {
9+
'body-max-line-length': [2, 'always', 200],
10+
},
11+
};
12+
13+
module.exports = Configuration;

.github/dependabot.yml

+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
version: 2
2+
updates:
3+
- package-ecosystem: terraform
4+
directory: "/"
5+
schedule:
6+
interval: "daily"
7+
open-pull-requests-limit: 10
8+
9+
- package-ecosystem: terraform
10+
directory: "/examples"
11+
schedule:
12+
interval: "daily"
13+
open-pull-requests-limit: 10
14+
15+
- package-ecosystem: "github-actions"
16+
directory: "/"
17+
schedule:
18+
interval: "daily"
19+
open-pull-requests-limit: 10

.github/workflows/build.yml

+28
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: Build
2+
3+
on: [ push, workflow_dispatch ]
4+
5+
jobs:
6+
examples:
7+
runs-on: ubuntu-latest
8+
strategy:
9+
fail-fast: false
10+
matrix:
11+
os: [ ubuntu-latest ]
12+
tf-version: [ 1.1.9, 1.2.9, 1.3.2 ]
13+
steps:
14+
- name: Install terraform v${{ matrix.tf-version }}
15+
run: |
16+
curl -LO https://releases.hashicorp.com/terraform/${{ matrix.tf-version }}/terraform_${{ matrix.tf-version }}_linux_amd64.zip
17+
unzip terraform_${{ matrix.tf-version }}_linux_amd64.zip
18+
sudo mv terraform /usr/local/bin
19+
rm *
20+
- name: Checkout code
21+
uses: actions/checkout@v2
22+
- name: Validate examples terraform v${{ matrix.tf-version }}
23+
run: make examples
24+
build:
25+
needs: [examples]
26+
runs-on: ubuntu-latest
27+
steps:
28+
- run: echo "OK"

.github/workflows/commitlint.yaml

+14
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
name: Lint Commit Messages
2+
3+
on: [pull_request]
4+
5+
jobs:
6+
commitlint:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- uses: actions/checkout@v3
10+
with:
11+
fetch-depth: 0
12+
- uses: wagoid/commitlint-github-action@v5
13+
with:
14+
configFile: "./.github/commitlint.config.js"

.github/workflows/terrascan.yaml

+30
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Terrascan
2+
on: [ pull_request ]
3+
# https://github.com/marketplace/actions/terrascan-iac-scanner
4+
jobs:
5+
terrascan:
6+
runs-on: ubuntu-latest
7+
name: terrascan
8+
steps:
9+
- name: Checkout repository
10+
uses: actions/checkout@v3
11+
- name: Run Terrascan
12+
id: terrascan
13+
uses: tenable/terrascan-action@main
14+
with:
15+
iac_type: 'terraform'
16+
iac_version: 'v14'
17+
policy_type: 'aws'
18+
only_warn: true
19+
sarif_upload: true
20+
#non_recursive:
21+
#iac_dir:
22+
#policy_path:
23+
#skip_rules:
24+
#config_path:
25+
#webhook_url:
26+
#webhook_token:
27+
- name: Upload SARIF file
28+
uses: github/codeql-action/upload-sarif@v2
29+
with:
30+
sarif_file: terrascan.sarif

.gitignore

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
**/.terraform/*
2+
*.tfvars
3+
terraform.tfstate.backup
4+
5+
.idea
6+
zz

.terraform.lock.hcl

+24
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

CODEOWNERS

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
* @argoyle @peter-svensson

LICENSE

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2021 opzkit
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
2+
3+
4+
for f in terraform-aws*; do
5+
cd $f && git remote add template [email protected]:opzkit/tf-template.git && git fetch --all && cd ..
6+
done
7+
8+
gbc template
9+
git cherry-pick --no-commit --allow-empty 1c8badd7f7a4ffa2b80d26d84c5932ac52f184d0...807c49a8ae12ee7be4a0401877d4ac7f86145a84
10+
11+
gcm "chore: rebase from template"
12+
git cherry-pick --continue
13+
...repeat
14+
15+
16+
tf import module.terraform-aws-dns-validated-certificate.github_repository.repo terraform-aws-dns-validated-certificate
17+
18+
tf import module.terraform-aws-aurora-postgresql.github_repository.repo terraform-aws-aurora-postgresql
19+
20+
tf import module.terraform-aws-aurora-mysql.github_repository.repo terraform-aws-aurora-mysql
21+

main.tf

+201
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,201 @@
1+
terraform {
2+
required_providers {
3+
github = {
4+
source = "integrations/github"
5+
version = "~> 4.0"
6+
}
7+
}
8+
}
9+
10+
module "template" {
11+
source = "./template-repo"
12+
13+
description = "Template repository for Terraform modules"
14+
name = "tf-template"
15+
}
16+
17+
module "example" {
18+
depends_on = [module.template]
19+
source = "./tf-repo"
20+
21+
description = "some text"
22+
name = "example"
23+
template_owner = var.github_owner
24+
template_repository = module.template.template_repo
25+
}
26+
#
27+
module "terraform-aws-aurora-mysql" {
28+
source = "./tf-repo"
29+
30+
description = ""
31+
name = "terraform-aws-aurora-mysql"
32+
}
33+
34+
module "terraform-aws-aurora-postgresql" {
35+
source = "./tf-repo"
36+
37+
description = ""
38+
name = "terraform-aws-aurora-postgresql"
39+
}
40+
41+
module "terraform-aws-dns-validated-certificate" {
42+
source = "./tf-repo"
43+
44+
description = ""
45+
name = "terraform-aws-dns-validated-certificate"
46+
}
47+
48+
#
49+
#module "terraform-aws-k8s-network" {
50+
# source = "./tf-repo"
51+
#
52+
# description = ""
53+
# name = "terraform-aws-k8s-network"
54+
#}
55+
#
56+
#module "terraform-cloudamqp-rabbitmq" {
57+
# source = "./tf-repo"
58+
#
59+
# description = ""
60+
# name = "terraform-cloudamqp-rabbitmq"
61+
#}
62+
#
63+
#module "terraform-aws-k8s" {
64+
# source = "./tf-repo"
65+
#
66+
# description = ""
67+
# name = "terraform-aws-k8s"
68+
#}
69+
#
70+
#module "terraform-aws-k8s-addons-cluster-autoscaler" {
71+
# source = "./tf-repo"
72+
#
73+
# description = ""
74+
# name = "terraform-aws-k8s-addons-cluster-autoscaler"
75+
#}
76+
#
77+
#module "nodeamqp" {
78+
# source = "./tf-repo"
79+
#
80+
# description = ""
81+
# name = "nodeamqp"
82+
#}
83+
#
84+
#module "terraform-aws-k8s-addons-external-secrets-operator" {
85+
# source = "./tf-repo"
86+
#
87+
# description = ""
88+
# name = "terraform-aws-k8s-addons-external-secrets-operator"
89+
#}
90+
#
91+
#module "terraform-aws-k8s-addons-grafana-agent-operator" {
92+
# source = "./tf-repo"
93+
#
94+
# description = ""
95+
# name = "terraform-aws-k8s-addons-grafana-agent-operator"
96+
#}
97+
#
98+
#module "govulncheck-action" {
99+
# source = "./tf-repo"
100+
#
101+
# description = ""
102+
# name = "govulncheck-action"
103+
#}
104+
105+
#module "auth0" {
106+
# source = "./tf-repo"
107+
#
108+
# description = ""
109+
# name = "auth0"
110+
#}
111+
#
112+
#module "opzkit_github_io" {
113+
# source = "./tf-repo"
114+
#
115+
# description = ""
116+
# name = "opzkit.github.io"
117+
#}
118+
#
119+
#module "terraform-aws-k8s-addons-external-secrets" {
120+
# source = "./tf-repo"
121+
#
122+
# description = ""
123+
# name = "terraform-aws-k8s-addons-external-secrets"
124+
#}
125+
#
126+
#module "terraform-aws-k8s-addons-fluentbit" {
127+
# source = "./tf-repo"
128+
#
129+
# description = ""
130+
# name = "terraform-aws-k8s-addons-fluentbit"
131+
#}
132+
#
133+
#module "terraform-aws-elasticache-redis" {
134+
# source = "./tf-repo"
135+
#
136+
# description = ""
137+
# name = "terraform-aws-elasticache-redis"
138+
#}
139+
#
140+
#module "terraform-aws-rds-instance-mysql" {
141+
# source = "./tf-repo"
142+
#
143+
# description = ""
144+
# name = "terraform-aws-rds-instance-mysql"
145+
#}
146+
#
147+
#module "terraform-aws-rds-instance-postgresql" {
148+
# source = "./tf-repo"
149+
#
150+
# description = ""
151+
# name = "terraform-aws-rds-instance-postgresql"
152+
#}
153+
#
154+
#module "terraform-aws-k8s-argocd-cluster-secret" {
155+
# source = "./tf-repo"
156+
#
157+
# description = ""
158+
# name = "terraform-aws-k8s-argocd-cluster-secret"
159+
#}
160+
#
161+
#module "terraform-aws-kops-state-store" {
162+
# source = "./tf-repo"
163+
#
164+
# description = ""
165+
# name = "terraform-aws-kops-state-store"
166+
#}
167+
#
168+
#module "terraform-aws-k8s-aws-lb-role-fix" {
169+
# source = "./tf-repo"
170+
#
171+
# description = ""
172+
# name = "terraform-aws-k8s-aws-lb-role-fix"
173+
#}
174+
#
175+
#module "terraform-aws-k8s-addons-external-dns" {
176+
# source = "./tf-repo"
177+
#
178+
# description = ""
179+
# name = "terraform-aws-k8s-addons-external-dns"
180+
#}
181+
#
182+
#module "terraform-aws-k8s-addons-github-runners" {
183+
# source = "./tf-repo"
184+
#
185+
# description = ""
186+
# name = "terraform-aws-k8s-addons-github-runners"
187+
#}
188+
#
189+
#module "terraform-aws-k8s-addons-argocd" {
190+
# source = "./tf-repo"
191+
#
192+
# description = ""
193+
# name = "terraform-aws-k8s-addons-argocd"
194+
#}
195+
#
196+
#module "argocd-bootstrap-template" {
197+
# source = "./tf-repo"
198+
#
199+
# description = ""
200+
# name = "argocd-bootstrap-template"
201+
#}

providers.tf

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
provider "github" {
2+
# token = var.token # or `GITHUB_TOKEN`
3+
owner = var.github_owner
4+
}

0 commit comments

Comments
 (0)