Skip to content

Commit 659029c

Browse files
committed
refactor: build and release tasks
fixes references to incorrect container build files, separates release and build tasks to make more sense, adds tasks for publishing the helm chart prepares for #45
1 parent 5712646 commit 659029c

File tree

1 file changed

+24
-1
lines changed

1 file changed

+24
-1
lines changed

Taskfile.yml

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,19 @@ dotenv: ['.env']
44

55
tasks:
66
build:image:
7+
prompt: "Before we build, is the version number up to date?"
8+
desc: builds a publishable docker image
9+
cmds:
10+
- |
11+
docker buildx build \
12+
--platform=linux/amd64,linux/arm64 \
13+
-t ghcr.io/{{.ORG_NAME}}/{{.PACKAGE_NAME}}:v{{.PROJ_VER}} \
14+
-t ghcr.io/{{.ORG_NAME}}/{{.PACKAGE_NAME}}:latest \
15+
-f Dockerfile.prod .
16+
vars:
17+
PROJ_VER:
18+
sh: "task version"
19+
release:image:
720
prompt: "Before we build, is the version number up to date?"
821
desc: builds a publishable docker image
922
cmds:
@@ -13,7 +26,17 @@ tasks:
1326
--push \
1427
-t ghcr.io/{{.ORG_NAME}}/{{.PACKAGE_NAME}}:v{{.PROJ_VER}} \
1528
-t ghcr.io/{{.ORG_NAME}}/{{.PACKAGE_NAME}}:latest \
16-
-f Dockerfile .
29+
-f Dockerfile.prod .
30+
vars:
31+
PROJ_VER:
32+
sh: "task version"
33+
release:chart:
34+
prompt: "Before we build, is the version number up to date?"
35+
desc: builds and publishes the helm chart for this project
36+
dir: charts
37+
cmds:
38+
- helm package {{.PACKAGE_NAME}}
39+
- helm push {{.PACKAGE_NAME}}-{{.PROJ_VER}}*.tgz oci://ghcr.io/{{.ORG_NAME}}/charts
1740
vars:
1841
PROJ_VER:
1942
sh: "task version"

0 commit comments

Comments
 (0)