41 lines
832 B
YAML
41 lines
832 B
YAML
|
# https://taskfile.dev
|
||
|
|
||
|
version: '3'
|
||
|
|
||
|
vars:
|
||
|
GREETING: Hello, World!
|
||
|
REPO: harbor.hq.rosti.cz/rosti/runtime
|
||
|
VERSION: 2023.08-1
|
||
|
BASEIMAGE: debian:bookworm
|
||
|
|
||
|
tasks:
|
||
|
default:
|
||
|
deps:
|
||
|
- build
|
||
|
|
||
|
build:
|
||
|
cmds:
|
||
|
- docker pull {{ .BASEIMAGE }}
|
||
|
- docker build -t {{ .REPO }}:dev .
|
||
|
- docker tag {{ .REPO }}:dev {{ .REPO }}:{{ .VERSION }}
|
||
|
- echo "JSON for admin:"
|
||
|
- python generate_versions.py
|
||
|
|
||
|
test:
|
||
|
cmds:
|
||
|
- bash ./tests2.sh {{ .REPO }}:{{ .VERSION }}
|
||
|
|
||
|
squashed:
|
||
|
cmds:
|
||
|
- docker pull {{ .BASEIMAGE }}
|
||
|
- docker build --squash -t {{ .REPO }}:dev-squashed .
|
||
|
- docker tag {{ .REPO }}:dev-squashed {{ .REPO }}:{{ .VERSION }}
|
||
|
- echo "JSON for admin:"
|
||
|
- python generate_versions.py
|
||
|
|
||
|
push:
|
||
|
cmds:
|
||
|
- docker push {{ .REPO }}:{{ .VERSION }}
|
||
|
deps:
|
||
|
- squashed
|