Esquio Nightly Build #1769
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
name: Esquio Nightly Build | |
on: | |
schedule: | |
- cron: '0 6 * * *' | |
jobs: | |
build: | |
env: | |
BUILD_CONFIG: Release | |
VERSION_SUFFIX: -preview${{ github.run_id }} | |
name: Build | |
runs-on: ubuntu-latest | |
services: | |
sql-server: | |
image: mcr.microsoft.com/mssql/server:2019-latest | |
env: | |
ACCEPT_EULA: Y | |
MSSQL_SA_PASSWORD: Password12! | |
ports: | |
- 5433:1433 | |
postgres: | |
image: postgres | |
ports: | |
- 5434:5432 | |
env: | |
POSTGRES_PASSWORD: Password12! | |
mysql: | |
image: mysql | |
ports: | |
- 3306:3306 | |
env: | |
MYSQL_ROOT_PASSWORD: Password12! | |
MYSQL_USER: mysql | |
MYSQL_PASSWORD: Password12! | |
steps: | |
- uses: actions/checkout@v1 | |
- name: Setup .NET Core SDK | |
uses: actions/[email protected] | |
with: | |
dotnet-version: 6.0.201 | |
- name: dotnet build | |
run: dotnet build Esquio.sln -c $BUILD_CONFIG | |
- name: dotnet test [UnitTests] | |
run: dotnet test ./tests/UnitTests/UnitTests.csproj -c $BUILD_CONFIG --no-build | |
- name: dotnet test [FunctionalTests-SqlServer] | |
run: dotnet test ./tests/FunctionalTests/FunctionalTests.csproj -c $BUILD_CONFIG --no-build | |
env: | |
Data__Store: "SqlServer" | |
Data__ConnectionString: "Server=tcp:localhost,5433;Initial Catalog=Esquio.UI;User Id=sa;Password=Password12!;Encrypt=False" | |
- name: dotnet test [FunctionalTests-Postgres] | |
run: dotnet test ./tests/FunctionalTests/FunctionalTests.csproj -c $BUILD_CONFIG --no-build | |
env: | |
Data__Store: "NpgSql" | |
Data__ConnectionString: "Host=localhost;Port=5434;Database=Esquio.UI.Tests;User Id=postgres;Password=Password12!" | |
- name: dotnet test [FunctionalTests-MySql] | |
run: dotnet test ./tests/FunctionalTests/FunctionalTests.csproj -c $BUILD_CONFIG --no-build | |
env: | |
Data__Store: "MySql" | |
Data__ConnectionString: "Server=localhost;Database=Esquio.UI.Tests;Uid=root;Pwd=Password12!;" | |
- name: dotnet pack [Esquio] | |
run: dotnet pack ./src/Esquio/Esquio.csproj -o ./artifacts -c $BUILD_CONFIG --version-suffix $VERSION_SUFFIX --no-build --include-source --include-symbols | |
- name: dotnet pack [Esquio.AspNetCore] | |
run: dotnet pack ./src/Esquio.AspNetCore/Esquio.AspNetCore.csproj -o ./artifacts -c $BUILD_CONFIG --version-suffix $VERSION_SUFFIX --no-build --include-source --include-symbols | |
- name: dotnet pack [Esquio.AspNetCore.ApplicationInsightProcessor] | |
run: dotnet pack ./src/Esquio.AspNetCore.ApplicationInsightProcessor/Esquio.AspNetCore.ApplicationInsightProcessor.csproj -o ./artifacts -c $BUILD_CONFIG --version-suffix $VERSION_SUFFIX --no-build --include-source --include-symbols | |
- name: dotnet pack [Esquio.Configuration.Store] | |
run: dotnet pack ./src/Esquio.Configuration.Store/Esquio.Configuration.Store.csproj -o ./artifacts -c $BUILD_CONFIG --version-suffix $VERSION_SUFFIX --no-build --include-source --include-symbols | |
- name: dotnet pack [Esquio.Http.Store] | |
run: dotnet pack ./src/Esquio.Http.Store/Esquio.Http.Store.csproj -o ./artifacts -c $BUILD_CONFIG --version-suffix $VERSION_SUFFIX --no-build --include-source --include-symbols | |
- name: dotnet pack [Esquio.Blazor.WebAssembly] | |
run: dotnet pack ./src/Esquio.Blazor.WebAssembly/Esquio.Blazor.WebAssembly.csproj -o ./artifacts -c $BUILD_CONFIG --version-suffix $VERSION_SUFFIX --no-build --include-source --include-symbols | |
- name: dotnet pack [Esquio.MiniProfiler] | |
run: dotnet pack ./tools/Esquio.MiniProfiler/Esquio.MiniProfiler.csproj -c $BUILD_CONFIG --no-build --version-suffix $VERSION_SUFFIX --include-source --include-symbols | |
- name: dotnet pack [Esquio.CLi] | |
run: dotnet pack ./tools/Esquio.CliTool/Esquio.CliTool.csproj -c $BUILD_CONFIG --no-build --version-suffix $VERSION_SUFFIX --include-source --include-symbols | |
- name: Publish GitHub Packages | |
run: | | |
for f in ./artifacts/*.nupkg | |
do | |
echo "Publishing $f" | |
curl --silent -X PUT -u "Xabaril:${{ secrets.GITHUB_TOKEN }}" -F package=@$f https://nuget.pkg.github.com/Xabaril/ | |
if [ $? -eq 0 ] | |
then | |
echo "successfully pushed $f" | |
else | |
echo "failed to push $f" >&2 | |
exit 1 | |
fi | |
done | |
shell: bash |