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

Release version v1.0.0 #67

Merged
merged 245 commits into from
Jul 6, 2024
Merged
Show file tree
Hide file tree
Changes from 243 commits
Commits
Show all changes
245 commits
Select commit Hold shift + click to select a range
b3db588
Merge pull request #8 from SmartCityFlensburg/main
choffmann May 26, 2024
99849e4
fix: change develop ingress hostname
choffmann May 27, 2024
0ceefbc
ci: add commit sha on develop package
choffmann May 27, 2024
2015fa8
Update dev image
choffmann May 27, 2024
c24747e
ci: change pipeline
choffmann May 27, 2024
0e6c186
Update dev image
choffmann May 27, 2024
889f530
ci: change user to GitHub Actions
choffmann May 27, 2024
09bbc9e
Update dev image
web-flow May 27, 2024
0a38ce9
ci: change helm template service
choffmann May 27, 2024
615395a
Update dev image
web-flow May 27, 2024
e7b7aac
ci: fix some issues in workflow
choffmann May 27, 2024
b301f8c
Update dev image to commit e7b7aac
web-flow May 27, 2024
d7fcb39
Update stage image to commit b301f8c
web-flow May 27, 2024
62bfce7
feat: update changelog.md
choffmann May 27, 2024
953948a
Update dev image to commit 62bfce7
web-flow May 27, 2024
69581a8
ci: change develop enviroment url to dev
choffmann May 29, 2024
c002aa4
Update dev image to commit 69581a8
web-flow May 29, 2024
bfedf31
chore: add fonts, rename css files
May 31, 2024
17951f1
chore: customize tailwind config
May 31, 2024
f3f2a5e
feat: add meta data to head, add editorsconfig, update folder structure
May 31, 2024
44a5177
chore: add empty lines to bottom of files
May 31, 2024
a493332
fix: change path and missing color
choffmann May 31, 2024
ef7a454
Merge pull request #15 from SmartCityFlensburg/feature/add-tailwind-c…
choffmann May 31, 2024
300f6be
Update dev image to commit ef7a454
web-flow May 31, 2024
bed5dd0
feat: add footer component
May 31, 2024
d99a856
Merge branch 'develop' into feature/add-footer
May 31, 2024
0042ea1
fix: update contact icon for contact button
May 31, 2024
e0562cb
chore: comment out contact button as long as we do not have a mail
May 31, 2024
07992e7
chore: delete public path out of background images
May 31, 2024
d21eeaf
fix: add target blank to footer button
May 31, 2024
af5d56c
Merge pull request #17 from SmartCityFlensburg/feature/add-footer
choffmann May 31, 2024
58a240d
Update dev image to commit af5d56c
web-flow May 31, 2024
67e127e
ci: add workflow to test build
choffmann Jun 3, 2024
3b50475
feat: add header (wip)
Jun 5, 2024
c552cd1
feat: add navigation transitions
Jun 5, 2024
13ae538
refactor: create main navigation component
Jun 5, 2024
7d2122c
ci: change ingress
choffmann Jun 5, 2024
49a593f
Update dev image to commit 7d2122c
web-flow Jun 5, 2024
6ec0667
Update stage image to commit 49a593f
web-flow Jun 5, 2024
7219c5e
Merge pull request #20 from SmartCityFlensburg/feature/build-on-pr
choffmann Jun 5, 2024
268c64b
Update dev image to commit 7219c5e
web-flow Jun 5, 2024
5f5ac5e
feat: add a click outside option for navigation
Jun 5, 2024
d565db0
fix: typescript errors in helper
Jun 5, 2024
e4a5004
Merge pull request #22 from SmartCityFlensburg/feature/add-header
choffmann Jun 5, 2024
0d35a8d
Update dev image to commit e4a5004
web-flow Jun 5, 2024
a29e777
feat: add accordions
Jun 6, 2024
7abafd9
feat: add animation to accordion items
Jun 6, 2024
fa17432
feat: update content
Jun 6, 2024
a5a4511
feat: add slider for involved parties
Jun 6, 2024
03bbeba
docs: update readme add section setting up project
choffmann May 29, 2024
6241b53
docs: add section deployment in readme
choffmann May 29, 2024
b8669ec
docs: add tech stack in readme
choffmann May 31, 2024
ec18db6
docs: fix some issues in README
choffmann Jun 6, 2024
3b70c2c
docs: add description about the repository
choffmann Jun 6, 2024
03284ba
docs: update introduction
choffmann Jun 6, 2024
3ae1fc5
fix: implement cross browser testing, close on resize
Jun 6, 2024
b0b5acd
feat: update arrow icon
Jun 6, 2024
6e415a4
feat: rename items to stakeholder
Jun 6, 2024
0dd1473
chore: add accessibility translations
Jun 6, 2024
1beb33c
fix: smaller image on tablet screens
Jun 6, 2024
2ed273a
fix: do not listen to resize, add gutter for scrolling
Jun 6, 2024
62d756a
Merge pull request #25 from SmartCityFlensburg/feature/update-readme
choffmann Jun 6, 2024
9cae61e
Update dev image to commit 62d756a
web-flow Jun 6, 2024
9e39bb9
Merge pull request #24 from SmartCityFlensburg/feature/add-faq-section
choffmann Jun 6, 2024
27d8096
Merge branch 'develop' into feature/add-involved-parties-section
Jun 6, 2024
8f1b1aa
Update dev image to commit 9e39bb9
web-flow Jun 6, 2024
4092561
Merge dev into current branch
Jun 6, 2024
f1bea44
fix: add max height to accordion in css
Jun 6, 2024
aacb91f
chore: add types for splide package
Jun 6, 2024
0e7947e
fix: add some accessibility improvements
Jun 6, 2024
3283141
fix: install splide package with yarn
Jun 6, 2024
fe3a005
chore: delete package-lock
Jun 6, 2024
a34094d
chore: add slider to production dependencies
Jun 7, 2024
68545e1
feat: add introduction section
Jun 7, 2024
ddb41d7
fix: update cursor
Jun 7, 2024
a09d6e3
feat: add favicons
Jun 7, 2024
c768fef
Merge pull request #26 from SmartCityFlensburg/feature/add-involved-p…
choffmann Jun 7, 2024
819c91c
Update dev image to commit c768fef
web-flow Jun 7, 2024
b0ad2d9
feat: add favicons
Jun 7, 2024
2fae5ca
Merge branch 'feature/add-favicons' of github.com:SmartCityFlensburg/…
Jun 7, 2024
f895069
fix: remove public from path
Jun 7, 2024
fc60408
Merge branch 'develop' into feature/add-introduction-section
Jun 7, 2024
928d3c6
Merge pull request #31 from SmartCityFlensburg/feature/add-favicons
choffmann Jun 7, 2024
a1fc674
Update dev image to commit 928d3c6
web-flow Jun 7, 2024
513af1c
Merge pull request #30 from SmartCityFlensburg/feature/add-introducti…
choffmann Jun 8, 2024
1e28577
Update dev image to commit 513af1c
web-flow Jun 8, 2024
3e5921b
ci: add deploy on pr
choffmann Jun 9, 2024
b956312
Update dev image to commit 3e5921b
web-flow Jun 9, 2024
b29c81b
feat: add process section (wip)
Jun 10, 2024
00633d6
Merge branch 'develop' into feature/add-current-process-section
Jun 10, 2024
f02575d
ci: add deploy on pr
choffmann Jun 9, 2024
fb15464
Update dev image to commit f02575d
web-flow Jun 10, 2024
306822a
fix: make process responsive for larger screens
Jun 10, 2024
09f7ec0
fix: update card width
Jun 10, 2024
e62e57b
chore: add padding to splide types
Jun 10, 2024
75cffd0
Merge branch 'develop' into feature/add-current-process-section
Jun 10, 2024
f51e202
chore: delete not used file from merge
Jun 10, 2024
3c4c08f
fix: update correct aria-label
Jun 10, 2024
7d85f70
fix: update max-screen width
Jun 10, 2024
501db19
ci: add deploy on pr
choffmann Jun 9, 2024
4d78476
Merge branch 'develop' into feature/add-current-process-section
choffmann Jun 10, 2024
a894376
Update dev image to commit 501db19
web-flow Jun 10, 2024
6587f4f
Merge branch 'develop' into feature/add-current-process-section
choffmann Jun 10, 2024
b3f7098
Merge pull request #36 from SmartCityFlensburg/feature/add-current-pr…
choffmann Jun 11, 2024
90bd930
Update dev image to commit b3f7098
web-flow Jun 11, 2024
7906759
feat: add infrastructure for new pages
Jun 11, 2024
14cf31c
chore: refactor order structure
Jun 11, 2024
e9b1bbd
fix: arrow import and update url in MainNavigation
Jun 11, 2024
3bf6d15
refactor: process steps to reuse process cards
Jun 11, 2024
3f42998
feat: add hero
Jun 11, 2024
a2fd1cf
feat: add hero background
Jun 11, 2024
04c473b
chore: add empty line to file
Jun 11, 2024
d466463
fet: add dashboard preview section
Jun 11, 2024
93145f2
fix: spacing to hero
Jun 11, 2024
cb005d7
feat: add advantages section
Jun 11, 2024
3a40f36
Merge branch 'feature/add-dashboard-section' into feature/add-advanta…
Jun 11, 2024
d1462e0
feat: add correct icons for advantage cards
Jun 11, 2024
6b75728
feat: add logo animation
Jun 11, 2024
1d9791b
feat: add contact section
Jun 12, 2024
c3dd734
feat: add background for mobile
Jun 12, 2024
bbca5e9
fix: implement feedback
Jun 14, 2024
ca51257
ci: fix subpath in nginx
choffmann Jun 14, 2024
11bd2b5
Merge pull request #41 from SmartCityFlensburg/feature/add-project-page
choffmann Jun 14, 2024
85a9c00
Update dev image to commit 11bd2b5
web-flow Jun 14, 2024
c4e50ed
fix: add devider (wip)
Jun 14, 2024
83afe25
fix: add correct mail to contact section
Jun 14, 2024
8b64910
Merge branch 'develop' into feature/add-contact-section
Jun 14, 2024
e533997
Merge branch 'develop' into feature/add-dashboard-section
Jun 14, 2024
10a2a4c
Merge pull request #46 from SmartCityFlensburg/feature/add-contact-se…
choffmann Jun 14, 2024
624043e
Update dev image to commit 10a2a4c
web-flow Jun 14, 2024
2423992
Merge branch 'develop' into feature/add-dashboard-section
choffmann Jun 14, 2024
579668a
Merge pull request #43 from SmartCityFlensburg/feature/add-dashboard-…
choffmann Jun 14, 2024
5db8eee
Update dev image to commit 579668a
web-flow Jun 14, 2024
f3406c3
fix: update card height
Jun 14, 2024
3a7e463
fix: update process steps to test with different data
Jun 14, 2024
9df6e67
Merge pull request #47 from SmartCityFlensburg/fix/same-card-height-i…
choffmann Jun 14, 2024
758a5ab
Update dev image to commit 9df6e67
web-flow Jun 14, 2024
cc2e692
Merge branch 'develop' into feature/add-advantages-section
Jun 15, 2024
f9a7a49
chore: cleanup code
Jun 15, 2024
44b1f74
Merge branch 'develop' into feature/add-homepage-hero
Jun 15, 2024
4ab8a99
feat: add homepage devider to homepage
Jun 15, 2024
fa17d37
feat: add second big tree to hero
Jun 15, 2024
1811f37
feat: add third tree
Jun 15, 2024
44305b4
Merge pull request #45 from SmartCityFlensburg/feature/add-advantages…
choffmann Jun 15, 2024
1f8a98e
Update dev image to commit 44305b4
web-flow Jun 15, 2024
45242f2
feat: add background
Jun 15, 2024
5d1fbcf
feat: add background to hero
Jun 15, 2024
bf9aafa
feat: add cloud
Jun 15, 2024
153ecf4
chore: cleanup
Jun 15, 2024
3bd806c
chore: cleanup not needed files
Jun 15, 2024
f94a50a
Merge branch 'develop' of github.com:SmartCityFlensburg/project-websi…
Jun 15, 2024
b4a9b69
feat: add contact page
Jun 15, 2024
014ee28
fix: update spacing
Jun 16, 2024
680bff1
feat: add contact sections
Jun 16, 2024
3757150
feat: add not found page
Jun 16, 2024
c71ec7c
Merge branch 'feature/add-contact-page' into feature/add-not-found-page
Jun 16, 2024
56ebaa4
feat: add content and animation to not found page
Jun 16, 2024
604b226
fix: update position of trees on landscape mobile phones
Jun 18, 2024
4bf85c3
fix: add useMemo to memorise current step
Jun 18, 2024
82b1bf5
Merge pull request #50 from SmartCityFlensburg/feature/add-homepage-hero
doriengr Jun 18, 2024
2999e2d
Update dev image to commit 82b1bf5
web-flow Jun 18, 2024
b0f9b80
Merge branch 'develop' into feature/add-contact-page
Jun 18, 2024
2b9ae50
fix: cleanup homepage classes
Jun 18, 2024
e319c5e
Merge pull request #55 from SmartCityFlensburg/fix/hero-classes-cleanup
doriengr Jun 18, 2024
ae2669d
Update dev image to commit e319c5e
web-flow Jun 18, 2024
b0e579d
feat: add homepage overlay
Jun 18, 2024
0a5db73
feat: add hero homepage overlay with popups (wip)
Jun 18, 2024
bbe9c35
Merge pull request #53 from SmartCityFlensburg/feature/add-contact-page
doriengr Jun 18, 2024
4beec47
Update dev image to commit bbe9c35
web-flow Jun 18, 2024
c4f7f57
feat: add animations to icons
Jun 18, 2024
0a3f4e7
fix: add lines to overlay (wip)
Jun 18, 2024
d7e4360
refactor: make hompage icons more modular
Jun 18, 2024
827b689
feat: add lines to sensors
Jun 18, 2024
97f720e
fix: scroll to top on overlay
Jun 18, 2024
4027705
feat: add simple transitions
Jun 18, 2024
ae0dd8f
feat: add animations
Jun 18, 2024
0f61a5f
Merge branch 'develop' into feature/add-not-found-page
Jun 18, 2024
5fe181d
feat: use indent size of two in yaml files
choffmann Jun 19, 2024
266ef4b
feat: fix action only delete when chart and namespace exist
choffmann Jun 19, 2024
7aec460
Merge pull request #54 from SmartCityFlensburg/feature/add-not-found-…
doriengr Jun 20, 2024
22179ec
Update dev image to commit 7aec460
web-flow Jun 20, 2024
7cd8e4c
Merge pull request #58 from SmartCityFlensburg/feature/run-cleanup-ac…
choffmann Jun 20, 2024
2cecf70
Update dev image to commit 7cd8e4c
web-flow Jun 20, 2024
8d7198b
Merge branch 'develop' into feature/add-hero-homepage-overlays
Jun 22, 2024
3008590
fix: close overlay on resize
Jun 22, 2024
e357977
feat: add cookie on initial load of startpage
Jun 22, 2024
4ea807f
feat: add welcome card (wip)
Jun 22, 2024
505ffd0
fix: add transition delay of welcome card
Jun 22, 2024
b484bf6
fix: make welcome card logic work
Jun 23, 2024
6232ba3
fix: showing icons after one animation call
Jun 23, 2024
99fca3a
feat: add fade in of overlay icons
Jun 23, 2024
1baea5c
fix: do not set cookie on mobile screens
Jun 23, 2024
6671c0d
feat: add background to process section
Jun 23, 2024
b550ea3
feat: add background to stakeholder and contact section
Jun 23, 2024
51f3ebf
fix: add link to logo in footer
Jun 23, 2024
93c5868
Merge pull request #60 from SmartCityFlensburg/fix/add-link-to-footer
doriengr Jun 23, 2024
844a23f
Update dev image to commit 93c5868
web-flow Jun 23, 2024
cdea66b
fix: update page title
Jun 23, 2024
bc201bc
Merge pull request #62 from SmartCityFlensburg/fix/update-page-title
doriengr Jun 24, 2024
2b170c8
Update dev image to commit bc201bc
web-flow Jun 24, 2024
eca9754
Merge branch 'develop' into feature/add-background-to-sections
Jun 24, 2024
ab99a1c
Merge branch 'develop' into feature/add-background-to-sections
Jun 24, 2024
e37caa7
Merge pull request #59 from SmartCityFlensburg/feature/add-background…
doriengr Jun 24, 2024
2674c12
Update dev image to commit e37caa7
web-flow Jun 24, 2024
00021b2
Changed Text in Footer.tsx
Jun 27, 2024
44cd2cc
Changed Text in ContactPage.tsx
Jun 27, 2024
4e1e5c6
Changed Text in ProjectPage.tsx
Jun 27, 2024
66ba19d
Changed Text in NotFoundPage.tsx
Jun 27, 2024
b30fdd6
Changed Text in ContactHeroContent.tsx
Jun 27, 2024
49d70e2
Changed Text in HomepageHero.tsx
Jun 27, 2024
f1f5887
Changed Texts in StakeholderCard.tsx and Stakeholder.tsx
Jun 27, 2024
0d058bb
Changed Text in Introduction.tsx
Jun 27, 2024
dfeb805
Changed Text in Process.tsx
Jun 27, 2024
0e903cf
Changed Text in Advantages.tsx
Jun 27, 2024
e5c6252
Changed Text in Contact.tsx
Jun 27, 2024
b431c78
Changed Text in DashboardPreview.tsx
Jun 27, 2024
2a70901
Merge branch 'develop' into feature/add-hero-homepage-overlays
Jul 1, 2024
d6891f3
fix: hide welcome card on outside click
Jul 1, 2024
00f3af5
feat: add link to last popup
Jul 1, 2024
feb8af0
Merge pull request #56 from SmartCityFlensburg/feature/add-hero-homep…
doriengr Jul 2, 2024
04e03ed
Update dev image to commit feb8af0
web-flow Jul 2, 2024
300e9a1
Changed Text in Faq.tsx
Jul 4, 2024
0e58f96
Changed Text in processSteps.ts and Faq.tsx
xk0niR Jul 4, 2024
3cc6674
Merge branch 'develop' into wording/changedTextsOnWebsite
Jul 5, 2024
6000d76
fix: update positioning of large tree on larger screens
Jul 5, 2024
787533e
fix: unify styling of links in text
Jul 5, 2024
5ee0bb1
fix: small fixes in spacings
Jul 5, 2024
3945837
Merge pull request #63 from SmartCityFlensburg/wording/changedTextsOn…
doriengr Jul 5, 2024
922adee
Update dev image to commit 3945837
web-flow Jul 5, 2024
4e5cb54
feat: add og-image
Jul 5, 2024
93a55e4
Merge pull request #64 from SmartCityFlensburg/feature/add-open-graph…
doriengr Jul 5, 2024
24ef8d6
Update dev image to commit 93a55e4
web-flow Jul 5, 2024
25d3b8a
fix: use correct path for og image
Jul 5, 2024
b807327
Merge pull request #65 from SmartCityFlensburg/fix/use-correct-og-ima…
doriengr Jul 5, 2024
6d60d63
Update dev image to commit b807327
web-flow Jul 5, 2024
5ad50e7
Changed Text in WelcomeCard.tsx and HomepageOverlay.tsx
xk0niR Jul 6, 2024
2bffc5e
Merge pull request #66 from SmartCityFlensburg/wording/changedOverlay…
doriengr Jul 6, 2024
2c30d74
Update dev image to commit 2bffc5e
web-flow Jul 6, 2024
b7fa8bd
Prepare release v1.0.0
web-flow Jul 6, 2024
6f625de
docs: update changelog
choffmann Jul 6, 2024
104a965
ci: fix stage build workflow
choffmann Jul 6, 2024
0b4867f
Update stage image to commit 104a965
web-flow Jul 6, 2024
4086697
ci: dump version in prod helm chart
choffmann Jul 6, 2024
92fdc8d
ci: dump prod version on draft new release
choffmann Jul 6, 2024
79df8f6
Update stage image to commit 92fdc8d
web-flow Jul 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
2 changes: 2 additions & 0 deletions .docker/Dockerfile.dev
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ RUN yarn build:dev


FROM nginx:latest
RUN rm /etc/nginx/conf.d/default.conf
COPY .docker/nginx.conf /etc/nginx/conf.d/
COPY --from=builder-web /app/build/dist /usr/share/nginx/html

EXPOSE 80
Expand Down
2 changes: 2 additions & 0 deletions .docker/Dockerfile.prod
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ RUN yarn build


FROM nginx:latest
RUN rm /etc/nginx/conf.d/default.conf
COPY .docker/nginx.conf /etc/nginx/conf.d/
COPY --from=builder-web /app/build/dist /usr/share/nginx/html

EXPOSE 80
Expand Down
2 changes: 2 additions & 0 deletions .docker/Dockerfile.stage
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ RUN yarn build:stage


FROM nginx:latest
RUN rm /etc/nginx/conf.d/default.conf
COPY .docker/nginx.conf /etc/nginx/conf.d/
COPY --from=builder-web /app/build/dist /usr/share/nginx/html

EXPOSE 80
Expand Down
9 changes: 9 additions & 0 deletions .docker/nginx.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
server {
listen 80;
listen [::]:80;

location / {
root /usr/share/nginx/html;
try_files $uri $uri/ /index.html;
}
}
30 changes: 30 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# EditorConfig is awesome: https://EditorConfig.org

# Top-most EditorConfig file
root = true

[*]
charset = utf-8
end_of_line = lf
indent_size = 4
indent_style = space
insert_final_newline = true
trim_trailing_whitespace = true

[*.css]
indent_size = 4

[*.scss]
indent_size = 4

[*.js]
indent_size = 4

[*.json]
indent_size = 2

[*.yaml]
indent_size = 2

[*.yml]
indent_size = 2
36 changes: 34 additions & 2 deletions .github/workflows/build-and-push-develop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,17 @@ jobs:
build_and_deploy_dev:
runs-on: ubuntu-latest
permissions:
contents: read
contents: write
packages: write
actions: write
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Set commit sha
run: |
echo "COMMIT_SHA=$(git rev-parse --short $GITHUB_SHA)" >> $GITHUB_ENV

- name: Set up QEMU
uses: docker/setup-qemu-action@v3

Expand All @@ -41,4 +45,32 @@ jobs:
file: ./.docker/Dockerfile.dev
platforms: linux/amd64,linux/arm64
push: true
tags: ghcr.io/${{ env.REPO_LC }}-dev:latest
tags: ghcr.io/${{ env.REPO_LC }}-dev:latest, ghcr.io/${{ env.REPO_LC }}-dev:${{ env.COMMIT_SHA }}

- name: "Setup yq"
uses: dcarbone/[email protected]
with:
version: "v4.42.1"
force: true

- name: Initialize mandatory git config
run: |
git config --global user.name 'GitHub Actions'
git config --global user.email '[email protected]'

- name: Bump version in values/develop.yaml
run: yq -i '.deployment.image.tag=strenv(COMMIT_SHA)' ./k8s/values/develop.yaml

- name: Commit k8s values files
id: make-commit
run: |
git add ./k8s/values/develop.yaml
git commit --message "Update dev image to commit ${{ env.COMMIT_SHA }}"

echo "::set-output name=commit::$(git rev-parse HEAD)"

- name: Push changes
uses: CasperWA/push-protected@v2
with:
token: ${{ secrets.GITHUB_TOKEN }}
branch: develop
76 changes: 73 additions & 3 deletions .github/workflows/build-and-push-stage.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
name: Build and Push Docker Image Staging
"on":
workflow_dispatch:
push:
branches:
- release/*
Expand All @@ -9,7 +10,7 @@ jobs:
build_and_deploy_stage:
runs-on: ubuntu-latest
permissions:
contents: read
contents: write
packages: write
actions: write
steps:
Expand Down Expand Up @@ -37,6 +38,11 @@ jobs:

echo "RELEASE_VERSION=$VERSION" >> $GITHUB_ENV

- name: Extract version from input (for manual workflow dispatch)
if: github.event_name == 'workflow_dispatch'
run: |
echo "RELEASE_VERSION=${{ github.event.inputs.version }}" >> $GITHUB_ENV

- name: Set up QEMU
uses: docker/setup-qemu-action@v3

Expand All @@ -56,11 +62,75 @@ jobs:
env:
REPO: "${{ github.repository }}"

- name: Build and push
- name: Set commit sha
run: |
echo "COMMIT_SHA=$(git rev-parse --short $GITHUB_SHA)" >> $GITHUB_ENV

- name: Build and push Version
if: github.event_name == 'push'
uses: docker/build-push-action@v5
with:
context: .
file: ./.docker/Dockerfile.stage
platforms: linux/amd64,linux/arm64
push: true
tags: ghcr.io/${{ env.REPO_LC }}-stage:${{ env.RELEASE_VERSION }}-preview, ghcr.io/${{ env.REPO_LC }}-stage:latest, ghcr.io/${{ env.REPO_LC }}-stage:${{ env.COMMIT_SHA }}

- name: Build and push Version
if: github.event_name == 'workflow_dispatch'
uses: docker/build-push-action@v5
with:
context: .
file: ./.docker/Dockerfile.stage
platforms: linux/amd64,linux/arm64
push: true
tags: ghcr.io/${{ env.REPO_LC }}-stage:${{ env.RELEASE_VERSION }}-preview, ghcr.io/${{ env.REPO_LC }}-stage:lastest
tags: ghcr.io/${{ env.REPO_LC }}-stage:latest, ghcr.io/${{ env.REPO_LC }}-stage:${{ env.COMMIT_SHA }}

- name: "Setup yq"
uses: dcarbone/[email protected]
with:
version: "v4.42.1"
force: true

- name: Initialize mandatory git config
run: |
git config --global user.name 'GitHub Actions'
git config --global user.email '[email protected]'

- name: Bump version in values/stage.yaml
run: yq -i '.deployment.image.tag=strenv(COMMIT_SHA)' ./k8s/values/stage.yaml

- name: Commit k8s values files
id: make-commit
run: |
git add ./k8s/values/stage.yaml
git commit --message "Update stage image to commit ${{ env.COMMIT_SHA }}"

echo "::set-output name=commit::$(git rev-parse HEAD)"

- name: Push changes
uses: CasperWA/push-protected@v2
if: github.event_name == 'push'
with:
token: ${{ secrets.GITHUB_TOKEN }}
branch: release/${{ env.RELEASE_VERSION }}

- name: Push changes
uses: CasperWA/push-protected@v2
if: github.event_name == 'workflow_dispatch'
with:
token: ${{ secrets.GITHUB_TOKEN }}
branch: develop

- name: Delete tag
uses: dev-drprasad/[email protected]
with:
tag_name: stage-deployment
delete_release: false
github_token: ${{ secrets.GITHUB_TOKEN }}

- name: Create tag
run: git tag -fa 'stage-deployment' -m "Update tag to commit ${{ env.COMMIT_SHA }}"

- name: Push tag
run: git push origin stage-deployment
31 changes: 31 additions & 0 deletions .github/workflows/build-on-pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: "Build project on PR"

on:
pull_request:
branches:
- develop

jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: read
packages: read
actions: read
steps:
- name: Checkout code
uses: actions/checkout@v4

- name: Use Node.js
uses: actions/setup-node@v4
with:
node-version-file: .node-version

- name: Install Yarn
run: npm install -g yarn

- name: Install dependencies
run: yarn --frozen-lockfile

- name: Build project
run: yarn build
72 changes: 72 additions & 0 deletions .github/workflows/cleanup_pull_request.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
name: 'Cleanup Pull Request'
on:
pull_request:
types: [closed]

jobs:
check-resources:
name: "Check Resources"
runs-on: ubuntu-latest
outputs:
helm_exists: ${{ steps.check_helm.outputs.exists }}
namespace_exists: ${{ steps.check_namespace.outputs.exists }}

steps:
- name: Kubernetes login
uses: azure/k8s-set-context@v4
with:
method: kubeconfig
kubeconfig: ${{ secrets.KUBE_CONFIG }}

- name: Check Helm Chart
id: check_helm
run: |
RELEASE_NAME=project-website-pr-${{ github.event.number }}
if helm list --all --namespace $RELEASE_NAME | grep $RELEASE_NAME; then
echo "::set-output name=exists::true"
else
echo Helm Chart $RELEASE_NAME does not exist
echo "::set-output name=exists::false"
fi

- name: Check Namespace
id: check_namespace
run: |
NAMESPACE=project-website-pr-${{ github.event.number }}
if kubectl get namespace $NAMESPACE; then
echo "::set-output name=exists::true"
else
echo Namespace $NAMESPACE does not exist
echo "::set-output name=exists::false"
fi

cleanup-pr:
name: "Cleanup Pull Request"
runs-on: ubuntu-latest
needs: check-resources
if: needs.check-resources.outputs.helm_exists == 'true' || needs.check-resources.outputs.namespace_exists == 'true'
continue-on-error: true
permissions:
contents: read
packages: write
actions: write
pull-requests: write

steps:
- name: Kubernetes login
uses: azure/k8s-set-context@v4
with:
method: kubeconfig
kubeconfig: ${{ secrets.KUBE_CONFIG }}

- name: Delete Helm Chart
if: needs.check-resources.outputs.helm_exists == 'true'
run: |
RELEASE_NAME=project-website-pr-${{ github.event.number }}
helm delete $RELEASE_NAME --namespace $RELEASE_NAME

- name: Delete Namespace
if: needs.check-resources.outputs.namespace_exists == 'true'
run: |
NAMESPACE=project-website-pr-${{ github.event.number }}
kubectl delete namespace $NAMESPACE
Loading
Loading