diff options
Diffstat (limited to 'internal/workflows/step.go')
| -rw-r--r-- | internal/workflows/step.go | 26 |
1 files changed, 25 insertions, 1 deletions
diff --git a/internal/workflows/step.go b/internal/workflows/step.go index 17ca25e1..fc95fd69 100644 --- a/internal/workflows/step.go +++ b/internal/workflows/step.go @@ -52,11 +52,35 @@ func newCIRequest(display, name, id string) Step { } } +// download is a step to obtain a hakurei distribution. +var download = Step{ + Name: "Download hakurei distribution", + ID: "download", + Uses: "actions/download-artifact@v3", + + With: []KV[any]{ + {"name", "dist-${{ needs.dist.outputs.rev }}"}, + {"path", "result"}, + }, +} + +// _download is like download, but with race instrument. +var _download = Step{ + Name: "Download hakurei distribution", + ID: "download", + Uses: "actions/download-artifact@v3", + + With: []KV[any]{ + {"name", "dist-${{ needs.dist-race.outputs.rev }}-race"}, + {"path", "result"}, + }, +} + // install is a step to unpack and deploy a hakurei distribution created by a // step with identifier dist. var install = Step{ Name: "Install hakurei", - Run: "HAKUREI_VERSION=\"$(cat cmd/dist/VERSION)-${{ steps.dist.outputs.rev }}\" && " + + Run: "HAKUREI_VERSION=\"$(cat cmd/dist/VERSION)\" && " + "tar xf result/hakurei-$HAKUREI_VERSION*-amd64.tar.gz && " + "./hakurei-$HAKUREI_VERSION*-amd64/install.sh && " + "sudo -u ubuntu hakurei version && " + |
