diff --git a/.github/workflows/Test_EICAR_Rock.yaml b/.github/workflows/Test_EICAR_Rock.yaml new file mode 100644 index 0000000..bd79fd9 --- /dev/null +++ b/.github/workflows/Test_EICAR_Rock.yaml @@ -0,0 +1,23 @@ +name: Build External Rock + + +on: + push: + paths: + - oci-factory_workflows/examples/Test_EICAR_Rock.yaml + workflow_dispatch: + +jobs: + build: + + uses: clay-lake/oci-factory/.github/workflows/Build-Rock.yaml@refactor-workflows + with: + oci-archive-name: "eicar-rock" + rock-repo: canonical/rocks-toolbox + rock-repo-commit: oci-factory_workflows + rockfile-directory: /oci-factory_workflows/rocks/eicar + arch-map: '{"amd64": "ubuntu-22.04"}' + + # uses: clay-lake/oci-factory/.github/workflows/Test-Rock.yaml@refactor-workflows + # with: + # oci-archive-name: "eicar-rock" \ No newline at end of file diff --git a/oci-factory_workflows/README.md b/oci-factory_workflows/README.md index e8bea92..dec6088 100644 --- a/oci-factory_workflows/README.md +++ b/oci-factory_workflows/README.md @@ -13,4 +13,15 @@ when calling this workflow. Alternatively, builds can be executed remotely on the Launchpad CI platform if available. **Examples:** -- Building an External Rock - ./examples/Build_External_Rock.yaml \ No newline at end of file +- Building an External Rock - ./examples/Build_External_Rock.yaml + + +## Test-Rock + +The Build-Rock workflow is capable of building multi architecture rocks. Github +Runners in the required target architecture must be available and configured +when calling this workflow. Alternatively, builds can be executed remotely on +the Launchpad CI platform if available. + +**Examples:** +- Test an External Rock - ./examples/Test_External_Rock.yaml \ No newline at end of file diff --git a/oci-factory_workflows/rocks/eicar/rockcraft.yaml b/oci-factory_workflows/rocks/eicar/rockcraft.yaml new file mode 100644 index 0000000..1bd77bd --- /dev/null +++ b/oci-factory_workflows/rocks/eicar/rockcraft.yaml @@ -0,0 +1,19 @@ +name: eicar-rock +summary: A test rock to check malware scanners +description: An extension of the "Hello World" rock. This rock contains the EICAR test file to test if malware scanners are working as expected +version: "latest" +license: Apache-2.0 + +base: ubuntu@22.04 +platforms: + amd64: + +parts: + hello: + plugin: nil + stage-packages: + - hello + eicar: + plugin: dump + source-type: file + source: src/eicar \ No newline at end of file diff --git a/oci-factory_workflows/rocks/eicar/src/eicar b/oci-factory_workflows/rocks/eicar/src/eicar new file mode 100644 index 0000000..a2463df --- /dev/null +++ b/oci-factory_workflows/rocks/eicar/src/eicar @@ -0,0 +1 @@ +X5O!P%@AP[4\PZX54(P^)7CC)7}$EICAR-STANDARD-ANTIVIRUS-TEST-FILE!$H+H* \ No newline at end of file