force_build
This commit is contained in:
13
.github/workflows/build.yaml
vendored
13
.github/workflows/build.yaml
vendored
@@ -8,6 +8,9 @@ on:
|
|||||||
type: string
|
type: string
|
||||||
required: false
|
required: false
|
||||||
default: latest
|
default: latest
|
||||||
|
force_build:
|
||||||
|
type: boolean
|
||||||
|
default: false
|
||||||
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
@@ -37,9 +40,15 @@ jobs:
|
|||||||
uses: webfactory/ssh-agent@v0.9.0
|
uses: webfactory/ssh-agent@v0.9.0
|
||||||
with:
|
with:
|
||||||
ssh-private-key: ${{ secrets.LIB_SSH_KEY }}
|
ssh-private-key: ${{ secrets.LIB_SSH_KEY }}
|
||||||
- name: Build image
|
- name: Build Docker image
|
||||||
run: |
|
run: |
|
||||||
|
if [ "$NO_CACHE" == "true" ]; then
|
||||||
|
docker build -t cr.yandex/$CR_REGISTRY/$CR_REPO:${IMAGE_TAG::7} --no-cache --ssh default .
|
||||||
|
else
|
||||||
docker build -t cr.yandex/$CR_REGISTRY/$CR_REPO:${IMAGE_TAG::7} --ssh default .
|
docker build -t cr.yandex/$CR_REGISTRY/$CR_REPO:${IMAGE_TAG::7} --ssh default .
|
||||||
|
fi
|
||||||
|
env:
|
||||||
|
NO_CACHE: ${{ inputs.force_build || 'false' }}
|
||||||
- name: Yandex Cloud Login
|
- name: Yandex Cloud Login
|
||||||
uses: yc-actions/yc-cr-login@v2
|
uses: yc-actions/yc-cr-login@v2
|
||||||
with:
|
with:
|
||||||
@@ -59,4 +68,4 @@ jobs:
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
${{ if 1 }}: value: a ${{ else }}: value: b
|
||||||
Reference in New Issue
Block a user