bromite-buildtools/images/bromite-source/action.yaml

41 lines
1.1 KiB
YAML
Raw Normal View History

2021-07-07 18:56:07 +05:30
name: 'Prepare Bromite Source Image'
2021-07-07 18:56:28 +05:30
description: 'Check and build Bromite sources image by version'
2021-07-07 18:56:07 +05:30
inputs:
version:
description: 'Chromium Version (example 91.0.4472.146)'
required: true
sha:
description: 'Bromite sha ref'
required: true
runs:
using: "composite"
steps:
- name: Checking image for "${{ inputs.sha }}"
shell: bash
run: |
BROMITE_SHA="${{ inputs.sha }}"
VERSION="${{ inputs.version }}"
IS_PRESENT=$(docker manifest inspect uazo/bromite:$BROMITE_SHA > /dev/null ; echo $?)
if [ $IS_PRESENT -ne "0" ]; then
echo "Image not found"
mkdir bromite-source
pushd bromite-source/
2021-07-07 19:04:13 +05:30
git clone https://github.com/uazo/bromite-buildtools
2021-07-07 18:56:07 +05:30
cd bromite-buildtools/images/bromite-source/
2021-07-08 14:56:42 +05:30
sudo docker build -t uazo/bromite:$BROMITE_SHA --progress plain \
2021-07-08 19:55:19 +05:30
--no-cache \
2021-07-07 18:56:07 +05:30
--build-arg BROMITE_SHA=$BROMITE_SHA \
--build-arg VERSION=$VERSION \
.
popd
rm -rf bromite-source
fi