Skip to content

Commit

Permalink
Action steps updates and docker file changes for .NET 8 multi archite…
Browse files Browse the repository at this point in the history
…cture build
  • Loading branch information
Farooq Kotwal committed Aug 16, 2024
1 parent db80721 commit 453672a
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
12 changes: 6 additions & 6 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,11 @@ jobs:

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v4

- name: Setup Docker Metadata
id: meta
uses: docker/metadata-action@v3
uses: docker/metadata-action@v5
with:
# list of Docker images to use as base name for tags
images: |
Expand All @@ -52,21 +52,21 @@ jobs:
type=semver,pattern={{major}}
- name: Setup Docker QEMU
uses: docker/setup-qemu-action@v1
uses: docker/setup-qemu-action@v3

- name: Setup Docker Buildx
uses: docker/setup-buildx-action@v1
uses: docker/setup-buildx-action@v3

- name: Login to DockerHub
if: ${{ github.repository_owner == 'ConsumerDataRight' && github.event_name != 'pull_request' }}
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Build and push Docker image
id: docker_build
uses: docker/build-push-action@v2
uses: docker/build-push-action@v6
with:
context: ./Source
file: ./Source/Dockerfile.standalone
Expand Down
2 changes: 1 addition & 1 deletion Source/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ ENV ASPNETCORE_ENVIRONMENT=Release
###############################################################################
# Build CdrAuthServer API layer
###############################################################################
FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build
FROM --platform=$BUILDPLATFORM mcr.microsoft.com/dotnet/sdk:8.0 AS build
WORKDIR /src
COPY ./ .

Expand Down
2 changes: 1 addition & 1 deletion Source/Dockerfile.standalone
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ RUN npm run build
###############################################################################
# Build CdrAuthServer API layer
###############################################################################
FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build
FROM --platform=$BUILDPLATFORM mcr.microsoft.com/dotnet/sdk:8.0 AS build
WORKDIR /src
COPY ./ .

Expand Down

0 comments on commit 453672a

Please sign in to comment.