feat: show version number on welcome screen when logged in

This commit is contained in:
Benjamin Nussbaum 2025-05-06 13:19:02 +02:00
parent 56210405ff
commit 4de1403105
4 changed files with 32 additions and 0 deletions

View file

@ -19,6 +19,10 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v4
- name: Extract version from tag
id: get_version
run: echo "VERSION=${GITHUB_REF#refs/tags/}" >> $GITHUB_ENV
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
@ -52,3 +56,5 @@ jobs:
cache-from: type=gha
cache-to: type=gha,mode=max
target: production
build-args: |
APP_VERSION=${{ env.VERSION }}

View file

@ -3,6 +3,13 @@
########################
FROM bnussbau/serversideup-php:8.3-fpm-nginx-alpine-imagick-chromium AS base
LABEL org.opencontainers.image.source=https://github.com/usetrmnl/byos_laravel
LABEL org.opencontainers.image.description="TRMNL BYOS Laravel"
LABEL org.opencontainers.image.licenses=MIT
ARG APP_VERSION
ENV APP_VERSION=${APP_VERSION}
ENV AUTORUN_ENABLED="true"
# Switch to the root user so we can do root things

View file

@ -130,4 +130,17 @@ return [
'force_https' => env('FORCE_HTTPS', false),
'puppeteer_docker' => env('PUPPETEER_DOCKER', false),
/*
|--------------------------------------------------------------------------
| Application Version
|--------------------------------------------------------------------------
|
| This value is the version of your application, which will be used when
| displaying the version number in the UI. This is set during the Docker
| build process from the release tag.
|
*/
'version' => env('APP_VERSION', null),
];

View file

@ -31,4 +31,10 @@
</nav>
@endif
</header>
@auth
@if(config('app.version'))
<flux:text class="text-xs">Version: <a href="https://github.com/usetrmnl/byos_laravel/releases/"
target="_blank">{{ config('app.version') }}</a></flux:text>
@endif
@endauth
</x-layouts.auth.card>