Skip to content

Commit f15e208

Browse files
authored
Merge branch 'master' into master
2 parents 2bc34be + cdf9a65 commit f15e208

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

51 files changed

+1092
-353
lines changed

.env

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ BACKEND_CORS_ORIGINS="http://localhost,http://localhost:5173,https://localhost,h
1313
SECRET_KEY=changethis
1414
FIRST_SUPERUSER=[email protected]
1515
FIRST_SUPERUSER_PASSWORD=changethis
16-
USERS_OPEN_REGISTRATION=True
1716

1817
# Emails
1918
SMTP_HOST=

.github/ISSUE_TEMPLATE/config.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ contact_links:
44
about: Please report security vulnerabilities to [email protected]
55
- name: Question or Problem
66
about: Ask a question or ask about a problem in GitHub Discussions.
7-
url: https://github.com/tiangolo/full-stack-fastapi-template/discussions/categories/questions
7+
url: https://github.com/fastapi/full-stack-fastapi-template/discussions/categories/questions
88
- name: Feature Request
99
about: To suggest an idea or ask about a feature, please start with a question saying what you would like to achieve. There might be a way to do it already.
10-
url: https://github.com/tiangolo/full-stack-fastapi-template/discussions/categories/questions
10+
url: https://github.com/fastapi/full-stack-fastapi-template/discussions/categories/questions

.github/labeler.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
docs:
2+
- changed-files:
3+
- any-glob-to-any-file:
4+
- '**/*.md'
5+
6+
internal:
7+
- changed-files:
8+
- any-glob-to-any-file:
9+
- .github/**/*
10+
- scripts/**/*
11+
- .gitignore
12+
- .pre-commit-config.yaml
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
name: Add to Project
2+
3+
on:
4+
pull_request_target:
5+
issues:
6+
types:
7+
- opened
8+
- reopened
9+
10+
jobs:
11+
add-to-project:
12+
name: Add to project
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/[email protected]
16+
with:
17+
project-url: https://github.com/orgs/fastapi/projects/2
18+
github-token: ${{ secrets.PROJECTS_TOKEN }}

.github/workflows/deploy-production.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ on:
77

88
jobs:
99
deploy:
10+
# Do not deploy in the main repository, only in user projects
11+
if: github.repository_owner != 'fastapi'
1012
runs-on:
1113
- self-hosted
1214
- production

.github/workflows/deploy-staging.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ on:
77

88
jobs:
99
deploy:
10+
# Do not deploy in the main repository, only in user projects
11+
if: github.repository_owner != 'fastapi'
1012
runs-on:
1113
- self-hosted
1214
- staging

.github/workflows/issue-manager.yml

Lines changed: 18 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,27 +2,41 @@ name: Issue Manager
22

33
on:
44
schedule:
5-
- cron: "0 0 * * *"
5+
- cron: "13 4 * * *"
66
issue_comment:
77
types:
88
- created
9-
- edited
109
issues:
1110
types:
1211
- labeled
12+
pull_request_target:
13+
types:
14+
- labeled
15+
workflow_dispatch:
16+
17+
permissions:
18+
issues: write
1319

1420
jobs:
1521
issue-manager:
22+
if: github.repository_owner == 'fastapi'
1623
runs-on: ubuntu-latest
1724
steps:
25+
- name: Dump GitHub context
26+
env:
27+
GITHUB_CONTEXT: ${{ toJson(github) }}
28+
run: echo "$GITHUB_CONTEXT"
1829
- uses: tiangolo/[email protected]
1930
with:
2031
token: ${{ secrets.GITHUB_TOKEN }}
2132
config: >
2233
{
2334
"answered": {
24-
"users": ["tiangolo"],
2535
"delay": 864000,
26-
"message": "Assuming the original issue was solved, it will be automatically closed now. But feel free to add more comments or create new issues."
36+
"message": "Assuming the original need was handled, this will be automatically closed now. But feel free to add more comments or create new issues or PRs."
37+
},
38+
"changes-requested": {
39+
"delay": 2628000,
40+
"message": "As this PR had requested changes to be applied but has been inactive for a while, it's now going to be closed. But if there's anyone interested, feel free to create a new PR."
2741
}
2842
}

.github/workflows/labeler.yml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: Pull Request Labeler and Checker
2+
on:
3+
pull_request_target:
4+
types:
5+
- opened
6+
- synchronize
7+
- reopened
8+
# For label-checker
9+
- labeled
10+
- unlabeled
11+
12+
jobs:
13+
labeler:
14+
permissions:
15+
contents: read
16+
pull-requests: write
17+
runs-on: ubuntu-latest
18+
steps:
19+
- uses: actions/labeler@v5
20+
# Run this after labeler applied labels
21+
check-labels:
22+
name: Check labels
23+
runs-on: ubuntu-latest
24+
steps:
25+
- uses: docker://agilepathway/pull-request-label-checker:latest
26+
with:
27+
one_of: breaking,security,feature,bug,refactor,upgrade,docs,lang-all,internal
28+
repo_token: ${{ secrets.GITHUB_TOKEN }}

README.md

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Full Stack FastAPI Template
22

3-
<a href="https://github.com/tiangolo/full-stack-fastapi-template/actions?query=workflow%3ATest" target="_blank"><img src="https://github.com/tiangolo/full-stack-fastapi-template/workflows/Test/badge.svg" alt="Test"></a>
4-
<a href="https://coverage-badge.samuelcolvin.workers.dev/redirect/tiangolo/full-stack-fastapi-template" target="_blank"><img src="https://coverage-badge.samuelcolvin.workers.dev/tiangolo/full-stack-fastapi-template.svg" alt="Coverage"></a>
3+
<a href="https://github.com/fastapi/full-stack-fastapi-template/actions?query=workflow%3ATest" target="_blank"><img src="https://github.com/fastapi/full-stack-fastapi-template/workflows/Test/badge.svg" alt="Test"></a>
4+
<a href="https://coverage-badge.samuelcolvin.workers.dev/redirect/fastapi/full-stack-fastapi-template" target="_blank"><img src="https://coverage-badge.samuelcolvin.workers.dev/fastapi/full-stack-fastapi-template.svg" alt="Coverage"></a>
55

66
## Technology Stack and Features
77

@@ -13,6 +13,7 @@
1313
- 💃 Using TypeScript, hooks, Vite, and other parts of a modern frontend stack.
1414
- 🎨 [Chakra UI](https://chakra-ui.com) for the frontend components.
1515
- 🤖 An automatically generated frontend client.
16+
- 🧪 [Playwright](https://playwright.dev) for End-to-End testing.
1617
- 🦇 Dark mode support.
1718
- 🐋 [Docker Compose](https://www.docker.com) for development and production.
1819
- 🔒 Secure password hashing by default.
@@ -25,31 +26,31 @@
2526

2627
### Dashboard Login
2728

28-
[![API docs](img/login.png)](https://github.com/tiangolo/full-stack-fastapi-template)
29+
[![API docs](img/login.png)](https://github.com/fastapi/full-stack-fastapi-template)
2930

3031
### Dashboard - Admin
3132

32-
[![API docs](img/dashboard.png)](https://github.com/tiangolo/full-stack-fastapi-template)
33+
[![API docs](img/dashboard.png)](https://github.com/fastapi/full-stack-fastapi-template)
3334

3435
### Dashboard - Create User
3536

36-
[![API docs](img/dashboard-create.png)](https://github.com/tiangolo/full-stack-fastapi-template)
37+
[![API docs](img/dashboard-create.png)](https://github.com/fastapi/full-stack-fastapi-template)
3738

3839
### Dashboard - Items
3940

40-
[![API docs](img/dashboard-items.png)](https://github.com/tiangolo/full-stack-fastapi-template)
41+
[![API docs](img/dashboard-items.png)](https://github.com/fastapi/full-stack-fastapi-template)
4142

4243
### Dashboard - User Settings
4344

44-
[![API docs](img/dashboard-user-settings.png)](https://github.com/tiangolo/full-stack-fastapi-template)
45+
[![API docs](img/dashboard-user-settings.png)](https://github.com/fastapi/full-stack-fastapi-template)
4546

4647
### Dashboard - Dark Mode
4748

48-
[![API docs](img/dashboard-dark.png)](https://github.com/tiangolo/full-stack-fastapi-template)
49+
[![API docs](img/dashboard-dark.png)](https://github.com/fastapi/full-stack-fastapi-template)
4950

5051
### Interactive API Documentation
5152

52-
[![API docs](img/docs.png)](https://github.com/tiangolo/full-stack-fastapi-template)
53+
[![API docs](img/docs.png)](https://github.com/fastapi/full-stack-fastapi-template)
5354

5455
## How To Use It
5556

@@ -132,16 +133,16 @@ Decide a name for your new project's directory, you will use it below. For examp
132133
Go to the directory that will be the parent of your project, and run the command with your project's name:
133134

134135
```bash
135-
copier copy https://github.com/tiangolo/full-stack-fastapi-template my-awesome-project --trust
136+
copier copy https://github.com/fastapi/full-stack-fastapi-template my-awesome-project --trust
136137
```
137138

138139
If you have `pipx` and you didn't install `copier`, you can run it directly:
139140

140141
```bash
141-
pipx run copier copy https://github.com/tiangolo/full-stack-fastapi-template my-awesome-project --trust
142+
pipx run copier copy https://github.com/fastapi/full-stack-fastapi-template my-awesome-project --trust
142143
```
143144

144-
**Note** the `--trust` option is necessary to be able to execute a [post-creation script](https://github.com/tiangolo/full-stack-fastapi-template/blob/master/.copier/update_dotenv.py) that updates your `.env` files.
145+
**Note** the `--trust` option is necessary to be able to execute a [post-creation script](https://github.com/fastapi/full-stack-fastapi-template/blob/master/.copier/update_dotenv.py) that updates your `.env` files.
145146

146147
### Input Variables
147148

backend/README.md

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -63,16 +63,6 @@ Make sure your editor is using the correct Python virtual environment.
6363

6464
Modify or add SQLModel models for data and SQL tables in `./backend/app/models.py`, API endpoints in `./backend/app/api/`, CRUD (Create, Read, Update, Delete) utils in `./backend/app/crud.py`.
6565

66-
### Enabling Open User Registration
67-
68-
By default the backend has user registration disabled, but there's already a route to register users. If you want to allow users to register themselves, you can set the environment variable `USERS_OPEN_REGISTRATION` to `True` in the `.env` file.
69-
70-
After modifying the environment variables, restart the Docker containers to apply the changes. You can do this by running:
71-
72-
```console
73-
$ docker compose up -d
74-
```
75-
7666
### VS Code
7767

7868
There are already configurations in place to run the backend through the VS Code debugger, so that you can use breakpoints, pause and explore variables, etc.

0 commit comments

Comments
 (0)