Skip to content

Commit

Permalink
Update to dotnet8
Browse files Browse the repository at this point in the history
  • Loading branch information
rafaelschlatter committed Mar 25, 2024
1 parent bb2dd36 commit 2b92f63
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 15 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/dotnet.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ on:

jobs:
dotnet:
uses: RaaLabs/reusable-workflows/.github/workflows/dotnet-build.yml@main
uses: RaaLabs/reusable-workflows/.github/workflows/dotnet-build.yml@dotnet8
with:
IMAGE_NAME: 'connectors-opcua'
secrets:
Expand Down
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -279,4 +279,6 @@ __pycache__/
Artifacts/

*.feature.cs
*.DS_Store
*.DS_Store
*.der
*.pfx
7 changes: 4 additions & 3 deletions Source/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
FROM mcr.microsoft.com/dotnet/sdk:7.0-alpine3.17 AS build-env
FROM mcr.microsoft.com/dotnet/sdk:8.0-alpine3.19 AS build-env
ARG TARGETARCH
WORKDIR /app

VOLUME [ "/app/config" ]
Expand All @@ -14,15 +15,15 @@ RUN --mount=type=secret,id=NUGET_GITHUB_PACKAGES_USERNAME \
--password $(cat /run/secrets/NUGET_GITHUB_PACKAGES_TOKEN) \
--store-password-in-clear-text --name "githubpackagesnuget" "https://nuget.pkg.github.com/RaaLabs/index.json"

RUN dotnet restore --runtime alpine-x64
RUN dotnet restore --runtime="linux-musl-${TARGETARCH/amd64/x64}"

RUN dotnet publish -c Release -o out --no-restore \
--runtime alpine-x64 \
--self-contained true \
/p:PublishTrimmed=true \
/p:PublishSingleFile=true

FROM mcr.microsoft.com/dotnet/runtime-deps:7.0-alpine3.17 AS final
FROM mcr.microsoft.com/dotnet/runtime-deps:8.0-alpine3.19 AS final

WORKDIR /app
COPY --from=build-env /app/Source/out ./
Expand Down
20 changes: 10 additions & 10 deletions Source/OPCUA.csproj
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net7.0</TargetFramework>
<TargetFramework>net8.0</TargetFramework>
<TrimMode>partial</TrimMode>
<AssemblyName>RaaLabs.Edge.Connectors.OPCUA</AssemblyName>
</PropertyGroup>
Expand All @@ -12,15 +12,15 @@
<TrimmerRootAssembly Include="RaaLabs.Edge.Connectors.OPCUA" preserve="all" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="RaaLabs.Edge" Version="1.16.1" />
<PackageReference Include="RaaLabs.Edge.Modules.EventHandling" Version="1.16.1" />
<PackageReference Include="RaaLabs.Edge.Modules.Configuration" Version="1.16.1" />
<PackageReference Include="RaaLabs.Edge.Modules.EdgeHub" Version="1.16.1" />
<PackageReference Include="RaaLabs.Edge.Modules.Diagnostics" Version="1.16.1" />
<PackageReference Include="OPCFoundation.NetStandard.Opc.Ua" Version="1.5.373.121" />
<PackageReference Include="OPCFoundation.NetStandard.Opc.Ua.Client" Version="1.5.373.121" />
<PackageReference Include="OPCFoundation.NetStandard.Opc.Ua.Configuration" Version="1.5.373.121" />
<PackageReference Include="OPCFoundation.NetStandard.Opc.Ua.Core" Version="1.5.373.121" />
<PackageReference Include="RaaLabs.Edge" Version="1.16.3" />
<PackageReference Include="RaaLabs.Edge.Modules.EventHandling" Version="1.16.3" />
<PackageReference Include="RaaLabs.Edge.Modules.Configuration" Version="1.16.3" />
<PackageReference Include="RaaLabs.Edge.Modules.EdgeHub" Version="1.16.3" />
<PackageReference Include="RaaLabs.Edge.Modules.Diagnostics" Version="1.16.3" />
<PackageReference Include="OPCFoundation.NetStandard.Opc.Ua" Version="1.5.374.27" />
<PackageReference Include="OPCFoundation.NetStandard.Opc.Ua.Client" Version="1.5.374.27" />
<PackageReference Include="OPCFoundation.NetStandard.Opc.Ua.Configuration" Version="1.5.374.27" />
<PackageReference Include="OPCFoundation.NetStandard.Opc.Ua.Core" Version="1.5.374.27" />
<PackageReference Include="Polly" Version="7.2.4" />
</ItemGroup>
</Project>

0 comments on commit 2b92f63

Please sign in to comment.