forked from Azure-Samples/graphrag-accelerator
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add basic cicd build pipeline (Azure-Samples#34)
- Loading branch information
1 parent
3624d94
commit 63a0f67
Showing
5 changed files
with
69 additions
and
3 deletions.
There are no files selected for viewing
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
name: Dev Build | ||
on: | ||
workflow_dispatch: # triggered manually via the GitHub UI | ||
pull_request: # triggered when a PR is created or updated | ||
types: | ||
- opened | ||
- reopened | ||
- synchronize | ||
- ready_for_review | ||
paths: # only trigger on changes in specific directories | ||
- '.github/**/*.yaml' | ||
- 'backend/**' | ||
- 'docker/**' | ||
- 'infra/**' | ||
- 'poetry.lock' | ||
- 'pyproject.toml' | ||
jobs: | ||
lint-check: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
- name: Setup python | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: '3.10' | ||
- run: pip install ruff | ||
- run: | | ||
ruff check | ||
build-devcontainer: | ||
needs: [lint-check] | ||
runs-on: ubuntu-latest | ||
if: ${{ !github.event.pull_request.draft }} | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
- name: Build docker image | ||
uses: docker/build-push-action@v2 | ||
with: | ||
context: .devcontainer | ||
push: false | ||
build-backend: | ||
needs: [lint-check] | ||
runs-on: ubuntu-latest | ||
if: ${{ !github.event.pull_request.draft }} | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
- name: Build docker image | ||
uses: docker/build-push-action@v2 | ||
with: | ||
context: . | ||
file: docker/Dockerfile-backend | ||
push: false | ||
build-frontend: | ||
needs: [lint-check] | ||
runs-on: ubuntu-latest | ||
if: ${{ !github.event.pull_request.draft }} | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
- name: Build docker image | ||
uses: docker/build-push-action@v2 | ||
with: | ||
context: . | ||
file: docker/Dockerfile-frontend | ||
push: false |
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,7 +4,6 @@ | |
import asyncio | ||
import inspect | ||
import os | ||
import traceback | ||
from typing import cast | ||
|
||
import yaml | ||
|
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,7 +2,6 @@ | |
# Licensed under the MIT License. | ||
|
||
import os | ||
import traceback | ||
|
||
from fastapi import ( | ||
Depends, | ||
|