Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
MH321Productions committed Jun 5, 2024
1 parent 3baf6c9 commit b26d68e
Show file tree
Hide file tree
Showing 2 changed files with 57 additions and 12 deletions.
23 changes: 13 additions & 10 deletions .ci/integrationTest.postgres.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,19 @@ debugRun() {
time $@
}

{
debugRun dockerCompose down;
# debugRun dockerCompose build;
debugRun dockerCompose up -d --no-build
} &
{
debugRun dotnet restore "Backbone.sln";
debugRun dotnet build --no-restore "Backbone.sln"
}
wait
#{
# debugRun dockerCompose down;
## debugRun dockerCompose build;
# debugRun dockerCompose up -d --no-build
#} &
#{
# debugRun dotnet restore "Backbone.sln";
# debugRun dotnet build --no-restore "Backbone.sln"
#}
#wait

debugRun dockerCompose down;
debugRun dockerCompose up -d --no-build

export CONSUMER_API_BASE_ADDRESS="http://localhost:5000"
export ADMIN_API_BASE_ADDRESS="http://localhost:5173"
Expand Down
46 changes: 44 additions & 2 deletions .github/workflows/docker-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ jobs:
cache-from: type=gha
cache-to: type=gha,mode=max
tags: ${{ matrix.tag }}
load: true
load: false
outputs: type=docker,dest=/tmp/${{ matrix.tag }}.tar
#outputs: type=registry,dest=localhost:6000/consumer-api

Expand Down Expand Up @@ -173,11 +173,47 @@ jobs:
# run: |
# rm -rf /tmp/.buildx-cache
# mv /tmp/.buildx-cache-new /tmp/.buildx-cache

build-solution:
name: Build Solution
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- uses: actions/setup-node@v3
with:
node-version: 20
check-latest: true
cache: "npm"
cache-dependency-path: "**/package-lock.json"

- name: Setup NuGet
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.x

- name: Install script dependencies
run: npm install --prefix ./.ci

- name: Restore Solution
run: dotnet restore "Backbone.sln"

- name: Build Solution
run: dotnet build --no-restore "Backbone.sln"

- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: solution
path: ./

run-tests:
name: Run tests
runs-on: ubuntu-latest
needs: docker-integration-test-postgres
needs:
- docker-integration-test-postgres
- build-solution
steps:
- name: Checkout
uses: actions/checkout@v4
Expand Down Expand Up @@ -207,6 +243,12 @@ jobs:
pattern: docker-*
merge-multiple: true

- name: Download Built solution
uses: actions/download-artifact@v4
with:
name: solution
path: .

- name: Load Docker images
run: |
docker load --input /tmp/consumer-api.tar
Expand Down

0 comments on commit b26d68e

Please sign in to comment.