Skip to content

Commit

Permalink
ci(general): updates to v1.2.1 and forge v0.4.0 (#1035)
Browse files Browse the repository at this point in the history
* chore(ci): updates to v1.2.1 and forge 0.4.0

* fix: updates test report workflow

* wip: use local version of allure workflow
  • Loading branch information
jmgilman authored Oct 22, 2024
1 parent c93d691 commit f78f326
Show file tree
Hide file tree
Showing 7 changed files with 55 additions and 26 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: CI
on:
push:
branches: [main]
tags: ['*']
tags: ['**']
pull_request:

permissions:
Expand All @@ -14,11 +14,11 @@ permissions:

jobs:
ci:
uses: input-output-hk/catalyst-forge/.github/workflows/ci.yml@ci/v1.1.0
uses: input-output-hk/catalyst-forge/.github/workflows/ci.yml@ci/v1.2.1
with:
forge_version: 0.2.1
forge_version: 0.4.0

test_reporting:
if: always()
needs: ci
uses: input-output-hk/catalyst-voices/.github/workflows/generate-allure-report.yml@main
uses: ./.github/workflows/generate-allure-report.yml
26 changes: 16 additions & 10 deletions .github/workflows/generate-allure-report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,39 +26,45 @@ jobs:
- uses: actions/checkout@v4

- name: Install Forge
uses: input-output-hk/catalyst-forge/actions/install@ci/v1.1.0
uses: input-output-hk/catalyst-forge/actions/install@ci/v1.2.1
with:
version: 0.4.0
if: always()

- name: Setup CI
uses: input-output-hk/catalyst-forge/actions/setup@ci/v1.1.0
uses: input-output-hk/catalyst-forge/actions/setup@ci/v1.2.1

- name: Get catalyst gateway unit test report
uses: input-output-hk/catalyst-forge/actions/run@ci/v1.1.0
uses: input-output-hk/catalyst-forge/actions/run@ci/v1.2.1
if: always()
continue-on-error: true
with:
path: ./catalyst-gateway+build
command: run
args: ./catalyst-gateway+build

- name: Get schemathesis test report
uses: input-output-hk/catalyst-forge/actions/run@ci/v1.1.0
uses: input-output-hk/catalyst-forge/actions/run@ci/v1.2.1
if: always()
continue-on-error: true
with:
path: ./catalyst-gateway/tests/schemathesis_tests+test-fuzzer-api
command: run
args: ./catalyst-gateway/tests/schemathesis_tests+test-fuzzer-api

- name: Get flutter unit test report
uses: input-output-hk/catalyst-forge/actions/run@ci/v1.1.0
uses: input-output-hk/catalyst-forge/actions/run@ci/v1.2.1
if: always()
continue-on-error: true
with:
path: ./catalyst_voices+test-unit
command: run
args: ./catalyst_voices+test-unit

- name: Get python api test report
uses: input-output-hk/catalyst-forge/actions/run@ci/v1.1.0
uses: input-output-hk/catalyst-forge/actions/run@ci/v1.2.1
if: always()
continue-on-error: true
with:
path: ./catalyst-gateway/tests/api_tests+test
command: run
args: ./catalyst-gateway/tests/api_tests+test

- name: Collect and upload test reports
uses: actions/upload-artifact@v4
Expand Down
9 changes: 4 additions & 5 deletions blueprint.cue
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@ global: {
"^build(-.*)?$",
"^package(-.*)?$",
"^test(-.*)?$",
"^release(-.*)?$",
"^publish(-.*)?$",
]
registries: [
ci.providers.aws.registry,
Expand Down Expand Up @@ -49,9 +47,6 @@ global: {
path: "GITHUB_TOKEN"
},
]
tagging: {
strategy: "commit"
}
}
deployment: {
registry: ci.providers.aws.registry
Expand All @@ -61,4 +56,8 @@ global: {
}
root: "k8s"
}
repo: {
defaultBranch: "main"
name: "input-output-hk/catalyst-voices"
}
}
8 changes: 4 additions & 4 deletions catalyst-gateway/Earthfile
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ COPY_SRC:

# builder : Set up our target toolchains, and copy our files.
builder:
DO rust-ci+SETUP
DO rust-ci+SETUP

# sync-cfg: Synchronize local config with CI version.
# Must be run by the developer manually.
Expand All @@ -36,7 +36,7 @@ builder-src:

# Generate Checksums of the source
DO rust-ci+FINGERPRINT_SRC
SAVE ARTIFACT ../src_fingerprint.txt
SAVE ARTIFACT ../src_fingerprint.txt

## -----------------------------------------------------------------------------
##
Expand Down Expand Up @@ -89,7 +89,7 @@ package:
ENTRYPOINT [ "./cat-gateway", "run" ]

# Publish cat-gateway
publish:
docker:
FROM +package

ARG container="cat-gateway"
Expand All @@ -109,7 +109,7 @@ check-builder-src-cache:

# Don't build the src in the home directory itself, because it contains stuff.
WORKDIR $HOME/build
RUN rm -rf *
RUN rm -rf *

COPY +builder-src/src_fingerprint.txt ..

Expand Down
15 changes: 14 additions & 1 deletion catalyst-gateway/blueprint.cue
Original file line number Diff line number Diff line change
@@ -1,2 +1,15 @@
version: "1.0.0"
project: name: "gateway"
project: {
name: "gateway"
release: {
docker: {
on: {
merge: {}
tag: {}
}
config: {
tag: _ @forge(name="GIT_COMMIT_HASH")
}
}
}
}
2 changes: 1 addition & 1 deletion catalyst_voices/Earthfile
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ package:

SAVE IMAGE voices-frontend:$tag

publish:
docker:
FROM +package

ARG container="voices"
Expand Down
13 changes: 12 additions & 1 deletion catalyst_voices/blueprint.cue
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,20 @@ project: {
values: {
environment: name: "dev"
frontend: image: {
tag: _ @env(name="GIT_IMAGE_TAG",type="string")
tag: _ @forge(name="GIT_COMMIT_HASH")
}
}
}
}
release: {
docker: {
on: {
merge: {}
tag: {}
}
config: {
tag: _ @forge(name="GIT_COMMIT_HASH")
}
}
}
}

0 comments on commit f78f326

Please sign in to comment.