From 82c648b7cde1a250cff1a6ac97fc31efddb73c9d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Adam=20=C5=A0trauch?= Date: Sat, 12 Aug 2023 14:16:21 +0200 Subject: [PATCH] Debian 12, new version of everything, switch to task --- .drone.yml | 10 +++++----- Dockerfile | 36 ++++++++++++++++-------------------- Makefile | 3 ++- Taskfile.yml | 40 ++++++++++++++++++++++++++++++++++++++++ 4 files changed, 63 insertions(+), 26 deletions(-) create mode 100644 Taskfile.yml diff --git a/.drone.yml b/.drone.yml index 004d35d..6301ee8 100644 --- a/.drone.yml +++ b/.drone.yml @@ -4,7 +4,7 @@ name: image building steps: - name: build&push squashed image - image: harbor.hq.rosti.cz/library/builder:35 + image: harbor.hq.rosti.cz/library/builder:38 environment: username: robot$rosti+rosti password: @@ -13,7 +13,7 @@ steps: privileged: true commands: - echo "$password" | podman login -u $username --password-stdin $repo - - make DOCKER=podman push + - task push trigger: event: @@ -29,7 +29,7 @@ name: test image steps: - name: test build - image: harbor.hq.rosti.cz/library/builder:35 + image: harbor.hq.rosti.cz/library/builder:38 environment: username: robot$rosti+rosti password: @@ -38,8 +38,8 @@ steps: privileged: true commands: - echo "$password" | podman login -u $username --password-stdin $repo - - make VERSION=test DOCKER=podman build - - make DOCKER=podman VERSION=test test + - task build VERSION=test + - task testVERSION=test trigger: event: diff --git a/Dockerfile b/Dockerfile index 86c84e3..788cb1c 100644 --- a/Dockerfile +++ b/Dockerfile @@ -44,42 +44,38 @@ ENV TERM xterm ## Node.js WORKDIR /usr/src ADD build_node.sh /usr/local/bin/build_node.sh -# 2023/04 -RUN build_node.sh 16.19.0 +# 2023/08 +RUN build_node.sh 16.20.2 RUN build_node.sh 17.9.1 -RUN build_node.sh 18.12.1 -RUN build_node.sh 18.15.0 -RUN build_node.sh 19.6.0 RUN build_node.sh 19.9.0 +RUN build_node.sh 18.17.1 +RUN build_node.sh 20.5.1 ## Python WORKDIR /usr/src ADD build_python.sh /usr/local/bin/build_python.sh -# 2023/04 -RUN build_python.sh 3.9.16 -RUN build_python.sh 3.10.11 -RUN build_python.sh 3.11.3 +# 2023/08 +RUN build_python.sh 3.9.17 +RUN build_python.sh 3.10.12 +RUN build_python.sh 3.11.4 ## PHP 8 ADD build_php8.sh /usr/local/bin/build_php8.sh -# 2023/04 -RUN build_php8.sh 8.1.13 -RUN build_php8.sh 8.1.16 -RUN build_php8.sh 8.2.1 -RUN build_php8.sh 8.2.3 +# 2023/08 +RUN build_php8.sh 8.1.21 +RUN build_php8.sh 8.2.7 ## Ruby WORKDIR /usr/src ADD build_ruby.sh /usr/local/bin/build_ruby.sh -# 2022/12 -RUN build_ruby.sh 3.1.3 -RUN build_ruby.sh 3.2.0 +# 2023/08 +RUN build_ruby.sh 3.1.4 +RUN build_ruby.sh 3.2.2 ## Deno ADD build_deno.sh /usr/local/bin/build_deno.sh -# 2023/04 -RUN build_deno.sh 1.30.1 -RUN build_deno.sh 1.32.3 +# 2023/08 +RUN build_deno.sh 1.36.1 ############# diff --git a/Makefile b/Makefile index 9416917..3afad22 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,7 @@ +# TODO: Unnecessary, remo this file REPO=harbor.hq.rosti.cz/rosti/runtime DOCKER=docker -VERSION=2023.06-1 +VERSION=2023.08-1 BASEIMAGE=debian:11 all: build diff --git a/Taskfile.yml b/Taskfile.yml new file mode 100644 index 0000000..cb8dd5d --- /dev/null +++ b/Taskfile.yml @@ -0,0 +1,40 @@ +# 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