Skip to content

Commit

Permalink
Merge branch 'main' into dependabot/nuget/OpenTelemetry.Instrumentati…
Browse files Browse the repository at this point in the history
…on.AspNetCore-1.10.0
  • Loading branch information
ardalis authored Dec 13, 2024
2 parents feef342 + f12f574 commit 707c838
Show file tree
Hide file tree
Showing 2 changed files with 48 additions and 1 deletion.
47 changes: 47 additions & 0 deletions .github/workflows/build-ramdisk.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Build and Test with Ramdisk

on:
push:
branches:
- main
pull_request:

jobs:
build-and-test:
runs-on: ubuntu-latest

steps:
# Step 1: Checkout the repository
- name: Checkout Code
uses: actions/checkout@v3

# Step 2: Set up .NET environment
- name: Setup .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: 7.0

# Step 3: Create a ramdisk
- name: Create Ramdisk
run: |
mkdir -p /mnt/ramdisk
sudo mount -t tmpfs -o size=2G tmpfs /mnt/ramdisk
# Step 4: Copy source code to the ramdisk
- name: Copy Code to Ramdisk
run: |
cp -r $GITHUB_WORKSPACE /mnt/ramdisk/project
# Step 5: Build and test from the ramdisk
- name: Build and Test
run: |
cd /mnt/ramdisk/project
dotnet build --configuration Release
dotnet test --no-build --verbosity normal
# Step 6: Cleanup the ramdisk (optional, as the instance is ephemeral)
- name: Cleanup Ramdisk
if: always()
run: |
sudo umount /mnt/ramdisk
rm -rf /mnt/ramdisk
2 changes: 1 addition & 1 deletion Directory.Packages.props
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
<PackageVersion Include="OpenTelemetry.Exporter.OpenTelemetryProtocol" Version="1.10.0" />
<PackageVersion Include="OpenTelemetry.Extensions.Hosting" Version="1.10.0" />
<PackageVersion Include="OpenTelemetry.Instrumentation.AspNetCore" Version="1.10.0" />
<PackageVersion Include="OpenTelemetry.Instrumentation.Http" Version="1.9.0" />
<PackageVersion Include="OpenTelemetry.Instrumentation.Http" Version="1.10.0" />
<PackageVersion Include="OpenTelemetry.Instrumentation.Runtime" Version="1.9.0" />
<PackageVersion Include="Aspire.Hosting.Testing" Version="9.0.0" />
<!--#endif -->
Expand Down

0 comments on commit 707c838

Please sign in to comment.