Skip to content

Instantly share code, notes, and snippets.

View grilo13's full-sized avatar

Pedro Grilo grilo13

View GitHub Profile
@liviaerxin
liviaerxin / README.md
Last active July 2, 2024 19:24
FastAPI and Uvicorn Logging #python #fastapi #uvicorn #logging

FastAPI and Uvicorn Logging

When running FastAPI app, all the logs in console are from Uvicorn and they do not have timestamp and other useful information. As Uvicorn applies python logging module, we can override Uvicorn logging formatter by applying a new logging configuration.

Meanwhile, it's able to unify the your endpoints logging with the Uvicorn logging by configuring all of them in the config file log_conf.yaml.

Before overriding:

uvicorn main:app --reload
@chrisedrego
chrisedrego / redisinsight-manifest.yaml
Created January 22, 2021 19:58
RedisInsight Manifest for kubernetes deployment & services
apiVersion: apps/v1
kind: Deployment
metadata:
name: redisinsight
labels:
app: redisinsight
spec:
replicas: 1
selector:
matchLabels: