1
0
mirror of synced 2026-03-25 10:12:12 +00:00
Files
Interlisp.medley/.github/workflows/buildReleaseInclDocker.yml

133 lines
3.8 KiB
YAML

#*******************************************************************************
# buidReleaseInclDocker.yml
#
# Interlisp webflow to build a Medley release and push it to github.
# And to build a multiplatform Docker image for the release and push it to Docker Hub.
# And to kickoff a build and deploy workflow for Medley-online within the online repo.
#
# This workflow just calls two reuseable workflows to the two task:
# buildLoadup.yml and buildDocker.yml
#
# 2022-01-18 Frank Halasz
#
# Copyright 2022 by Interlisp.org
#
# ******************************************************************************
name: "Build/Push Release, Docker, OIO"
# Run this workflow on ...
on:
schedule:
- cron: '17 9 * * 3'
workflow_dispatch:
inputs:
maiko_release:
description: "What maiko release to use"
type: string
default: 'Latest'
draft:
description: "Mark this as a draft release"
type: boolean
default: false
online:
description: "Deploy this release online"
type: boolean
default: true
force:
description: "Force build even if build already successfully completed for this commit"
type: boolean
default: false
workflow_call:
outputs:
successful:
description: "'True' if medley build completed successully"
value: ${{ jobs.complete.outputs.build_successful }}
inputs:
maiko_release:
description: "What maiko release to use"
required: false
type: string
default: 'Latest'
draft:
description: "Mark this as a draft release"
required: false
type: boolean
default: false
online:
description: "Deploy this release online"
required: false
type: boolean
default: true
force:
description: "Force build even if build already successfully completed for this commit"
required: false
type: boolean
default: false
defaults:
run:
shell: bash
# Jobs that compose this workflow
jobs:
######################################################################################
# Build Loadup
do_release:
uses: ./.github/workflows/buildLoadup.yml
with:
maiko_release: ${{ inputs.maiko_release }}
draft: ${{ inputs.draft }}
force: ${{ inputs.force }}
secrets: inherit
outputs:
github_release_tag: ${{ needs.do_release.outputs.github_release_tag }}
######################################################################################
# Build Docker Image
do_docker:
needs: [do_release]
uses: ./.github/workflows/buildDocker.yml
with:
github_release_tag: ${{ needs.do_release.outputs.github_release_tag }}
draft: ${{ inputs.draft }}
force: ${{ inputs.force }}
secrets: inherit
######################################################################################
# Run HCFILES and push to files.interlisp.org
do_HCFILES:
needs: [do_release]
uses: ./.github/workflows/doHCFILES.yml
with:
draft: ${{ inputs.draft }}
secrets: inherit
######################################################################################
# Kickoff workflow in online repo to build and deploy Medley docker image to oio
do_oio:
if: ${{ inputs.online }} == true
runs-on: ubuntu-24.04
needs: [do_release, do_docker]
steps:
- name: trigger-oio-buildAndDeploy
run: |
gh workflow run buildAndDeployMedleyDocker.yml \
--repo Interlisp/online --ref main \
-f github_release_tag=${{ needs.do_release.outputs.github_release_tag }} \
-f draft=${{ inputs.draft }}
env:
GITHUB_TOKEN: ${{ secrets.ONLINE_TOKEN }}