Skip to content

Commit 7c0f369

Browse files
committed
configure the workflow server-side instead of inrepo
1 parent 32d773e commit 7c0f369

File tree

4 files changed

+29
-20
lines changed

4 files changed

+29
-20
lines changed

.atlantis.yaml

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -10,23 +10,3 @@ projects:
1010
branch: /main/
1111
dir: infra/aws/terraform/artifacts.k8s.io
1212
workflow: aws
13-
# For AWS, atlantis needs to assume a specific role in each account except the management account
14-
# so we read it from the folder that atlantis will work on
15-
workflows:
16-
aws:
17-
plan:
18-
steps:
19-
- init:
20-
extra_args: ["--backend-config", "atlantis.config"]
21-
- plan:
22-
extra_args: ["-var-file", "atlantis.tfvars"]
23-
apply:
24-
steps:
25-
- apply:
26-
extra_args: ["-var-file", "atlantis.tfvars"]
27-
import:
28-
steps:
29-
- init:
30-
extra_args: ["--backend-config", "atlantis.config"]
31-
- import:
32-
extra_args: ["-var-file", "atlantis.tfvars"]

kubernetes/gke-utility/atlantis/atlantis.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,5 @@ hide-prev-plan-comments: true
1111
hide-unchanged-plan-comments: true
1212
checkout-strategy: merge
1313
emoji-reaction: eyes
14+
repo-config: /config/repos.yaml
1415
# default-tf-distribution: opentofu # uncomment when we start using opentofu

kubernetes/gke-utility/atlantis/kustomization.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ configMapGenerator:
1515
- name: atlantis-config
1616
files:
1717
- atlantis.yaml
18+
- repos.yaml
1819

1920
patchesStrategicMerge:
2021
- |-
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
# https://www.runatlantis.io/docs/server-side-repo-config.html
2+
repos:
3+
- id: github.com/kubernetes/k8s.io
4+
branch: /main/
5+
allow_custom_workflows: false # NO CUSTOM WORKLOADS CAN BE SPECIFIED IN THE REPOS
6+
allowed_workflows: [aws]
7+
8+
# For AWS, atlantis needs to assume a specific role in each account except the management account
9+
# so we read it from the folder that atlantis will work on
10+
workflows:
11+
aws:
12+
plan:
13+
steps:
14+
- init:
15+
extra_args: ["-backend-config=atlantis.config"]
16+
- plan:
17+
extra_args: ["-var-file=atlantis.tfvars"]
18+
apply:
19+
steps:
20+
- apply:
21+
extra_args: ["-var-file=atlantis.tfvars"]
22+
import:
23+
steps:
24+
- init:
25+
extra_args: ["-backend-config=atlantis.config"]
26+
- import:
27+
extra_args: ["-var-file=atlantis.tfvars"]

0 commit comments

Comments
 (0)