Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Simplify Makefile Architecture #832

Merged
merged 34 commits into from
Mar 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
d0968de
Split Iteration 1
TeodorSAP Feb 14, 2024
542f637
Makefile structure: iteration 2
TeodorSAP Feb 16, 2024
372b951
CHORE: small renaming
TeodorSAP Feb 16, 2024
e2f3d6c
CHORE: Move release to shell script
TeodorSAP Feb 16, 2024
82ed645
FEAT: Environment variables WIP
TeodorSAP Feb 26, 2024
7f883b7
Merge branch 'main' into chore/makefile
TeodorSAP Feb 26, 2024
a96ae83
FEAT: Makefile and shell scripts refactoring WIP
TeodorSAP Feb 26, 2024
d6ddfc3
CHORE: Initial Makefile Restructuring Iteration
TeodorSAP Feb 28, 2024
2b3fb5c
CHORE: Refactor tests running commands
TeodorSAP Feb 28, 2024
be480cd
Merge branch 'main' into chore/makefile
TeodorSAP Feb 28, 2024
8cc313f
CHORE: Clean-up Makefile comments
TeodorSAP Feb 28, 2024
d959efb
CHORE: ./hack
TeodorSAP Feb 28, 2024
09adfad
CHORE: Add ADR for Makefile architecture
TeodorSAP Feb 28, 2024
650bfc5
FIX: Syntax errors
TeodorSAP Feb 28, 2024
364e0cc
CHORE: ADR Title + small ginkgo fix
TeodorSAP Feb 28, 2024
efa90a2
Update docs/contributor/arch/009-makefile-architecture.md
TeodorSAP Feb 28, 2024
91418d5
Update docs/contributor/arch/009-makefile-architecture.md
TeodorSAP Feb 28, 2024
cf3e446
Update docs/contributor/arch/009-makefile-architecture.md
TeodorSAP Feb 28, 2024
209b206
Update docs/contributor/arch/009-makefile-architecture.md
TeodorSAP Feb 28, 2024
c03af3c
Update docs/contributor/arch/009-makefile-architecture.md
TeodorSAP Feb 28, 2024
0776a6d
Update docs/contributor/arch/009-makefile-architecture.md
TeodorSAP Feb 28, 2024
bf804d3
Update docs/contributor/arch/009-makefile-architecture.md
TeodorSAP Feb 28, 2024
e2edf42
Update docs/contributor/development.md
TeodorSAP Feb 28, 2024
2124e81
Update docs/contributor/development.md
TeodorSAP Feb 28, 2024
9bac435
Update docs/contributor/arch/009-makefile-architecture.md
TeodorSAP Feb 28, 2024
175e42e
Update docs/contributor/arch/009-makefile-architecture.md
TeodorSAP Feb 28, 2024
dc0dc12
Update docs/contributor/arch/009-makefile-architecture.md
TeodorSAP Feb 28, 2024
6796cd5
Update docs/contributor/arch/009-makefile-architecture.md
TeodorSAP Feb 28, 2024
c6adb9f
FIX: gardener-integration-test.sh
TeodorSAP Feb 29, 2024
0b3eb1f
REFACTOR: Apply review suggestions
TeodorSAP Mar 6, 2024
fab4e64
Merge branch 'main' into chore/makefile
TeodorSAP Mar 6, 2024
21a45f3
FIX: Merge conflict
TeodorSAP Mar 6, 2024
851ce1a
FIX: I'm blind
TeodorSAP Mar 6, 2024
669c8d1
CHORE: Remove unnecessary shell export macro
TeodorSAP Mar 6, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions .env
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
### Default Environment Variables
## General
ENV_ENVTEST_K8S_VERSION=1.27.1 # ENVTEST_K8S_VERSION refers to the version of Kubebuilder assets to be downloaded by envtest binary.
ENV_IMG=europe-docker.pkg.dev/kyma-project/prod/telemetry-manager:main # Image URL to use all building/pushing image targets
TeodorSAP marked this conversation as resolved.
Show resolved Hide resolved

## Gardener
ENV_GARDENER_K8S_VERSION=1.27
ENV_GARDENER_OS_VERSION="Not Defined"

## Dependencies
ENV_CONTROLLER_TOOLS_VERSION=v0.11.3
ENV_GINKGO_VERSION=v2.15.0
ENV_GO_TEST_COVERAGE_VERSION=v2.8.2
ENV_GOLANGCI-LINT_VERSION=latest
ENV_ISTIO_VERSION=1.3.2
ENV_K3D_VERSION=v5.4.7
ENV_KUSTOMIZE_VERSION=v5.0.1
ENV_TABLE_GEN_VERSION=v0.0.0-20230523174756-3dae9f177ffd
7 changes: 5 additions & 2 deletions .github/template/prepare-test/action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,13 @@ runs:
using: "composite"

steps:

- name: Setup Golang
uses: "./.github/template/setup-golang"

- name: Setup Ginkgo
shell: bash
run: make ginkgo

- name: Provision K3D
shell: bash
run: make provision-k3d
Expand Down Expand Up @@ -51,6 +54,6 @@ runs:

- name: Print cluster info
shell: bash
run: |
run: |
kubectl cluster-info
kubectl -n kyma-system get po
2 changes: 1 addition & 1 deletion .github/workflows/branch-integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ jobs:

# provision cluster and run tests
- name: Run test
run: make gardener-integration-test
run: hack/gardener-integration-test.sh
env:
GARDENER_SECRET_NAME: ${{ secrets.GARDENER_SECRET_NAME }}
GARDENER_PROJECT: ${{ secrets.GARDENER_PROJECT }}
Expand Down
178 changes: 90 additions & 88 deletions .github/workflows/pr-integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ on:
- "main"
- "release-*"
paths-ignore:
- 'docs/**'
- '**.md'
- "docs/**"
- "**.md"
workflow_dispatch:

jobs:
Expand All @@ -27,7 +27,7 @@ jobs:
github-token: ${{ secrets.GITHUB_TOKEN }}

- name: Run tests
run: make run-e2e-test-metrics
run: bin/ginkgo run --tags e2e --label-filter="metrics" test/e2e

- name: Finalize test
uses: "./.github/template/finalize-test"
Expand All @@ -38,104 +38,104 @@ jobs:
e2e-metrics:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Checkout repo
uses: actions/checkout@v4

- name: Prepare test
uses: "./.github/template/prepare-test"
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
- name: Prepare test
uses: "./.github/template/prepare-test"
with:
github-token: ${{ secrets.GITHUB_TOKEN }}

- name: Run tests
run: make run-e2e-test-metrics
- name: Run tests
run: bin/ginkgo run --tags e2e --label-filter="metrics" test/e2e

- name: Finalize test
uses: "./.github/template/finalize-test"
if: success() || failure()
with:
failure: failure()
- name: Finalize test
uses: "./.github/template/finalize-test"
if: success() || failure()
with:
failure: failure()

e2e-traces-release:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Checkout repo
uses: actions/checkout@v4

- name: Prepare Test
uses: "./.github/template/prepare-test"
with:
release: true
github-token: ${{ secrets.GITHUB_TOKEN }}
- name: Prepare Test
uses: "./.github/template/prepare-test"
with:
release: true
github-token: ${{ secrets.GITHUB_TOKEN }}

- name: Run tests
run: make run-e2e-test-traces
- name: Run tests
run: bin/ginkgo run --tags e2e --label-filter="traces" test/e2e

- name: Finalize Test
uses: "./.github/template/finalize-test"
if: success() || failure()
with:
failure: failure()
- name: Finalize Test
uses: "./.github/template/finalize-test"
if: success() || failure()
with:
failure: failure()

e2e-traces:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Checkout repo
uses: actions/checkout@v4

- name: Prepare Test
uses: "./.github/template/prepare-test"
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
- name: Prepare Test
uses: "./.github/template/prepare-test"
with:
github-token: ${{ secrets.GITHUB_TOKEN }}

- name: Run tests
run: make run-e2e-test-traces
- name: Run tests
run: bin/ginkgo run --tags e2e --label-filter="traces" test/e2e

- name: Finalize Test
uses: "./.github/template/finalize-test"
if: success() || failure()
with:
failure: failure()
- name: Finalize Test
uses: "./.github/template/finalize-test"
if: success() || failure()
with:
failure: failure()

e2e-logs-release:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Checkout repo
uses: actions/checkout@v4

- name: Prepare Test
uses: "./.github/template/prepare-test"
with:
release: true
github-token: ${{ secrets.GITHUB_TOKEN }}
- name: Prepare Test
uses: "./.github/template/prepare-test"
with:
release: true
github-token: ${{ secrets.GITHUB_TOKEN }}

- name: Run tests
run: make run-e2e-test-logs
- name: Run tests
run: bin/ginkgo run --tags e2e --label-filter="logs" test/e2e

- name: Finalize Test
uses: "./.github/template/finalize-test"
if: success() || failure()
with:
failure: failure()
- name: Finalize Test
uses: "./.github/template/finalize-test"
if: success() || failure()
with:
failure: failure()

e2e-logs:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Checkout repo
uses: actions/checkout@v4

- name: Prepare Test
uses: "./.github/template/prepare-test"
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
- name: Prepare Test
uses: "./.github/template/prepare-test"
with:
github-token: ${{ secrets.GITHUB_TOKEN }}

- name: Run tests
run: make run-e2e-test-logs
- name: Run tests
run: bin/ginkgo run --tags e2e --label-filter="logs" test/e2e

- name: Finalize Test
uses: "./.github/template/finalize-test"
if: success() || failure()
with:
failure: failure()
- name: Finalize Test
uses: "./.github/template/finalize-test"
if: success() || failure()
with:
failure: failure()

e2e-telemetry-release:
runs-on: ubuntu-latest
Expand All @@ -150,7 +150,7 @@ jobs:
github-token: ${{ secrets.GITHUB_TOKEN }}

- name: Run tests
run: make run-e2e-test-telemetry
run: bin/ginkgo run --tags e2e --label-filter="telemetry" test/e2e

- name: Finalize Test
uses: "./.github/template/finalize-test"
Expand All @@ -170,7 +170,7 @@ jobs:
github-token: ${{ secrets.GITHUB_TOKEN }}

- name: Run tests
run: make run-e2e-test-telemetry
run: bin/ginkgo run --tags e2e --label-filter="telemetry" test/e2e

- name: Finalize Test
uses: "./.github/template/finalize-test"
Expand All @@ -181,19 +181,21 @@ jobs:
e2e-integration-istio:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v4

- name: Prepare Test
uses: "./.github/template/prepare-test"
with:
github-token: ${{ secrets.GITHUB_TOKEN }}

- name: Run tests
run: make run-integration-test-istio

- name: Finalize Test
uses: "./.github/template/finalize-test"
if: success() || failure()
with:
failure: failure()
- name: Checkout repo
uses: actions/checkout@v4

- name: Prepare Test
uses: "./.github/template/prepare-test"
with:
github-token: ${{ secrets.GITHUB_TOKEN }}

- name: Run tests
run: |
hack/deploy-istio.sh
bin/ginkgo run --tags istio test/integration/istio

- name: Finalize Test
uses: "./.github/template/finalize-test"
if: success() || failure()
with:
failure: failure()
Loading
Loading