Update README.md #10
This file contains 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: Build and Push Docker Images | |
on: | |
push: | |
branches: | |
- master | |
env: | |
NAME: "requests" | |
REGISTRY: ghcr.io | |
jobs: | |
build-and-push: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: read | |
packages: write | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
- name: Set up Docker Buildx | |
uses: docker/setup-buildx-action@v3 | |
- name: Build frondend | |
uses: oven-sh/setup-bun@v2 | |
with: | |
bun-version: latest | |
- name: Install dependencies | |
run: | | |
cd main/frontend | |
bun install --frozen-lockfile | |
cd - | |
- name: Build frontend | |
run: | | |
cd main/frontend | |
bun run build | |
cd - | |
- name: Log in to the Container registry | |
uses: docker/login-action@v2 | |
with: | |
registry: ${{ env.REGISTRY }} | |
username: ${{ github.actor }} | |
password: ${{ secrets.CR_PAT }} | |
- name: Build and push Docker image | |
uses: docker/build-push-action@v4 | |
with: | |
context: hook/ | |
tags: ${{ env.REGISTRY }}/${{ github.actor }}/requests-hook:latest | |
push: true | |
- name: Build and push Docker image | |
uses: docker/build-push-action@v4 | |
with: | |
context: main/ | |
tags: ${{ env.REGISTRY }}/${{ github.actor }}/requests-main:latest | |
push: true |