Skip to content

Commit

Permalink
fix(github): checks and release
Browse files Browse the repository at this point in the history
  • Loading branch information
Nelfimov committed Aug 23, 2024
1 parent 8fd9634 commit 7f365bb
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 46 deletions.
19 changes: 4 additions & 15 deletions .github/workflows/checks.yml
Original file line number Diff line number Diff line change
@@ -1,23 +1,12 @@
name: Checks

on: [pull_request]
on:
- pull_request

jobs:
check:
name: Typecheck, lint
name: Checks
uses: atls/shared/.github/workflows/checks.yaml@master
permissions: write-all
with:
node-version: '18'
release:
name: Release
uses: atls/shared/.github/workflows/release.yaml@master
permissions: write-all
with:
node-version: '18'
test:
name: Tests
uses: atls/shared/.github/workflows/tests.yaml@master
permissions: write-all
with:
node-version: '18'
node-version: '19'
46 changes: 15 additions & 31 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,40 +2,24 @@ name: Release

on:
pull_request:
types: [closed]
types:
- closed
branches:
- master
paths-ignore:
- '.github/**'

jobs:
run:
if: github.event.pull_request.merged == true
name: Release
runs-on: ubuntu-latest

steps:
- name: Checkout
uses: actions/checkout@v2
with:
ref: master

- name: Setup Node
uses: actions/setup-node@v2
with:
node-version: '16.13'

- name: Install
run: yarn install

- name: Install Buildpack Cli
run: |
(curl -sSL "https://github.com/buildpacks/pack/releases/download/v0.23.0/pack-v0.23.0-linux.tgz" | sudo tar -C /usr/local/bin/ --no-same-owner -xzv pack)
- name: Login to Yandex Container Registry
run: echo -e $YCR_KEYFILE | docker login -u json_key --password-stdin cr.yandex
env:
YCR_KEYFILE: ${{ secrets.YCR_KEYFILE }}

- name: Release
env:
GITHUB_TOKEN: '${{ secrets.GITHUB_TOKEN }}'
run: |
yarn workspaces changed foreach image pack --publish --tag-policy hash-timestamp --registry 'cr.yandex/${{ secrets.YCR_PROJECT_ID }}/shdvor-'
uses: atls/shared/.github/workflows/pack-image.yaml@master
permissions: write-all
with:
registryURL: 'cr.yandex'
registryUser: 'json_key'
project: ${{ secrets.YCR_PROJECT_ID }}
imageNamePrefix: 'shdvor-'
nodeVersion: '19'
secrets:
registryKey: ${{ secrets.YCR_KEYFILE }}

0 comments on commit 7f365bb

Please sign in to comment.