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

fix(ci): Optimize CI performance #1529

Merged
merged 2 commits into from
Apr 22, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
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
3 changes: 3 additions & 0 deletions .github/workflows/execution-plan-pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@ name: "Execution Plan on Pull Request"
pull_request:
branches:
- main
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
sven-urbanski-freiheit-com marked this conversation as resolved.
Show resolved Hide resolved
jobs:
execution-plan:
uses: ./.github/workflows/execution-plan-snippet-earthly.yml
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/execution-plan-snippet-earthly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,7 @@ jobs:
if: |
always() &&
(needs.stageA_build.result != 'failed') &&
(needs.stageA_build.result != 'cancelled') &&
(needs.execution_plan.outputs.stage_b != 'null')
strategy:
matrix:
Expand Down
2 changes: 1 addition & 1 deletion Earthfile
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ integration-test:
# With alpine:3.18, we get occasional issues with gpg that says there's a process running already, even though there shouldn't be.
# Ubuntu:22.04 seems to solve this issue.
FROM ubuntu:22.04
RUN apt update && apt install -y curl gpg gpg-agent gettext bash git golang netcat-openbsd
RUN apt update && apt install --auto-remove -y curl gpg gpg-agent gettext bash git golang netcat-openbsd docker.io
ARG GO_TEST_ARGS
# K3S environment variables
ENV KUBECONFIG=/kp/kubeconfig.yaml
Expand Down
2 changes: 1 addition & 1 deletion infrastructure/docker/builder/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ cleanup-main:

release:
echo "Releasing $(IMAGENAME)"
earthly --push +publish --DOCKER_REGISTRY_URI=$(DOCKER_REGISTRY_URI) --IMAGE_TAG=$(IMAGE_TAG) --VERSION=$(VERSION)
earthly --no-output --push +publish --DOCKER_REGISTRY_URI=$(DOCKER_REGISTRY_URI) --IMAGE_TAG=$(IMAGE_TAG) --VERSION=$(VERSION)

publish: release
echo $(IMAGE_TAG)
Expand Down
2 changes: 1 addition & 1 deletion infrastructure/docker/git-ssh/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ cleanup-main:

release:
echo "Releasing $(IMAGENAME)"
earthly --push +publish --DOCKER_REGISTRY_URI=$(DOCKER_REGISTRY_URI) --IMAGE_TAG=$(IMAGE_TAG)
earthly --no-output --push +publish --DOCKER_REGISTRY_URI=$(DOCKER_REGISTRY_URI) --IMAGE_TAG=$(IMAGE_TAG)

publish: release
echo $(IMAGE_TAG)
Expand Down
4 changes: 2 additions & 2 deletions services/cd-service/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -64,11 +64,11 @@ build: bin/main

build-pr:
echo "build on pull request"
$(EARTHLY) --push +build-pr --registry=$(IMAGE_REGISTRY) --tag=$(VERSION) --mirror=$(ARTIFACT_REGISTRY_MIRROR)
$(EARTHLY) --no-output --push +build-pr --registry=$(IMAGE_REGISTRY) --tag=$(VERSION) --mirror=$(ARTIFACT_REGISTRY_MIRROR)
sven-urbanski-freiheit-com marked this conversation as resolved.
Show resolved Hide resolved

build-main:
echo "build on main"
$(EARTHLY) --push +build-main --registry=$(IMAGE_REGISTRY) --tag=$(VERSION) --mirror=$(ARTIFACT_REGISTRY_MIRROR)
$(EARTHLY) --no-output --push +build-main --registry=$(IMAGE_REGISTRY) --tag=$(VERSION) --mirror=$(ARTIFACT_REGISTRY_MIRROR)

.PHONY: cleanup-pr
cleanup-pr:
Expand Down
4 changes: 2 additions & 2 deletions services/frontend-service/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -59,11 +59,11 @@ build: bin/main

build-pr:
echo "build on pull request"
$(EARTHLY) --push +build-pr --registry=$(IMAGE_REGISTRY) --tag=$(VERSION) --mirror=$(ARTIFACT_REGISTRY_MIRROR)
$(EARTHLY) --no-output --push +build-pr --registry=$(IMAGE_REGISTRY) --tag=$(VERSION) --mirror=$(ARTIFACT_REGISTRY_MIRROR)

build-main:
echo "build on main"
$(EARTHLY) --push +build-main --registry=$(IMAGE_REGISTRY) --tag=$(VERSION) --mirror=$(ARTIFACT_REGISTRY_MIRROR)
$(EARTHLY) --no-output --push +build-main --registry=$(IMAGE_REGISTRY) --tag=$(VERSION) --mirror=$(ARTIFACT_REGISTRY_MIRROR)

.PHONY: cleanup-pr
cleanup-pr:
Expand Down
4 changes: 2 additions & 2 deletions services/rollout-service/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -47,11 +47,11 @@ build: bin/main

build-pr:
echo "build on pull request"
$(EARTHLY) --push +build-pr --registry=$(IMAGE_REGISTRY) --tag=$(VERSION) --mirror=$(ARTIFACT_REGISTRY_MIRROR)
$(EARTHLY) --no-output --push +build-pr --registry=$(IMAGE_REGISTRY) --tag=$(VERSION) --mirror=$(ARTIFACT_REGISTRY_MIRROR)

build-main:
echo "build on main"
$(EARTHLY) --push +build-main --registry=$(IMAGE_REGISTRY) --tag=$(VERSION) --mirror=$(ARTIFACT_REGISTRY_MIRROR)
$(EARTHLY) --no-output --push +build-main --registry=$(IMAGE_REGISTRY) --tag=$(VERSION) --mirror=$(ARTIFACT_REGISTRY_MIRROR)

.PHONY: cleanup-pr
cleanup-pr:
Expand Down
Loading