fix(ci): use plain docker build/push instead of buildx #6
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| jobs: | |
| lint-test-build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: pnpm/action-setup@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| cache: pnpm | |
| - run: pnpm install --frozen-lockfile | |
| - name: Lint | |
| run: pnpm lint | |
| - name: Stylelint | |
| run: pnpm lint:css | |
| - name: Typecheck | |
| run: pnpm typecheck | |
| - name: Test | |
| run: pnpm test | |
| - name: Build | |
| run: pnpm build | |
| docker: | |
| needs: lint-test-build | |
| if: github.ref == 'refs/heads/main' | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Login to YC Container Registry | |
| run: echo '${{ secrets.YC_SA_KEY_JSON }}' | docker login cr.yandex -u json_key --password-stdin | |
| - name: Build | |
| run: docker build -t cr.yandex/crpml6ifd12s8cbmbg3m/atlas:latest -t cr.yandex/crpml6ifd12s8cbmbg3m/atlas:${{ github.sha }} . | |
| - name: Push | |
| run: | | |
| docker push cr.yandex/crpml6ifd12s8cbmbg3m/atlas:latest | |
| docker push cr.yandex/crpml6ifd12s8cbmbg3m/atlas:${{ github.sha }} |