-
-
Notifications
You must be signed in to change notification settings - Fork 234
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #9488 from bitfoundation/develop
Version v-9.1.0 (#9484)
- Loading branch information
Showing
502 changed files
with
14,158 additions
and
4,246 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,8 +3,7 @@ | |
# Project templates come equipped with CI/CD for both Azure DevOps and GitHub, providing you with a hassle-free way to get started with your new project. It is important to note that you should not depend on the contents of this file. More info at https://bitplatform.dev/templates/dev-ops | ||
|
||
env: | ||
API_SERVER_ADDRESS: 'https://adminpanel-api.bitplatform.dev' | ||
WEB_SERVER_ADDRESS: 'https://adminpanel.bitplatform.dev' | ||
SERVER_ADDRESS: 'https://adminpanel.bitplatform.dev' | ||
APP_SERVICE_NAME: 'bit-adminpanel' | ||
|
||
on: | ||
|
@@ -29,25 +28,26 @@ jobs: | |
- name: Setup .NET | ||
uses: actions/setup-dotnet@v4 | ||
with: | ||
global-json-file: src/Templates/Boilerplate/Bit.Boilerplate/global.json | ||
global-json-file: src/global.json | ||
|
||
- name: Create project from Boilerplate | ||
run: | | ||
cd src/Templates/Boilerplate && dotnet build -c Release | ||
dotnet pack -c Release -o . -p:ReleaseVersion=0.0.0 -p:PackageVersion=0.0.0 | ||
dotnet new install Bit.Boilerplate.0.0.0.nupkg | ||
cd ../../../ && dotnet new bit-bp --name AdminPanel --database PostgreSQL --sample Admin --appInsights --serverUrl ${{ env.WEB_SERVER_ADDRESS }} --filesStorage AzureBlobStorage --api Standalone --notification --captcha reCaptcha --signalR --framework net9.0 | ||
cd ../../../ && dotnet new bit-bp --name AdminPanel --database PostgreSQL --sample Admin --appInsights --sentry --serverUrl ${{ env.SERVER_ADDRESS }} --filesStorage AzureBlobStorage --notification --captcha reCaptcha --signalR --framework net9.0 | ||
- name: Update core appsettings.json | ||
uses: devops-actions/[email protected] | ||
with: | ||
files: 'AdminPanel/src/Shared/appsettings.json, AdminPanel/src/Client/AdminPanel.Client.Core/appsettings.json, AdminPanel/src/Client/AdminPanel.Client.Web/appsettings.json, AdminPanel/src/Client/AdminPanel.Client.Web/appsettings.Production.json' | ||
env: | ||
ServerAddress: ${{ env.API_SERVER_ADDRESS }} | ||
GoogleRecaptchaSiteKey: ${{ secrets.GOOGLE_RECAPTCHA_SITE_KEY }} | ||
WebAppRender.BlazorMode: BlazorWebAssembly | ||
ApplicationInsights.ConnectionString: ${{ secrets.APPLICATION_INSIGHTS_CONNECTION_STRING }} | ||
ServerAddress: ${{ env.SERVER_ADDRESS }} | ||
Logging.Sentry.Dsn: ${{ secrets.ADMINPANEL_SENTRY_DSN }} | ||
GoogleRecaptchaSiteKey: ${{ secrets.GOOGLE_RECAPTCHA_SITE_KEY }} | ||
AdsPushVapid.PublicKey: ${{ secrets.ADMINPANEL_PUBLIC_VAPIDKEY }} | ||
ApplicationInsights.ConnectionString: ${{ secrets.APPLICATION_INSIGHTS_CONNECTION_STRING }} | ||
|
||
- uses: actions/setup-node@v4 | ||
with: | ||
|
@@ -60,24 +60,13 @@ jobs: | |
run: dotnet build AdminPanel/src/Client/AdminPanel.Client.Core/AdminPanel.Client.Core.csproj -t:BeforeBuildTasks -p:Version="${{ vars.APPLICATION_DISPLAY_VERSION}}" --no-restore -c Release | ||
|
||
- name: Publish | ||
run: dotnet publish AdminPanel/src/Server/AdminPanel.Server.Api/AdminPanel.Server.Api.csproj -c Release -p:PwaEnabled=true --self-contained -r linux-x64 -o ${{env.DOTNET_ROOT}}/server -p:Version="${{ vars.APPLICATION_DISPLAY_VERSION}}" | ||
run: dotnet publish AdminPanel/src/Server/AdminPanel.Server.Web/AdminPanel.Server.Web.csproj -c Release -p:PwaEnabled=true --self-contained -r linux-x64 -o ${{env.DOTNET_ROOT}}/server -p:Version="${{ vars.APPLICATION_DISPLAY_VERSION}}" | ||
|
||
- name: Upload server artifact | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: server-bundle | ||
path: ${{env.DOTNET_ROOT}}/server | ||
|
||
- name: Publish adminpanel blazor wasm standalone | ||
run: | | ||
sed -i 's/adminpanel.bitplatform.dev/adminpanel-api.bitplatform.dev/g' AdminPanel/src/Client/AdminPanel.Client.Web/wwwroot/index.html | ||
dotnet publish AdminPanel/src/Client/AdminPanel.Client.Web/AdminPanel.Client.Web.csproj -c Release -p:PwaEnabled=true -o ${{env.DOTNET_ROOT}}/static -p:Version="${{ vars.APPLICATION_DISPLAY_VERSION}}" | ||
- name: Upload static artifact | ||
uses: actions/upload-artifact@v4 | ||
with: | ||
name: static-bundle | ||
path: ${{env.DOTNET_ROOT}}/static | ||
include-hidden-files: true # Required for wwwroot/.well-known folder | ||
|
||
deploy_api_blazor: | ||
|
@@ -106,6 +95,9 @@ jobs: | |
fileName: 'DataProtectionCertificate.pfx' | ||
encodedString: ${{ secrets.API_DATA_PROTECTION_CERTIFICATE_FILE_BASE64 }} | ||
|
||
- name: Retrieve AppleAuthKey.p8 | ||
run: echo "${{ secrets.APPSTORE_API_KEY_PRIVATE_KEY_ADMIN }}" > AppleAuthKey.p8 | ||
|
||
- name: Deploy to Azure Web App | ||
id: deploy-to-webapp | ||
uses: azure/webapps-deploy@v3 | ||
|
@@ -133,7 +125,7 @@ jobs: | |
- name: Setup .NET | ||
uses: actions/setup-dotnet@v4 | ||
with: | ||
global-json-file: src\Templates\Boilerplate\Bit.Boilerplate\global.json | ||
global-json-file: src\global.json | ||
|
||
- uses: actions/setup-node@v4 | ||
with: | ||
|
@@ -144,27 +136,28 @@ jobs: | |
cd src\Templates\Boilerplate && dotnet build -c Release | ||
dotnet pack -c Release -o . -p:ReleaseVersion=0.0.0 -p:PackageVersion=0.0.0 | ||
dotnet new install Bit.Boilerplate.0.0.0.nupkg | ||
cd ..\..\..\ && dotnet new bit-bp --name AdminPanel --database PostgreSQL --sample Admin --windows --appInsights --serverUrl ${{ env.WEB_SERVER_ADDRESS }} --filesStorage AzureBlobStorage --captcha reCaptcha --signalR --offlineDb --framework net9.0 | ||
cd ..\..\..\ && dotnet new bit-bp --name AdminPanel --database PostgreSQL --sample Admin --windows --appInsights --sentry --serverUrl ${{ env.SERVER_ADDRESS }} --filesStorage AzureBlobStorage --captcha reCaptcha --signalR --offlineDb --framework net9.0 | ||
- name: Update core appsettings.json | ||
uses: devops-actions/[email protected] | ||
with: | ||
files: 'AdminPanel\src\Shared\appsettings.json, AdminPanel\src\Client\AdminPanel.Client.Core\appsettings.json, AdminPanel\src\Client\AdminPanel.Client.Windows\appsettings.json' | ||
env: | ||
ServerAddress: ${{ env.API_SERVER_ADDRESS }} | ||
ServerAddress: ${{ env.SERVER_ADDRESS }} | ||
Logging.Sentry.Dsn: ${{ secrets.ADMINPANEL_SENTRY_DSN }} | ||
GoogleRecaptchaSiteKey: ${{ secrets.GOOGLE_RECAPTCHA_SITE_KEY }} | ||
WindowsUpdate.FilesUrl: https://windows-adminpanel.bitplatform.dev | ||
ApplicationInsights.ConnectionString: ${{ secrets.APPLICATION_INSIGHTS_CONNECTION_STRING }} | ||
|
||
- name: Generate CSS/JS files | ||
run: dotnet build AdminPanel\src\Client\AdminPanel.Client.Core\AdminPanel.Client.Core.csproj -t:BeforeBuildTasks -p:Version="${{ vars.APPLICATION_DISPLAY_VERSION}}" --no-restore -c Release | ||
|
||
- name: Publish | ||
run: | | ||
cd AdminPanel\src\Client\AdminPanel.Client.Windows\ | ||
dotnet publish AdminPanel.Client.Windows.csproj -c Release -o .\publish-result -r win-x86 -p:Version="${{ vars.APPLICATION_DISPLAY_VERSION}}" -p:CompressionEnabled=false | ||
dotnet publish AdminPanel.Client.Windows.csproj -c Release -o .\publish-result -r win-x86 -p:Version="${{ vars.APPLICATION_DISPLAY_VERSION}}" --self-contained | ||
dotnet tool restore | ||
dotnet vpk pack -u AdminPanel.Client.Windows -v "${{ vars.APPLICATION_DISPLAY_VERSION }}" -p .\publish-result -e AdminPanel.Client.Windows.exe -r win-x86 --framework net9.0-x86-desktop,webview2 --icon .\wwwroot\favicon.ico --packTitle 'AdminPanel' | ||
dotnet vpk pack -u AdminPanel.Client.Windows -v "${{ vars.APPLICATION_DISPLAY_VERSION }}" -p .\publish-result -e AdminPanel.Client.Windows.exe -r win-x86 --framework webview2 --icon .\wwwroot\favicon.ico --packTitle 'AdminPanel' | ||
- name: Upload artifact | ||
uses: actions/upload-artifact@v4 | ||
|
@@ -184,14 +177,14 @@ jobs: | |
- name: Setup .NET | ||
uses: actions/setup-dotnet@v4 | ||
with: | ||
global-json-file: src/Templates/Boilerplate/Bit.Boilerplate/global.json | ||
global-json-file: src/global.json | ||
|
||
- name: Create project from Boilerplate | ||
run: | | ||
cd src/Templates/Boilerplate && dotnet build -c Release | ||
dotnet pack -c Release -o . -p:ReleaseVersion=0.0.0 -p:PackageVersion=0.0.0 | ||
dotnet new install Bit.Boilerplate.0.0.0.nupkg | ||
cd ../../../ && dotnet new bit-bp --name AdminPanel --database PostgreSQL --sample Admin --appInsights --appCenter --serverUrl ${{ env.WEB_SERVER_ADDRESS }} --filesStorage AzureBlobStorage --notification --captcha reCaptcha --signalR --framework net9.0 | ||
cd ../../../ && dotnet new bit-bp --name AdminPanel --database PostgreSQL --sample Admin --appInsights --sentry --serverUrl ${{ env.SERVER_ADDRESS }} --filesStorage AzureBlobStorage --notification --captcha reCaptcha --signalR --framework net9.0 | ||
- uses: actions/setup-node@v4 | ||
with: | ||
|
@@ -216,14 +209,11 @@ jobs: | |
with: | ||
files: 'AdminPanel/src/Shared/appsettings.json, AdminPanel/src/Client/AdminPanel.Client.Core/appsettings.json, AdminPanel/src/Client/AdminPanel.Client.Maui/appsettings.json' | ||
env: | ||
ServerAddress: ${{ env.API_SERVER_ADDRESS }} | ||
ServerAddress: ${{ env.SERVER_ADDRESS }} | ||
Logging.Sentry.Dsn: ${{ secrets.ADMINPANEL_SENTRY_DSN }} | ||
GoogleRecaptchaSiteKey: ${{ secrets.GOOGLE_RECAPTCHA_SITE_KEY }} | ||
ApplicationInsights.ConnectionString: ${{ secrets.APPLICATION_INSIGHTS_CONNECTION_STRING }} | ||
|
||
- name: Set app center secret | ||
run: | | ||
sed -i 's/appCenterSecret = null;/appCenterSecret = "ea9b98ea-93a0-48c7-982a-0a72f4ad6d04";/g' AdminPanel/src/Client/AdminPanel.Client.Maui/MauiProgram.cs | ||
- name: Install maui | ||
run: cd src && dotnet workload install maui-android | ||
|
||
|
@@ -235,8 +225,8 @@ jobs: | |
dotnet build AdminPanel/src/Client/AdminPanel.Client.Core/AdminPanel.Client.Core.csproj -t:BeforeBuildTasks -p:Version="${{ vars.APPLICATION_DISPLAY_VERSION}}" --no-restore -c Release | ||
dotnet build AdminPanel/src/Client/AdminPanel.Client.Maui/AdminPanel.Client.Maui.csproj -t:BeforeBuildTasks -p:Version="${{ vars.APPLICATION_DISPLAY_VERSION}}" --no-restore -c Release | ||
- name: Build aab | ||
run: dotnet publish AdminPanel/src/Client/AdminPanel.Client.Maui/AdminPanel.Client.Maui.csproj -c Release -p:AndroidPackageFormat=aab -p:AndroidKeyStore=true -p:AndroidSigningKeyStore="AdminPanel.keystore" -p:AndroidSigningKeyAlias=bitplatform -p:AndroidSigningKeyPass="${{ secrets.ANDROID_RELEASE_KEYSTORE_PASSWORD }}" -p:AndroidSigningStorePass="${{ secrets.ANDROID_RELEASE_SIGNING_PASSWORD }}" -p:ApplicationDisplayVersion="${{ vars.APPLICATION_DISPLAY_VERSION }}" -p:ApplicationVersion="${{ vars.APPLICATION_VERSION }}" -p:Version="${{ vars.APPLICATION_DISPLAY_VERSION}}" -p:ApplicationTitle="AdminPanel" -p:ApplicationId="com.bitplatform.AdminPanel.Template" -p:CompressionEnabled=false -f net9.0-android | ||
- name: Publish aab | ||
run: dotnet publish AdminPanel/src/Client/AdminPanel.Client.Maui/AdminPanel.Client.Maui.csproj -c Release -p:AndroidPackageFormat=aab -p:AndroidKeyStore=true -p:AndroidSigningKeyStore="AdminPanel.keystore" -p:AndroidSigningKeyAlias=bitplatform -p:AndroidSigningKeyPass="${{ secrets.ANDROID_RELEASE_KEYSTORE_PASSWORD }}" -p:AndroidSigningStorePass="${{ secrets.ANDROID_RELEASE_SIGNING_PASSWORD }}" -p:ApplicationDisplayVersion="${{ vars.APPLICATION_DISPLAY_VERSION }}" -p:ApplicationVersion="${{ vars.APPLICATION_VERSION }}" -p:Version="${{ vars.APPLICATION_DISPLAY_VERSION}}" -p:ApplicationTitle="AdminPanel" -p:ApplicationId="com.bitplatform.AdminPanel.Template" -f net9.0-android | ||
|
||
- name: Upload artifact | ||
uses: actions/upload-artifact@v4 | ||
|
@@ -256,11 +246,11 @@ jobs: | |
- name: Setup .NET | ||
uses: actions/setup-dotnet@v4 | ||
with: | ||
global-json-file: src/Templates/Boilerplate/Bit.Boilerplate/global.json | ||
global-json-file: src/global.json | ||
|
||
- uses: maxim-lobanov/[email protected] | ||
with: | ||
xcode-version: '16.0' | ||
xcode-version: '16.2' | ||
|
||
- uses: actions/setup-node@v4 | ||
with: | ||
|
@@ -271,21 +261,18 @@ jobs: | |
cd src/Templates/Boilerplate && dotnet build -c Release | ||
dotnet pack -c Release -o . -p:ReleaseVersion=0.0.0 -p:PackageVersion=0.0.0 | ||
dotnet new install Bit.Boilerplate.0.0.0.nupkg | ||
cd ../../../ && dotnet new bit-bp --name AdminPanel --database PostgreSQL --sample Admin --appInsights --appCenter --serverUrl ${{ env.WEB_SERVER_ADDRESS }} --filesStorage AzureBlobStorage --notification --captcha reCaptcha --signalR --framework net9.0 | ||
cd ../../../ && dotnet new bit-bp --name AdminPanel --database PostgreSQL --sample Admin --appInsights --sentry --serverUrl ${{ env.SERVER_ADDRESS }} --filesStorage AzureBlobStorage --notification --captcha reCaptcha --signalR --framework net9.0 | ||
- name: Update core appsettings.json | ||
uses: devops-actions/[email protected] | ||
with: | ||
files: 'AdminPanel/src/Shared/appsettings.json, AdminPanel/src/Client/AdminPanel.Client.Core/appsettings.json, AdminPanel/src/Client/AdminPanel.Client.Maui/appsettings.json' | ||
env: | ||
ServerAddress: ${{ env.API_SERVER_ADDRESS }} | ||
ServerAddress: ${{ env.SERVER_ADDRESS }} | ||
Logging.Sentry.Dsn: ${{ secrets.ADMINPANEL_SENTRY_DSN }} | ||
GoogleRecaptchaSiteKey: ${{ secrets.GOOGLE_RECAPTCHA_SITE_KEY }} | ||
ApplicationInsights.ConnectionString: ${{ secrets.APPLICATION_INSIGHTS_CONNECTION_STRING }} | ||
|
||
- name: Set app center secret | ||
run: | | ||
brew install gnu-sed && gsed -i 's/appCenterSecret = null;/appCenterSecret = "0bc0d910-dc84-4887-a3a0-eee6b1b55797";/g' AdminPanel/src/Client/AdminPanel.Client.Maui/MauiProgram.cs | ||
- name: Install maui | ||
run: cd src && dotnet workload install maui | ||
|
||
|
@@ -309,7 +296,7 @@ jobs: | |
dotnet build AdminPanel/src/Client/AdminPanel.Client.Maui/AdminPanel.Client.Maui.csproj -t:BeforeBuildTasks -p:Version="${{ vars.APPLICATION_DISPLAY_VERSION}}" --no-restore -c Release | ||
- name: Build ipa | ||
run: dotnet publish AdminPanel/src/Client/AdminPanel.Client.Maui/AdminPanel.Client.Maui.csproj -p:RuntimeIdentifier=ios-arm64 -c Release -p:ArchiveOnBuild=true -p:CodesignKey="iPhone Distribution" -p:CodesignProvision="AdminPanel" -p:ApplicationDisplayVersion="${{ vars.APPLICATION_DISPLAY_VERSION }}" -p:ApplicationVersion="${{ vars.APPLICATION_VERSION }}" -p:Version="${{ vars.APPLICATION_DISPLAY_VERSION}}" -p:ApplicationTitle="AdminPanel" -p:ApplicationId="com.bitplatform.AdminPanel.Template" -p:CompressionEnabled=false -f net9.0-ios | ||
run: dotnet publish AdminPanel/src/Client/AdminPanel.Client.Maui/AdminPanel.Client.Maui.csproj -p:RuntimeIdentifier=ios-arm64 -c Release -p:ArchiveOnBuild=true -p:CodesignKey="iPhone Distribution" -p:CodesignProvision="AdminPanel" -p:ApplicationDisplayVersion="${{ vars.APPLICATION_DISPLAY_VERSION }}" -p:ApplicationVersion="${{ vars.APPLICATION_VERSION }}" -p:Version="${{ vars.APPLICATION_DISPLAY_VERSION}}" -p:ApplicationTitle="AdminPanel" -p:ApplicationId="com.bitplatform.AdminPanel.Template" -f net9.0-ios | ||
|
||
- name: Upload artifact | ||
uses: actions/upload-artifact@v4 | ||
|
Oops, something went wrong.