Skip to content

Building development #214

Building development

Building development #214

Workflow file for this run

# Copyright 2023 Iguazio
#
# 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
#
# http://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.
#
# This name is referenced in the release.yaml workflow, if you're changing here - change there
name: Build
run-name: Building ${{ inputs.version }} ${{ github.ref_name }}
permissions:
# Allow the action to upload images to ghcr
packages: write
on:
push:
branches:
- development
- '[0-9]+.[0-9]+.x'
workflow_dispatch:
inputs:
docker_registries:
description: 'Comma separated list of docker registries to push images to (default: ghcr.io/, use registry.hub.docker.com/ for docker hub)'
required: true
default: 'ghcr.io/'
docker_repo:
description: 'Docker repo to push images to (default: lowercase github repository owner name)'
required: false
default: ''
version:
description: 'The version to build, without prefix v (e.g. 1.1.0), if not provided version will be <unstable-version-prefix>-<commit-hash>, where <unstable-version-prefix> is taken from automation/version/unstable_version_prefix'
required: false
default: ''
skip_images:
description: 'Comma separated list of images to skip building, example with all possible images: mlrun,api,base,models,models-gpu,jupyter,test'
required: false
default: ''
build_from_cache:
description: 'Whether to build images from cache or not. Default: true, set to false only if required because that will cause a significant increase in build time'
required: true
default: 'true'
type: choice
options:
- 'true'
- 'false'
jobs:
build-mlrun:
if: github.repository == 'mlrun/mlrun' || github.event_name == 'workflow_dispatch'
name: Build MLRun
uses: ./.github/workflows/build-internal.yaml
with:
docker_registries: ${{ github.event.inputs.docker_registries }}
docker_repo: ${{ github.event.inputs.docker_repo }}
version: ${{ needs.prepare-inputs.outputs.version }}
skip_images: ${{ github.event.inputs.skip_images }}
build_from_cache: ${{ github.event.inputs.build_from_cache }}
secrets: inherit