diff --git a/backend/api/__pycache__/routes.cpython-310.pyc b/backend/api/__pycache__/routes.cpython-310.pyc new file mode 100644 index 0000000..cd7e954 Binary files /dev/null and b/backend/api/__pycache__/routes.cpython-310.pyc differ diff --git a/backend/api/routes.py b/backend/api/routes.py new file mode 100644 index 0000000..f52258d --- /dev/null +++ b/backend/api/routes.py @@ -0,0 +1,8 @@ +from fastapi import FastAPI + +app = FastAPI() + +@app.get("/prueba") +def ruta_de_prueba(): + # En FastAPI si devuelves un diccionario, se transforma a JSON + return {"mensaje": "¡Hola desde FastAPI! El contenedor de docker está funcionando"} \ No newline at end of file diff --git a/docker-compose.yaml b/docker-compose.yaml index 2dc0c35..6d49e5b 100644 --- a/docker-compose.yaml +++ b/docker-compose.yaml @@ -1,5 +1,3 @@ -version: '3.8' - services: backend: build: