📝 Add docs about removing the frontend (#156)
This commit is contained in:

committed by
GitHub

parent
3678eb9d57
commit
7d57876bda
@@ -8,17 +8,14 @@ Generate a backend and frontend stack using Python, including interactive API do
|
|||||||
|
|
||||||
[](https://github.com/tiangolo/full-stack-fastapi-postgresql)
|
[](https://github.com/tiangolo/full-stack-fastapi-postgresql)
|
||||||
|
|
||||||
|
|
||||||
### Alternative API documentation
|
### Alternative API documentation
|
||||||
|
|
||||||
[](https://github.com/tiangolo/full-stack-fastapi-postgresql)
|
[](https://github.com/tiangolo/full-stack-fastapi-postgresql)
|
||||||
|
|
||||||
|
|
||||||
### Dashboard Login
|
### Dashboard Login
|
||||||
|
|
||||||
[](https://github.com/tiangolo/full-stack-fastapi-postgresql)
|
[](https://github.com/tiangolo/full-stack-fastapi-postgresql)
|
||||||
|
|
||||||
|
|
||||||
### Dashboard - Create User
|
### Dashboard - Create User
|
||||||
|
|
||||||
[](https://github.com/tiangolo/full-stack-fastapi-postgresql)
|
[](https://github.com/tiangolo/full-stack-fastapi-postgresql)
|
||||||
@@ -61,6 +58,7 @@ Generate a backend and frontend stack using Python, including interactive API do
|
|||||||
* Docker multi-stage building, so you don't need to save or commit compiled code.
|
* Docker multi-stage building, so you don't need to save or commit compiled code.
|
||||||
* Frontend tests ran at build time (can be disabled too).
|
* Frontend tests ran at build time (can be disabled too).
|
||||||
* Made as modular as possible, so it works out of the box, but you can re-generate with Vue CLI or create it as you need, and re-use what you want.
|
* Made as modular as possible, so it works out of the box, but you can re-generate with Vue CLI or create it as you need, and re-use what you want.
|
||||||
|
* It's also easy to remove it if you have an API-only app, check the instructions in the generated `README.md`.
|
||||||
* **PGAdmin** for PostgreSQL database, you can modify it to use PHPMyAdmin and MySQL easily.
|
* **PGAdmin** for PostgreSQL database, you can modify it to use PHPMyAdmin and MySQL easily.
|
||||||
* **Flower** for Celery jobs monitoring.
|
* **Flower** for Celery jobs monitoring.
|
||||||
* 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.
|
* 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.
|
||||||
|
@@ -394,6 +394,26 @@ VUE_APP_ENV=development
|
|||||||
VUE_APP_ENV=staging
|
VUE_APP_ENV=staging
|
||||||
```
|
```
|
||||||
|
|
||||||
|
### Removing the frontend
|
||||||
|
|
||||||
|
If you are developing an API-only app and want to remove the frontend, you can do it easily:
|
||||||
|
|
||||||
|
* Remove the `./frontend` directory.
|
||||||
|
* In the `docker-compose.yml` file, remove the whole service / section `frontend`.
|
||||||
|
* In the `docker-compose.override.yml` file, remove the whole service / section `frontend`.
|
||||||
|
|
||||||
|
Done, you have a frontend-less (api-only) app. 🔥 🚀
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
If you want, you can also remove the `FRONTEND` environment variables from:
|
||||||
|
|
||||||
|
* `.env`
|
||||||
|
* `.gitlab-ci.yml`
|
||||||
|
* `./scripts/*.sh`
|
||||||
|
|
||||||
|
But it would be only to clean them up, leaving them won't really have any effect either way.
|
||||||
|
|
||||||
## Deployment
|
## Deployment
|
||||||
|
|
||||||
You can deploy the stack to a Docker Swarm mode cluster with a main Traefik proxy, set up using the ideas from <a href="https://dockerswarm.rocks" target="_blank">DockerSwarm.rocks</a>, to get automatic HTTPS certificates, etc.
|
You can deploy the stack to a Docker Swarm mode cluster with a main Traefik proxy, set up using the ideas from <a href="https://dockerswarm.rocks" target="_blank">DockerSwarm.rocks</a>, to get automatic HTTPS certificates, etc.
|
||||||
|
Reference in New Issue
Block a user