Skip to content

Commit

Permalink
refactor: simpify CI
Browse files Browse the repository at this point in the history
  • Loading branch information
ninoseki committed Mar 17, 2024
1 parent 2b51d2d commit 865e3bd
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
4 changes: 1 addition & 3 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,7 @@ jobs:
- name: Install dependencies
run: poetry install
- name: Run tests
run: |
mkdir -p frontend/dist/assets
poetry run pytest --cov=app
run: poetry run pytest --cov=app
- name: Coveralls
env:
COVERALLS_PARALLEL: true
Expand Down
9 changes: 7 additions & 2 deletions backend/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,13 @@ def create_app():

# add routes
app.include_router(api_router, prefix="/api")
app.mount("/assets", StaticFiles(directory="frontend/dist/assets"), name="assets")
app.mount("/", StaticFiles(html=True, directory="frontend/dist/"), name="index")
try:
app.mount(
"/assets", StaticFiles(directory="frontend/dist/assets"), name="assets"
)
app.mount("/", StaticFiles(html=True, directory="frontend/dist/"), name="index")
except Exception:
pass

return app

Expand Down

0 comments on commit 865e3bd

Please sign in to comment.