File tree Expand file tree Collapse file tree 4 files changed +7
-3
lines changed Expand file tree Collapse file tree 4 files changed +7
-3
lines changed Original file line number Diff line number Diff line change 4242 GOOGLE_OAUTH_CLIENT_ID=${{ secrets.GOOGLE_OAUTH_CLIENT_ID }}
4343 SENTRY_INGEST_CLIENT=${{ secrets.SENTRY_INGEST_CLIENT }}
4444 SENTRY_TRACE_RATE_CLIENT=${{ secrets.SENTRY_TRACE_RATE_CLIENT }}
45+ GIT_COMMIT=${{ github.sha }}
4546 tags : |
4647 ghcr.io/csesoc/notangles-client:${{ github.sha }}
4748 ghcr.io/csesoc/notangles-client:latest
Original file line number Diff line number Diff line change 4242 GOOGLE_OAUTH_CLIENT_ID=${{ secrets.GOOGLE_OAUTH_CLIENT_ID }}
4343 SENTRY_INGEST_CLIENT=${{ secrets.SENTRY_INGEST_CLIENT }}
4444 SENTRY_TRACE_RATE_CLIENT=${{ secrets.SENTRY_TRACE_RATE_CLIENT }}
45+ GIT_COMMIT=${{ github.sha }}
4546 tags : |
4647 ghcr.io/csesoc/notangles-client:${{ github.sha }}
4748 ghcr.io/csesoc/notangles-client:latest
@@ -122,4 +123,4 @@ jobs:
122123 git commit -m "feat(notangles): update images"
123124 git push -u origin update/notangles/${{ github.sha }}
124125 gh pr create -B migration --title "feat(notangles): update images" --body "Updates the images for the notangles deployment to commit csesoc/notangles@${{ github.sha }}." > URL
125- gh pr merge $(cat URL) --squash -d
126+ gh pr merge $(cat URL) --squash -d
Original file line number Diff line number Diff line change @@ -27,7 +27,9 @@ ENV VITE_APP_SENTRY_TRACE_RATE_CLIENT=$SENTRY_TRACE_RATE_CLIENT
2727ENV VITE_APP_ENVIRONMENT=production
2828ENV NODE_ENV=production
2929
30- RUN pnpm run build
30+ ARG GIT_COMMIT
31+ RUN if [ -n "$GIT_COMMIT" ]; then export VITE_COMMIT=$GIT_COMMIT; fi && \
32+ pnpm run build
3133
3234FROM caddy:2.8.4-alpine
3335COPY ./Caddyfile /etc/caddy/Caddyfile
Original file line number Diff line number Diff line change @@ -248,7 +248,7 @@ const Sidebar: React.FC = () => {
248248 { ! collapsed ? (
249249 < SidebarFooterText >
250250 < Divider />
251- < span > © DevSoc { new Date ( ) . getFullYear ( ) } , v1.0.0 </ span >
251+ < span > { import . meta . env . VITE_COMMIT ?. substring ( 0 , 7 ) ?? 'unknown commit' } </ span >
252252 </ SidebarFooterText >
253253 ) : (
254254 < CollapseButton collapsed = { collapsed } onClick = { ( ) => handleCollapse ( false ) } toolTipTitle = "Expand" />
You can’t perform that action at this time.
0 commit comments