Skip to content

Commit

Permalink
Develop (Merge): Bump Application Version to v0.2.2-alpha and Fix Doc…
Browse files Browse the repository at this point in the history
…kerfile and Workflow

Bump Application Version to v0.2.2-alpha and Fix Dockerfile and Workflow
  • Loading branch information
ktutak1337 authored Jul 27, 2024
2 parents 6591b0e + 2e8b3e4 commit d60d15c
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 13 deletions.
14 changes: 7 additions & 7 deletions .github/workflows/docker-build-and-publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:

- name: Extract version from tag
id: extract_version
run: echo "::set-output name=version::${GITHUB_REF#refs/tags/v}"
run: echo "version=${GITHUB_REF#refs/tags/v}" >> $GITHUB_ENV

- name: Build and push Docker images for web api
uses: docker/build-push-action@v6.5.0
Expand All @@ -37,9 +37,9 @@ jobs:
file: docker/webapi/Dockerfile
platforms: linux/amd64,linux/arm64
push: true
tags: |
stellarchat-api:${{ steps.extract_version.outputs.version }}
stellarchat-api:latest
tags: |
${{ vars.DOCKER_IMAGE_NAME }}/stellarchat-api:${{ env.version }}
${{ vars.DOCKER_IMAGE_NAME }}/stellarchat-api:latest
- name: Build and push Docker images for web app
uses: docker/build-push-action@v6.5.0
Expand All @@ -48,6 +48,6 @@ jobs:
file: docker/webapp/Dockerfile
platforms: linux/amd64,linux/arm64
push: true
tags: |
stellarchat-web:${{ steps.extract_version.outputs.version }}
stellarchat-web:latest
tags: |
${{ vars.DOCKER_IMAGE_NAME }}/stellarchat-web:${{ env.version }}
${{ vars.DOCKER_IMAGE_NAME }}/stellarchat-web:latest
7 changes: 5 additions & 2 deletions docker/webapi/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
FROM mcr.microsoft.com/dotnet/aspnet:8.0 AS base
ARG PLATFORM=$BUILDPLATFORM

FROM --platform=$PLATFORM mcr.microsoft.com/dotnet/aspnet:8.0 AS base
WORKDIR /app
EXPOSE 8080
EXPOSE 8443

RUN adduser --disabled-password --gecos "" stellar

FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build
ARG PLATFORM
FROM --platform=$PLATFORM mcr.microsoft.com/dotnet/sdk:8.0 AS build
ARG BUILD_CONFIGURATION=Release
WORKDIR /src
COPY ../../src/Server src/Server
Expand Down
7 changes: 5 additions & 2 deletions docker/webapp/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build
ARG PLATFORM=$BUILDPLATFORM

FROM --platform=$PLATFORM mcr.microsoft.com/dotnet/sdk:8.0 AS build

WORKDIR /src
COPY ../../src/Shared/StellarChat.Shared.Contracts/StellarChat.Shared.Contracts.csproj src/Shared/StellarChat.Shared.Contracts/
Expand All @@ -16,7 +18,8 @@ FROM build AS publish
ARG BUILD_CONFIGURATION=Release
RUN dotnet publish ./src/Client/StellarChat.Client.Web/StellarChat.Client.Web.csproj -c $BUILD_CONFIGURATION -o /app/publish

FROM nginx:1.27.0-alpine AS final
ARG PLATFORM
FROM --platform=$PLATFORM nginx:1.27.0-alpine AS final
WORKDIR /usr/share/nginx/html
COPY --from=publish /app/publish/wwwroot .
COPY /docker/webapp/nginx.conf /etc/nginx/nginx.conf
Expand Down
2 changes: 1 addition & 1 deletion src/Client/StellarChat.Client.Web/wwwroot/appsettings.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"app": {
"name": "Stellar Chat",
"version": "v0.2.1-alpha",
"version": "v0.2.2-alpha",
"logoLarge": "",
"logoSmall": "https://raw.githubusercontent.com/ktutak1337/Stellar-Chat/main/docs/assets/logo-small.jpg",
"releases": "https://github.com/ktutak1337/Stellar-Chat/releases"
Expand Down
2 changes: 1 addition & 1 deletion src/Server/StellarChat.Server.Api/appsettings.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"app": {
"name": "Stellar Chat",
"version": "v0.2.1-alpha"
"version": "v0.2.2-alpha"
},
"AllowedHosts": "*",
"openAI": {
Expand Down

0 comments on commit d60d15c

Please sign in to comment.