Skip to content

Commit

Permalink
arm
Browse files Browse the repository at this point in the history
  • Loading branch information
cherchyk committed Feb 12, 2024
1 parent 968448a commit b66848c
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 9 deletions.
7 changes: 7 additions & 0 deletions .github/workflows/image-build-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,12 @@ jobs:
- name: Checkout code
uses: actions/checkout@v4

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

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Login to Docker Hub
uses: docker/login-action@v3
with:
Expand All @@ -24,5 +30,6 @@ jobs:
uses: docker/build-push-action@v5
with:
push: true
platforms: linux/amd64,linux/arm64
file: ./Service.Dockerfile
tags: ${{ secrets.DOCKERHUB_USERNAME }}/service:latest
18 changes: 9 additions & 9 deletions Service.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -28,15 +28,15 @@ RUN dotnet publish "./Service.csproj" -c $BUILD_CONFIGURATION -o /app/publish /p

FROM mcr.microsoft.com/dotnet/aspnet:$RUN_IMAGE_TAG AS base
# Non-root user that will run the service
# ARG USER=km
# RUN \
# # Create user
# #Debian: useradd --create-home --user-group $USER --shell /bin/bash && \
# adduser -D -h /app -s /bin/sh $USER && \
# # Allow user to access the build
# chown -R $USER.$USER /app
# # Define current user
# USER $USER
ARG USER=km
RUN \
# Create user
#Debian: useradd --create-home --user-group $USER --shell /bin/bash && \
adduser -D -h /app -s /bin/sh $USER && \
# Allow user to access the build
chown -R $USER.$USER /app
# Define current user
USER $USER

WORKDIR /app
EXPOSE 8080
Expand Down

0 comments on commit b66848c

Please sign in to comment.