Skip to content

Commit

Permalink
task(mkdocs): deploy mkdocs
Browse files Browse the repository at this point in the history
  • Loading branch information
svaponi committed May 5, 2024
1 parent 1642636 commit 4393101
Show file tree
Hide file tree
Showing 7 changed files with 94 additions and 40 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/mkdocs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Builds the docs using mkdocs and pushes the result to `gh-pages` branch.
name: Docs
run-name: Build Docs 📄
on:
push:
branches:
- main
permissions:
contents: write
jobs:
deploy:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [ "3.12" ]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
cache: 'pip'
- name: Install Requirements
run: |
sudo apt-get update &&
sudo apt-get install pngquant &&
pip install mkdocs-material mkdocs-material-extensions pillow cairosvg
- name: Build and deploy MkDocs
run: mkdocs gh-deploy --force
40 changes: 0 additions & 40 deletions docs/SETUP.mdx

This file was deleted.

29 changes: 29 additions & 0 deletions docs/gcloud.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# Google Cloud Integration

This page contains information on how to configure the application to use resources on Google Cloud.
Use-cases:

- Install private dependencies published on [Artifact Registry](https://cloud.google.com/artifact-registry).
- Publish docker image on [Artifact Registry](https://cloud.google.com/artifact-registry).
- Deploy to [Google Kubernetes Engine (GKE)](https://cloud.google.com/kubernetes-engine).
- Deploy to [Cloud Run](https://cloud.google.com/run).

## Install Google Cloud CLI

- Install it from the [GCloud Installation](https://cloud.google.com/sdk/docs/install) page.
- Run in terminal:

```shell
gcloud init
```

- You will be asked to sign via Google Sign On.
- Choose your project from the menu.

## Add Google Cloud implementation of keyring to Poetry

1. Run in terminal:

```sh
poetry self add keyrings.google-artifactregistry-auth
```
3 changes: 3 additions & 0 deletions docs/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# FastAPI Boilerplate

Kickstart your [FastAPI](https://fastapi.tiangolo.com/) development with ease.
22 changes: 22 additions & 0 deletions docs/setup.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Setup

This page contain information on how to set up the project locally.

## Install Poetry

- Install it from the [Poetry Installation](https://python-poetry.org/docs/#installation) page.
- Check the installation by running:

```shell
poetry --version
```

- Make sure your version is **>=1.2.2**.

### Install Dependencies via Poetry

- Run in terminal:

```sh
poetry install
```
8 changes: 8 additions & 0 deletions mkdocs.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
site_name: FastAPI Boilerplate
site_url: https://svaponi.github.io/fastapi-boilerplate
nav:
- Home: index.md
- Setup: setup.md
- Cloud Integration:
- Google Cloud: gcloud.md
theme: readthedocs
2 changes: 2 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ description = ""
authors = ["svaponi <10941963+svaponi@users.noreply.github.com>"]
license = "MIT"
readme = "README.md"
repository = "https://github.com/svaponi/fastapi-boilerplate"
homepage = "https://svaponi.github.io/fastapi-boilerplate"

[tool.poetry.dependencies]
python = "^3.12"
Expand Down

0 comments on commit 4393101

Please sign in to comment.