Skip to content

Commit

Permalink
update gh actions
Browse files Browse the repository at this point in the history
  • Loading branch information
aspriddell committed Dec 30, 2024
1 parent a5577eb commit 3e17535
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 5 deletions.
11 changes: 7 additions & 4 deletions .github/workflows/publish-docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ on:
permissions:
packages: read

env:
DOTNET_TARGET_VER: 9.0

jobs:
docker-linux:
runs-on: ubuntu-latest
Expand All @@ -21,7 +24,7 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/setup-dotnet@v4
with:
dotnet-version: '8.0.x'
dotnet-version: ${{ github.env.DOTNET_TARGET_VER }}.x

- uses: docker/setup-qemu-action@v3
- uses: docker/setup-buildx-action@v3
Expand All @@ -39,7 +42,7 @@ jobs:
- name: Image Build and Push
uses: docker/build-push-action@v6
with:
context: ${{ matrix.project.name }}/bin/Release/net8.0/publish
context: ${{ matrix.project.name }}/bin/Release/net${{ github.env.DOTNET_TARGET_VER }}/publish
tags: dragonfruitdotnet/onionfruit-web:${{ matrix.project.tag-prefix }}linux
platforms: linux/arm64,linux/amd64
file: ${{ matrix.project.name }}/Dockerfile
Expand All @@ -61,7 +64,7 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/setup-dotnet@v4
with:
dotnet-version: '8.0.x'
dotnet-version: ${{ github.env.DOTNET_TARGET_VER }}.x

- uses: docker/login-action@v3
with:
Expand All @@ -75,7 +78,7 @@ jobs:
run: dotnet publish -c Release -p:UseAppHost=false -p:Version=${{ github.event.release.tag_name }} ${{ matrix.project.name }}

- name: Image Build
run: docker build -f ${{ matrix.project.name }}\Dockerfile -t ${{ env.DOCKER_TAG }} --build-arg "IMAGEVARIANT=nanoserver-ltsc2022" ${{ matrix.project.name }}\bin\Release\net8.0\publish
run: docker build -f ${{ matrix.project.name }}\Dockerfile -t ${{ env.DOCKER_TAG }} --build-arg "IMAGEVARIANT=nanoserver-ltsc2022" ${{ matrix.project.name }}\bin\Release\net${{ github.env.DOTNET_TARGET_VER }}\publish

- name: Image Push
run: docker push ${{ env.DOCKER_TAG }}
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/publish-server-iis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/setup-dotnet@v4
with:
dotnet-version: '8.0.x'
dotnet-version: '9.0.x'

- name: Setup GitHub NuGet
run: dotnet nuget update source dragonfruit --username USERNAME --password ${{ github.token }} --store-password-in-clear-text
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,4 +36,11 @@
<Protobuf Include="..\oniondb.proto" GrpcServices="Server"/>
</ItemGroup>

<ItemGroup>
<Content Remove="appsettings.json" />
<None Include="appsettings.json">
<CopyToPublishDirectory>Never</CopyToPublishDirectory>
</None>
</ItemGroup>

</Project>
7 changes: 7 additions & 0 deletions DragonFruit.OnionFruit.Web/DragonFruit.OnionFruit.Web.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,11 @@
<ProjectReference Include="..\DragonFruit.OnionFruit.Web.Worker\DragonFruit.OnionFruit.Web.Worker.csproj" />
</ItemGroup>

<ItemGroup>
<Content Remove="appsettings.json" />
<None Include="appsettings.json">
<CopyToPublishDirectory>Never</CopyToPublishDirectory>
</None>
</ItemGroup>

</Project>

0 comments on commit 3e17535

Please sign in to comment.