You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
That will also contain all the generated files with the generated variables, but it will let you compare the changes in `dev-fsfp` and the source in the project generator with git, and see what to commit.
@@ -51,7 +51,7 @@ After using `./scripts/dev-fsfp-back.sh`, there will be a bunch of generated fil
51
51
To discard all those changes at once, run `discard-dev-files.sh` from the root of the project, e.g.:
52
52
53
53
```console
54
-
$ cd~/code/full-stack-fastapi-postgresql/
54
+
$ cd~/code/full-stack-fastapi-mongodb/
55
55
56
56
$ bash ./scripts/dev-fsfp-back.sh
57
57
```
@@ -63,7 +63,7 @@ Run the tests. It creates a project `testing-project` *inside* of the project ge
Accelerate your next web development project with this FastAPI/Nuxt.js base project generator.
3
+
Accelerate your next web development project with this FastAPI/React/MongoDB base project generator.
6
4
7
5
This project is for developers looking to build and maintain full-feature progressive web applications using Python on the backend / Typescript on the frontend, and want the complex-but-routine aspects of auth 'n auth, and component and deployment configuration, taken care of, including interactive API documentation.
8
6
9
-
This is a comprehensively updated fork of [Sebastián Ramírez's](https://github.com/tiangolo)[Full Stack FastAPI and PostgreSQL Base Project Generator](https://github.com/tiangolo/full-stack-fastapi-postgresql). FastAPI is updated to version 0.99 (July 2023), SQLAlchemy to version 2.0 (July 2023), and the frontend to Nuxt 3.6 (July 2023).
7
+
This is an **experimental** fork of [Sebastián Ramírez's](https://github.com/tiangolo)[Full Stack FastAPI and PostgreSQL Base Project Generator](https://github.com/tiangolo/full-stack-fastapi-postgresql) and [Whythawk's](https://github.com/whythawk)[Full Stack FastAPI and PostgreSQL Base Project Generator](https://github.com/whythawk/full-stack-fastapi-postgresql). FastAPI is updated to version 0.103.2, MongoDB Motor 3.4, Beanie ODM 1.23, and the frontend to React.
8
+
10
9
11
10
-[Screenshots](#screenshots)
12
11
-[Key features](#key-features)
@@ -45,30 +44,23 @@ This is a comprehensively updated fork of [Sebastián Ramírez's](https://github
45
44
46
45
## Key features
47
46
48
-
This FastAPI, PostgreSQL, Neo4j & Nuxt 3 repo will generate a complete web application stack as a foundation for your project development.
47
+
This FastAPI, React, MongoDB repo will generate a complete web application stack as a foundation for your project development.
49
48
50
49
-**Docker Compose** integration and optimization for local development.
51
50
-**Authentication** user management schemas, models, crud and apis already built, with OAuth2 JWT token support & default hashing. Offers _magic link_ authentication, with password fallback, with cookie management, including `access` and `refresh` tokens.
52
51
-[**FastAPI**](https://github.com/tiangolo/fastapi) backend with [Inboard](https://inboard.bws.bio/) one-repo Docker images:
53
-
-**SQLAlchemy** version 2.0 support for models.
54
-
-**MJML** templates for common email transactions.
55
-
-**Metadata Schema** based on [Dublin Core](https://www.dublincore.org/specifications/dublin-core/dcmi-terms/#section-3) for inheritance.
-**MongoDB Beanie** for handling ODM creation https://beanie-odm.dev/
56
54
-**Common CRUD** support via generic inheritance.
57
55
-**Standards-based**: Based on (and fully compatible with) the open standards for APIs: [OpenAPI](https://github.com/OAI/OpenAPI-Specification) and [JSON Schema](http://json-schema.org/).
58
56
-[**Many other features**]("https://fastapi.tiangolo.com/features/"): including automatic validation, serialization, interactive documentation, etc.
-**Authorisation** via middleware for page access, including logged in or superuser.
61
-
-**Model blog** project, with [Nuxt Content](https://content.nuxtjs.org/) for writing Markdown pages.
62
59
-**Form validation** with [Vee-Validate 4](https://vee-validate.logaretm.com/v4/).
63
-
-**State management** with [Pinia](https://pinia.vuejs.org/), and persistance with [Pinia PersistedState](https://prazdevs.github.io/pinia-plugin-persistedstate/).
60
+
-**State management** with [Redux](https://redux.js.org/)
64
61
-**CSS and templates** with [TailwindCSS](https://tailwindcss.com/), [HeroIcons](https://heroicons.com/), and [HeadlessUI](https://headlessui.com/).
65
-
-**Internationalisation** with [@nuxt/i18n](https://nuxt.com/modules/i18n).
66
-
-**PWA support** with [Vite PWA plugin](https://vite-pwa-org.netlify.app/frameworks/nuxt.html).
67
-
-**PostgreSQL** database.
68
-
-**PGAdmin** for PostgreSQL database management.
69
62
-**Celery** worker that can import and use models and code from the rest of the backend selectively.
70
63
-**Flower** for Celery jobs monitoring.
71
-
-**Neo4j** graph database, including integration into the FastAPI base project.
72
64
- Load balancing between frontend and backend with **Traefik**, so you can have both under the same domain, separated by path, but served by different containers.
73
65
- Traefik integration, including Let's Encrypt **HTTPS** certificates automatic generation.
74
66
- GitLab **CI** (continuous integration), including frontend and backend testing.
@@ -85,14 +77,14 @@ This FastAPI, PostgreSQL, Neo4j & Nuxt 3 repo will generate a complete web appli
85
77
86
78
After using this generator, your new project (the directory created) will contain an extensive `README.md` with instructions for development, deployment, etc. You can pre-read [the project `README.md` template here too](./{{cookiecutter.project_slug}}/README.md).
87
79
88
-
This current release (August 2023) is for FastAPI version 0.99 and is the last before introducing support for Pydantic 2. Since this is intended as a base stack on which you will build complex applications, there is no intention of backwards compatability between releases, and the objective is to ensure that each release has the latest long-term-support versions of the core libraries so that you can rely on your application core for as long as possible.
80
+
This current release (October 2023) is for FastAPI version 0.103 and introduces support for Pydantic 2. Since this is intended as a base stack on which you will build complex applications, there is no intention of backwards compatability between releases, and the objective is to ensure that each release has the latest long-term-support versions of the core libraries so that you can rely on your application core for as long as possible.
89
81
90
82
To align with [Inboard](https://inboard.bws.bio/), Poetry has been deprecated in favour of [Hatch](https://hatch.pypa.io/latest/). This will also, hopefully, sort out some Poetry-related Docker build errors.
91
83
92
-
You will also find an initial implementation of internationalisation using [@nuxt/i18n](https://nuxt.com/modules/i18n). This is - at this time - a release candidate, so please do update and check their documentation for any changes. The [Vite PWA plugin](https://vite-pwa-org.netlify.app/frameworks/nuxt.html) is also included, along with a Node CLI for generating all necessary app icons. You will see links and notes to this in the [nuxt.config.ts](./{{cookiecutter.project_slug}}/frontend/nuxt.config.ts) file.
93
-
94
84
## Help needed
95
85
86
+
This stack is in an experimental state, so there is no guarantee for bugs or issues. Please open an issue ticket against this repository to make us aware of issues and we will do our best to respond to them in a timely manner. Please leave feedback on features that would be very beneficial for developers who often leverage mongodb in their FastAPI stack.
87
+
96
88
The tests are broken and it would be great if someone could take that on. Other potential roadmap items:
97
89
98
90
- Translation: docs are all in English and it would be great if those could be in other languages.
@@ -101,43 +93,18 @@ The tests are broken and it would be great if someone could take that on. Other
101
93
102
94
## Release Notes
103
95
104
-
See notes and [releases](https://github.com/whythawk/full-stack-fastapi-postgresql/releases).
105
-
106
-
## 0.8.2
107
-
108
-
Fixing [#39](https://github.com/whythawk/full-stack-fastapi-postgresql/issues/39), thanks to @a-vorobyoff:
109
-
110
-
- Exposing port 24678 for Vite on frontend in development mode.
111
-
- Ensuring Nuxt content on /api/_content doesn't interfere with backend /api/v routes.
112
-
- Checking for password before hashing on user creation.
113
-
- Updating generated README for Hatch (after Poetry deprecation).
114
-
- Minor fixes.
115
-
116
-
### 0.8.1
117
-
118
-
- Minor updates to Docker scripts for `build`.
119
-
120
-
### 0.8.0
96
+
See notes:
121
97
122
-
- Updates to `frontend`, [#37](https://github.com/whythawk/full-stack-fastapi-postgresql/pull/37) by @turukawa:
123
-
-`@nuxtjs/i18n` for internationalisation, along with language selection component.
124
-
-`@vite-pwa/nuxt` along with button components for install and refreshing the app and service workers, and a CLI icon generator.
125
-
-`@nuxtjs/robots` for simple control of `robots.txt` permissions from `nuxt.config.ts`.
98
+
## 0.1.0
126
99
127
-
### 0.7.4
128
-
- Updates: Complete update of stack to latest long-term releases. [#35](https://github.com/whythawk/full-stack-fastapi-postgresql/pull/35) by @turukawa, review by @br3ndonland
129
-
-`frontend`:
130
-
- Node 16 -> 18
131
-
- Nuxt 3.2 -> 3.6.5
132
-
- Latest Pinia requires changes in stores, where imports are not required (cause actual errors), and parameter declaration must happen in functions.
133
-
-`backend` and `celeryworker`:
134
-
- Python 3.9 -> 3.11
135
-
- FastAPI 0.88 -> 0.99 (Inboard 0.37 -> 0.51)
136
-
- Poetry -> Hatch
137
-
- Postgres 14 -> 15
138
-
- Fixed: Updated token url in deps.py [#29](https://github.com/whythawk/full-stack-fastapi-postgresql/pull/29) by @vusa
139
-
- Docs: Reorganised documentation [#21](https://github.com/whythawk/full-stack-fastapi-postgresql/pull/21) by @turukawa
100
+
- Replaced Next/Vue.js frontend framework with entirely React/Redux
101
+
- Replaced Backend native connection of PostgreSQL/SQLAlchemy with MongoDB Motor/Beanie ODM
102
+
- Removed Neo4j plugin
103
+
- Removed Alembic Usage
104
+
- Introduced new cookiecutter environment variables `mongo_host`, `mongo_user`, `mongo_password`, and `mongo_database`
105
+
- Introduced support for Pydantic 2
140
106
107
+
[Historic changes from whythawk](https://github.com/whythawk/full-stack-fastapi-postgresql/releases)
141
108
[Historic changes from original](https://github.com/tiangolo/full-stack-fastapi-postgresql#release-notes)
Copy file name to clipboardExpand all lines: docs/deployment-guide.md
+2-6Lines changed: 2 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -42,8 +42,6 @@ These files will also need to be customised for production deployment. Make alte
42
42
43
43
This guide uses [DigitalOcean Droplets](https://www.digitalocean.com/pricing/droplets), so customise as required. Deploy to the smallest (currently 500MiB memory, 1 vCPU and 10GiB SSD for $4/month). You can upgrade later when you know your resource requirements.
44
44
45
-
> **WARNING**: if you're using `neo4j` then the `java` server alone will need 1Gb of memory, and you may need a 2Gb to 4Gb base droplet. Plan accordingly. If you decide not to use it, you will need to carefully remove it. That will require editing `docker-compose.yml` and the start-up sequence in the backend. Shouldn't be too challenging.
46
-
47
45
Ensure you add your SSH encryption keys on launch so that your server can be secure from the beginning.
48
46
49
47
Deploy on whatever server image your prefer, although the default would be Ubuntu 20.04 (22.04 is the latest). End-of-life for 20.04 is April 2030, and for 22.04 is April 2032. You have time. The underlying image isn't that critical, as you'll be using the Docker images at their current versions.
@@ -56,7 +54,7 @@ For reference:
56
54
-[Link Namecheap domain to DigitalOcean](https://www.namecheap.com/support/knowledgebase/article.aspx/10375/2208/how-do-i-link-a-domain-to-my-digitalocean-account/)
57
55
-[Manage DNS records at DigitalOcean](https://docs.digitalocean.com/products/networking/dns/how-to/manage-records/)
58
56
59
-
Don't forget to create DNS A records for `flower`, `neo4j`, `traefik`, and `pgadmin`.
57
+
Don't forget to create DNS A records for `flower`, `traefik`.
60
58
61
59
Now you should be able to login to your server and begin deployment.
62
60
@@ -318,7 +316,5 @@ These are the URLs served in production (replace `example.com` with your own):
Copy file name to clipboardExpand all lines: docs/development-guide.md
+4-4Lines changed: 4 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -61,10 +61,10 @@ The input variables, with their default values (some auto generated) are:
61
61
-`smtp_emails_from_email`: The email account to use as the sender in the notification emails, it could be something like `[email protected]`.
62
62
-`smtp_emails_from_name`: The email account name to use as the sender in the notification emails, it could be something like `Symona Adaro`.
63
63
-`smtp_emails_to_email`: The email account to use as the recipient for `contact us` emails, it could be something like `[email protected]`.
64
-
-`postgres_password`: Postgres database password. Use the method above to generate it. (You could easily modify it to use MySQL, MariaDB, etc).
65
-
-`pgadmin_default_user`: PGAdmin default user, to log-in to the PGAdmin interface.
66
-
-`pgadmin_default_user_password`: PGAdmin default user password. Generate it with the method above.
67
-
-`neo4j_password`: Neo4j database password. Use the method above to generate it.
64
+
-`mongo_host`: MongoDB host cluster URI password
65
+
-`mongo_user`: MongoDB User account to access the cluster
66
+
-`mongodb_password`: MongoDB password for access to the cluster
67
+
-`mongodb_database`: MongoDB database to have the application operate within
68
68
-`traefik_constraint_tag`: The tag to be used by the internal Traefik load balancer (for example, to divide requests between backend and frontend) for production. Used to separate this stack from any other stack you might have. This should identify each stack in each environment (production, staging, etc).
69
69
-`traefik_constraint_tag_staging`: The Traefik tag to be used while on staging.
70
70
-`traefik_public_constraint_tag`: The tag that should be used by stack services that should communicate with the public.
0 commit comments