diff --git a/.github/workflows/dockers-buildbase-image.yml b/.github/workflows/dockers-buildbase-image.yml new file mode 100644 index 0000000000..4b99dc4027 --- /dev/null +++ b/.github/workflows/dockers-buildbase-image.yml @@ -0,0 +1,48 @@ +# +# Copyright (C) 2019-2024 vdaas.org vald team +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# You may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +name: "Build docker image: buildbase" +on: + schedule: + - cron: "0 1 * * *" + push: + branches: + - "main" + - "release/v*.*" + - "!release/v*.*.*" + tags: + - "*.*.*" + - "v*.*.*" + - "*.*.*-*" + - "v*.*.*-*" + pull_request: + paths: + - ".github/actions/docker-build/action.yaml" + - ".github/workflows/_docker-image.yaml" + - ".github/workflows/dockers-buildbase-image.yml" + - "dockers/buildbase/Dockerfile" + pull_request_target: + paths: + - ".github/actions/docker-build/action.yaml" + - ".github/workflows/_docker-image.yaml" + - ".github/workflows/dockers-buildbase-image.yml" + - "dockers/buildbase/Dockerfile" +jobs: + build: + uses: ./.github/workflows/_docker-image.yaml + with: + target: buildbase + platforms: linux/amd64,linux/arm64 + secrets: inherit diff --git a/Makefile b/Makefile index 1b08e62324..4dfc1b0138 100644 --- a/Makefile +++ b/Makefile @@ -25,6 +25,7 @@ AGENT_NGT_IMAGE = $(NAME)-agent-ngt AGENT_FAISS_IMAGE = $(NAME)-agent-faiss AGENT_SIDECAR_IMAGE = $(NAME)-agent-sidecar AGENT_IMAGE = $(NAME)-agent +BUILDBASE_IMAGE = $(NAME)-buildbase CI_CONTAINER_IMAGE = $(NAME)-ci-container DEV_CONTAINER_IMAGE = $(NAME)-dev-container DISCOVERER_IMAGE = $(NAME)-discoverer-k8s diff --git a/Makefile.d/docker.mk b/Makefile.d/docker.mk index 96d1db40db..e466f8b368 100644 --- a/Makefile.d/docker.mk +++ b/Makefile.d/docker.mk @@ -175,6 +175,17 @@ docker/build/manager-index: IMAGE=$(MANAGER_INDEX_IMAGE) \ docker/build/image +.PHONY: docker/name/buildbase +docker/name/buildbase: + @echo "$(ORG)/$(BUILDBASE_IMAGE)" + +.PHONY: docker/build/buildbase +## build buildbase image +docker/build/buildbase: + @make DOCKERFILE="$(ROOTDIR)/dockers/buildbase/Dockerfile" \ + IMAGE=$(BUILDBASE_IMAGE) \ + docker/build/image + .PHONY: docker/name/ci-container docker/name/ci-container: @echo "$(ORG)/$(CI_CONTAINER_IMAGE)" diff --git a/dockers/buildbase/Dockerfile b/dockers/buildbase/Dockerfile new file mode 100644 index 0000000000..9be2e4b20b --- /dev/null +++ b/dockers/buildbase/Dockerfile @@ -0,0 +1,18 @@ +# syntax = docker/dockerfile:latest +# +# Copyright (C) 2019-2024 vdaas.org vald team +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# You may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# + +FROM ubuntu:devel AS builder