Migrated CI from gitlab to gitea
All checks were successful
Branch Build / build-test-deploy (push) Successful in 2m22s
All checks were successful
Branch Build / build-test-deploy (push) Successful in 2m22s
This commit is contained in:
62
.gitea/workflows/branch-build.yml
Normal file
62
.gitea/workflows/branch-build.yml
Normal file
@@ -0,0 +1,62 @@
|
|||||||
|
name: Branch Build
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- '**'
|
||||||
|
|
||||||
|
env:
|
||||||
|
TZ: 'Europe/Berlin'
|
||||||
|
LANG: 'de'
|
||||||
|
CONFIGURATION: 'Debug'
|
||||||
|
GITEA_SERVER_URL: ${{ gitea.server_url }}
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build-test-deploy:
|
||||||
|
runs-on: ubuntu
|
||||||
|
steps:
|
||||||
|
- name: Checkout repository code
|
||||||
|
uses: actions/checkout@v6
|
||||||
|
with:
|
||||||
|
fetch-depth: 0
|
||||||
|
|
||||||
|
- name: Setup dotnet
|
||||||
|
uses: actions/setup-dotnet@v5
|
||||||
|
with:
|
||||||
|
dotnet-version: 10.x
|
||||||
|
cache: false
|
||||||
|
|
||||||
|
- name: Restore dependencies
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
dotnet restore -v q
|
||||||
|
echo "CI_SERVER_HOST=${GITEA_SERVER_URL#https://}" >> "$GITEA_ENV"
|
||||||
|
|
||||||
|
- name: Setup tools
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
dotnet tool install dotnet-reportgenerator-globaltool --tool-path /dotnet-tools
|
||||||
|
|
||||||
|
- name: Build solution
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
shopt -s globstar
|
||||||
|
mkdir /artifacts
|
||||||
|
dotnet build -c ${CONFIGURATION} --no-restore --nologo
|
||||||
|
mv ./**/*.nupkg /artifacts/
|
||||||
|
mv ./**/*.snupkg /artifacts/
|
||||||
|
|
||||||
|
- name: Test solution
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
dotnet test -c ${CONFIGURATION} --no-build --nologo /p:CoverletOutputFormat=Cobertura
|
||||||
|
/dotnet-tools/reportgenerator "-reports:${{ gitea.workspace }}/**/coverage.cobertura.xml" "-targetdir:/reports" "-reportType:TextSummary"
|
||||||
|
cat /reports/Summary.txt
|
||||||
|
|
||||||
|
- name: Publish packages
|
||||||
|
env:
|
||||||
|
BAGET_APIKEY: ${{ secrets.BAGET_APIKEY }}
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
dotnet nuget push -k ${BAGET_APIKEY} -s https://nuget.am-wd.de/v3/index.json --skip-duplicate /artifacts/*.nupkg
|
||||||
69
.gitea/workflows/core-build.yml
Normal file
69
.gitea/workflows/core-build.yml
Normal file
@@ -0,0 +1,69 @@
|
|||||||
|
name: Core Build
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
tags:
|
||||||
|
- 'v*'
|
||||||
|
|
||||||
|
env:
|
||||||
|
TZ: 'Europe/Berlin'
|
||||||
|
LANG: 'de'
|
||||||
|
CONFIGURATION: 'Release'
|
||||||
|
GITEA_SERVER_URL: ${{ gitea.server_url }}
|
||||||
|
CI_COMMIT_TAG: ${{ gitea.ref_name }}
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build-test-deploy:
|
||||||
|
runs-on: ubuntu
|
||||||
|
steps:
|
||||||
|
- name: Checkout repository code
|
||||||
|
uses: actions/checkout@v6
|
||||||
|
with:
|
||||||
|
fetch-depth: 0
|
||||||
|
|
||||||
|
- name: Setup dotnet
|
||||||
|
uses: actions/setup-dotnet@v5
|
||||||
|
with:
|
||||||
|
dotnet-version: 10.x
|
||||||
|
cache: false
|
||||||
|
|
||||||
|
- name: Restore dependencies
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
dotnet restore -v q
|
||||||
|
echo "CI_SERVER_HOST=${GITEA_SERVER_URL#https://}" >> "$GITEA_ENV"
|
||||||
|
|
||||||
|
- name: Setup tools
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
dotnet tool install dotnet-reportgenerator-globaltool --tool-path /dotnet-tools
|
||||||
|
|
||||||
|
- name: Build solution
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
shopt -s globstar
|
||||||
|
mkdir /artifacts
|
||||||
|
dotnet build -c ${CONFIGURATION} --no-restore --nologo src/Cloudflare/Cloudflare.csproj
|
||||||
|
mv ./src/Cloudflare/**/*.nupkg /artifacts/
|
||||||
|
mv ./src/Cloudflare/**/*.snupkg /artifacts/
|
||||||
|
|
||||||
|
- name: Test solution
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
dotnet test -c ${CONFIGURATION} --no-build --nologo /p:CoverletOutputFormat=Cobertura test/Cloudflare.Tests/Cloudflare.Tests.csproj
|
||||||
|
/dotnet-tools/reportgenerator "-reports:${{ gitea.workspace }}/**/coverage.cobertura.xml" "-targetdir:/reports" "-reportType:TextSummary"
|
||||||
|
|
||||||
|
- name: Upload artifacts
|
||||||
|
uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: artifacts
|
||||||
|
path: |
|
||||||
|
/reports/Summary.txt
|
||||||
|
|
||||||
|
- name: Publish packages
|
||||||
|
env:
|
||||||
|
NUGET_APIKEY: ${{ secrets.NUGET_APIKEY }}
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
dotnet nuget push -k ${NUGET_APIKEY} -s https://api.nuget.org/v3/index.json --skip-duplicate /artifacts/*.nupkg
|
||||||
71
.gitea/workflows/docs-build.yml
Normal file
71
.gitea/workflows/docs-build.yml
Normal file
@@ -0,0 +1,71 @@
|
|||||||
|
name: Documentation Build
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
tags:
|
||||||
|
- '**'
|
||||||
|
|
||||||
|
env:
|
||||||
|
TZ: 'Europe/Berlin'
|
||||||
|
LANG: 'de'
|
||||||
|
CONFIGURATION: 'Release'
|
||||||
|
GITEA_SERVER_URL: ${{ gitea.server_url }}
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build-deploy:
|
||||||
|
runs-on: server-runner
|
||||||
|
steps:
|
||||||
|
- name: Checkout repository code
|
||||||
|
uses: actions/checkout@v6
|
||||||
|
with:
|
||||||
|
fetch-depth: 0
|
||||||
|
|
||||||
|
- name: Setup dotnet
|
||||||
|
uses: actions/setup-dotnet@v5
|
||||||
|
with:
|
||||||
|
dotnet-version: 10.x
|
||||||
|
cache: false
|
||||||
|
|
||||||
|
- name: Restore dependencies
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
dotnet restore -v q
|
||||||
|
echo "CI_SERVER_HOST=${GITEA_SERVER_URL#https://}" >> "$GITEA_ENV"
|
||||||
|
|
||||||
|
- name: Setup tools
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
dotnet tool install dotnet-reportgenerator-globaltool --tool-path /dotnet-tools
|
||||||
|
dotnet tool install docfx --tool-path /dotnet-tools
|
||||||
|
|
||||||
|
- name: Build solution
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
shopt -s globstar
|
||||||
|
mkdir /artifacts
|
||||||
|
dotnet build -c ${CONFIGURATION} --no-restore --nologo
|
||||||
|
|
||||||
|
- name: Test solution
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
dotnet test -c ${CONFIGURATION} --no-build --nologo /p:CoverletOutputFormat=Cobertura
|
||||||
|
/dotnet-tools/reportgenerator "-reports:${{ gitea.workspace }}/**/coverage.cobertura.xml" "-targetdir:/reports" "-reportType:TextSummary"
|
||||||
|
cat /reports/Summary.txt
|
||||||
|
|
||||||
|
- name: Publish documentation
|
||||||
|
env:
|
||||||
|
DOCFX_SOURCE_REPOSITORY_URL: 'https://github.com/AM-WD/cloudflare-api'
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
/dotnet-tools/docfx metadata docs/docfx.json
|
||||||
|
/dotnet-tools/docfx build docs/docfx.json
|
||||||
|
tar -C "${{ gitea.workspace }}/docs/_site" -czf "/artifacts/docs.tar.gz" .
|
||||||
|
curl -sSL --no-progress-meter --user "${{ secrets.DOCS_DEPLOY_USER }}:${{ secrets.DOCS_DEPLOY_PASS }}" -F docs=cloudflare -F dump=@/artifacts/docs.tar.gz "${{ vars.DOCS_DEPLOY_URL }}"
|
||||||
|
|
||||||
|
- name: Upload artifacts
|
||||||
|
uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: cloudflare-docs
|
||||||
|
path: |
|
||||||
|
${{ gitea.workspace }}/docs/_site
|
||||||
70
.gitea/workflows/extensions-build.yml
Normal file
70
.gitea/workflows/extensions-build.yml
Normal file
@@ -0,0 +1,70 @@
|
|||||||
|
name: Extensions Build
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
tags:
|
||||||
|
- 'dns/v*'
|
||||||
|
- 'zones/v*'
|
||||||
|
|
||||||
|
env:
|
||||||
|
TZ: 'Europe/Berlin'
|
||||||
|
LANG: 'de'
|
||||||
|
CONFIGURATION: 'Release'
|
||||||
|
GITEA_SERVER_URL: ${{ gitea.server_url }}
|
||||||
|
CI_COMMIT_TAG: ${{ gitea.ref_name }}
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build-test-deploy:
|
||||||
|
runs-on: ubuntu
|
||||||
|
steps:
|
||||||
|
- name: Checkout repository code
|
||||||
|
uses: actions/checkout@v6
|
||||||
|
with:
|
||||||
|
fetch-depth: 0
|
||||||
|
|
||||||
|
- name: Setup dotnet
|
||||||
|
uses: actions/setup-dotnet@v5
|
||||||
|
with:
|
||||||
|
dotnet-version: 10.x
|
||||||
|
cache: false
|
||||||
|
|
||||||
|
- name: Restore dependencies
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
dotnet restore -v q
|
||||||
|
echo "CI_SERVER_HOST=${GITEA_SERVER_URL#https://}" >> "$GITEA_ENV"
|
||||||
|
|
||||||
|
- name: Setup tools
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
dotnet tool install dotnet-reportgenerator-globaltool --tool-path /dotnet-tools
|
||||||
|
|
||||||
|
- name: Build solution
|
||||||
|
shell: bash
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
shopt -s globstar
|
||||||
|
mkdir /artifacts
|
||||||
|
dotnet build -c ${CONFIGURATION} --no-restore --nologo
|
||||||
|
mv ./src/Extensions/**/*.nupkg /artifacts/
|
||||||
|
mv ./src/Extensions/**/*.snupkg /artifacts/
|
||||||
|
|
||||||
|
- name: Test solution
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
dotnet test -c ${CONFIGURATION} --no-build --nologo /p:CoverletOutputFormat=Cobertura
|
||||||
|
/dotnet-tools/reportgenerator "-reports:${{ gitea.workspace }}/**/coverage.cobertura.xml" "-targetdir:/reports" "-reportType:TextSummary"
|
||||||
|
|
||||||
|
- name: Upload artifacts
|
||||||
|
uses: actions/upload-artifact@v3
|
||||||
|
with:
|
||||||
|
name: artifacts
|
||||||
|
path: |
|
||||||
|
/reports/Summary.txt
|
||||||
|
|
||||||
|
- name: Publish packages
|
||||||
|
env:
|
||||||
|
NUGET_APIKEY: ${{ secrets.NUGET_APIKEY }}
|
||||||
|
run: |
|
||||||
|
set -ex
|
||||||
|
dotnet nuget push -k ${NUGET_APIKEY} -s https://api.nuget.org/v3/index.json --skip-duplicate /artifacts/*.nupkg
|
||||||
@@ -17,6 +17,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|||||||
|
|
||||||
- Updated tests to .NET 10
|
- Updated tests to .NET 10
|
||||||
- Updated solution to VS 2026
|
- Updated solution to VS 2026
|
||||||
|
- Migrated main repository from Gitlab to Gitea (CI/CD)
|
||||||
|
|
||||||
|
|
||||||
## v0.1.1, dns/v0.2.0, zones/v0.1.1 - 2025-11-06
|
## v0.1.1, dns/v0.2.0, zones/v0.1.1 - 2025-11-06
|
||||||
|
|||||||
@@ -28,8 +28,6 @@ This package contains the feature set of the _Domain/Zone Management_ section of
|
|||||||
|
|
||||||
Published under [MIT License] (see [choose a license])
|
Published under [MIT License] (see [choose a license])
|
||||||
|
|
||||||
[](https://link.am-wd.de/donate)
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
[Cloudflare]: src/Cloudflare/README.md
|
[Cloudflare]: src/Cloudflare/README.md
|
||||||
|
|||||||
@@ -1,9 +1,14 @@
|
|||||||
<Solution>
|
<Solution>
|
||||||
<Folder Name="/Solution Items/" />
|
<Folder Name="/Solution Items/" />
|
||||||
<Folder Name="/Solution Items/build/">
|
<Folder Name="/Solution Items/build/">
|
||||||
<File Path=".gitlab-ci.yml" />
|
|
||||||
<File Path="Directory.Build.props" />
|
<File Path="Directory.Build.props" />
|
||||||
</Folder>
|
</Folder>
|
||||||
|
<Folder Name="/Solution Items/build/workflows/">
|
||||||
|
<File Path=".gitea/workflows/branch-build.yml" />
|
||||||
|
<File Path=".gitea/workflows/core-build.yml" />
|
||||||
|
<File Path=".gitea/workflows/docs-build.yml" />
|
||||||
|
<File Path=".gitea/workflows/extensions-build.yml" />
|
||||||
|
</Folder>
|
||||||
<Folder Name="/Solution Items/config/">
|
<Folder Name="/Solution Items/config/">
|
||||||
<File Path=".editorconfig" />
|
<File Path=".editorconfig" />
|
||||||
<File Path=".gitignore" />
|
<File Path=".gitignore" />
|
||||||
|
|||||||
@@ -16,8 +16,8 @@
|
|||||||
<AssemblyOriginatorKeyFile>../../cloudflare-api.snk</AssemblyOriginatorKeyFile>
|
<AssemblyOriginatorKeyFile>../../cloudflare-api.snk</AssemblyOriginatorKeyFile>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<!-- Only build package for tagged releases or Debug on CI (only dev NuGet feed) -->
|
<!-- Only build package for tagged releases -->
|
||||||
<PropertyGroup Condition="$([System.Text.RegularExpressions.Regex]::IsMatch('$(CI_COMMIT_TAG)', '^v[0-9.]+')) or ('$(Configuration)' == 'Debug' and '$(GITLAB_CI)' == 'true')">
|
<PropertyGroup Condition="$([System.Text.RegularExpressions.Regex]::IsMatch('$(CI_COMMIT_TAG)', '^v[0-9.]+'))">
|
||||||
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
|
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
|
|||||||
@@ -2,6 +2,7 @@
|
|||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<Nullable>enable</Nullable>
|
<Nullable>enable</Nullable>
|
||||||
<NrtRevisionFormat>{semvertag:main}{!:-dev}</NrtRevisionFormat>
|
<NrtRevisionFormat>{semvertag:main}{!:-dev}</NrtRevisionFormat>
|
||||||
|
<NrtContinuousIntegrationBuild>$(ContinuousIntegrationBuild)</NrtContinuousIntegrationBuild>
|
||||||
|
|
||||||
<AppendTargetFrameworkToOutputPath>true</AppendTargetFrameworkToOutputPath>
|
<AppendTargetFrameworkToOutputPath>true</AppendTargetFrameworkToOutputPath>
|
||||||
<CopyRefAssembliesToPublishDirectory>false</CopyRefAssembliesToPublishDirectory>
|
<CopyRefAssembliesToPublishDirectory>false</CopyRefAssembliesToPublishDirectory>
|
||||||
@@ -18,7 +19,6 @@
|
|||||||
|
|
||||||
<IncludeSymbols>true</IncludeSymbols>
|
<IncludeSymbols>true</IncludeSymbols>
|
||||||
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
|
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
|
||||||
<EmbedUntrackedSources>false</EmbedUntrackedSources>
|
|
||||||
|
|
||||||
<Title>Modular Cloudflare API implementation in .NET</Title>
|
<Title>Modular Cloudflare API implementation in .NET</Title>
|
||||||
<Company>AM.WD</Company>
|
<Company>AM.WD</Company>
|
||||||
@@ -26,20 +26,26 @@
|
|||||||
<Copyright>© {copyright:2025-} AM.WD</Copyright>
|
<Copyright>© {copyright:2025-} AM.WD</Copyright>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<PropertyGroup Condition="'$(GITLAB_CI)' == 'true'">
|
<PropertyGroup Condition="'$(CI)' == 'true'">
|
||||||
<ContinuousIntegrationBuild>true</ContinuousIntegrationBuild>
|
<ContinuousIntegrationBuild>true</ContinuousIntegrationBuild>
|
||||||
|
<EmbedUntrackedSources>true</EmbedUntrackedSources>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup Condition="'$(GITLAB_CI)' == 'true'">
|
<!-- Only build package for Debug on CI (only dev NuGet feed) -->
|
||||||
<SourceLinkGitLabHost Include="$(CI_SERVER_HOST)" Version="$(CI_SERVER_VERSION)" />
|
<PropertyGroup Condition="'$(Configuration)' == 'Debug' and '$(CI)' == 'true'">
|
||||||
<PackageReference Include="Microsoft.SourceLink.GitLab" Version="8.0.0">
|
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
|
||||||
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<ItemGroup Condition="'$(CI)' == 'true'">
|
||||||
|
<SourceLinkGiteaHost Include="$(CI_SERVER_HOST)" />
|
||||||
|
<PackageReference Include="Microsoft.SourceLink.Gitea" Version="8.0.0">
|
||||||
<PrivateAssets>all</PrivateAssets>
|
<PrivateAssets>all</PrivateAssets>
|
||||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||||
</PackageReference>
|
</PackageReference>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<PackageReference Include="AMWD.NetRevisionTask" Version="1.3.0">
|
<PackageReference Include="AMWD.NetRevisionTask" Version="1.4.0">
|
||||||
<PrivateAssets>all</PrivateAssets>
|
<PrivateAssets>all</PrivateAssets>
|
||||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||||
</PackageReference>
|
</PackageReference>
|
||||||
|
|||||||
@@ -15,7 +15,7 @@
|
|||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<!-- Only build package for tagged releases or Debug on CI (only dev NuGet feed) -->
|
<!-- Only build package for tagged releases or Debug on CI (only dev NuGet feed) -->
|
||||||
<PropertyGroup Condition="$([System.Text.RegularExpressions.Regex]::IsMatch('$(CI_COMMIT_TAG)', '^dns\/v[0-9.]+')) or ('$(Configuration)' == 'Debug' and '$(GITLAB_CI)' == 'true')">
|
<PropertyGroup Condition="$([System.Text.RegularExpressions.Regex]::IsMatch('$(CI_COMMIT_TAG)', '^dns\/v[0-9.]+'))">
|
||||||
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
|
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
|
|||||||
@@ -15,7 +15,7 @@
|
|||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<!-- Only build package for tagged releases or Debug on CI (only dev NuGet feed) -->
|
<!-- Only build package for tagged releases or Debug on CI (only dev NuGet feed) -->
|
||||||
<PropertyGroup Condition="$([System.Text.RegularExpressions.Regex]::IsMatch('$(CI_COMMIT_TAG)', '^zones\/v[0-9.]+')) or ('$(Configuration)' == 'Debug' and '$(GITLAB_CI)' == 'true')">
|
<PropertyGroup Condition="$([System.Text.RegularExpressions.Regex]::IsMatch('$(CI_COMMIT_TAG)', '^zones\/v[0-9.]+'))">
|
||||||
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
|
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user