All Questions
158 questions
0
votes
0
answers
42
views
Docker Flask Service: ModuleNotFoundError: No module named 'flask' When Running Container, but Works Manually
I am trying to build and run a Flask-based Python service (task_manager) using Docker and Docker Compose, but I'm encountering a persistent issue. When I run the container via docker-compose up --...
0
votes
1
answer
33
views
Flask Nginx docker web page not responding - windows
Everything runs fine, the flask port 5000 works, but Nginx port web page not responding.
Please help and thank you.
Here are my code, docker file, nginx.conf, .py:
[[[[[enter image description here](...
2
votes
0
answers
34
views
Connection is reestablished when I dockerize a FlaskApp and access by my localhost
I created a Python flask app. Everything works well, so I decided to Dockerize it.
But when I launch my app with docker and try to access to http://localhost:5000/ I get:
The connection has been ...
-2
votes
1
answer
101
views
How to share python packages installed in my Docker base image with another Docker image from Jupyter?
When I execute docker compose up -d I want to be able to run my Flask app on localhost 5123 and a Jupyter server on localhost 8123 in the web browser. I want to use the Jupyter server to test some ...
0
votes
1
answer
147
views
Flask debug not hot reloading in docker container
I am attempting to run a Flask server in a docker container with debug enabled so that I can hot reload during development and try out changes. Unfortunately the hot reload is not detecting changes ...
1
vote
0
answers
162
views
Flask unable to connect to Redis & Celery with Docker-Compose
I am able to run celery shared tasks in the flask (called web) container's flask shell without issue (docker-compose exec web flask shell), however they time out when running in a route. Suspecting ...
1
vote
1
answer
61
views
API Flask and Docker compose issue
I'm having a little issue understanding how to access an endpoint from an api i'm hosting because this is my first time using docker compose. The isue is (i think) i'm setting the PORT 5000 for the ...
0
votes
0
answers
59
views
Flask: cannot curl it from docker container
Have 2 applications:
Inside docker container
Python Flask as http://localhost:5000. 1st application should call
Python Flask.
Yes, I know that localhost unreachable from docker container. To get ...
1
vote
1
answer
93
views
Flask App with Docker Compose Fails to Connect to MongoDB: ServerSelectionTimeoutError
I'm developing a Flask application that uses MongoDB for storage, and I'm trying to dockerize the setup using Docker Compose. However, I'm encountering a ServerSelectionTimeoutError when the Flask app ...
-2
votes
1
answer
38
views
Unable to connect to postgres instance when flask app Dockerfile in different directory
I have a project structure like this
project-root/
back/
Dockerfile
docker-compose.yaml
.env
Where docker-compose.yaml has
services:
postgres:
image: postgres:latest
...
2
votes
1
answer
106
views
Unable to connect to mysql container Unable to create tables due to 2003 (HY000): Can't connect to MySQL server on 'mysql:3307'
I am trying to connect mysql container with my python flask app and I have this error when running docker-compose build --no-cache && docker-compose up:
Creating network "...
0
votes
1
answer
334
views
docker container (flask + mariadb) works and then crashes with error "2003: Can't connect to MySQL server on 'db:3306' (111 Connection refused)"
I am quite surprised with my docker container behavior. I have a flask app with a mariadb database. It has no issue outside the container, on my local machine. More puzzling, sometimes the docker ...
-1
votes
1
answer
98
views
Circular import Python flask (docker-compose)
Im getting this error in my flask container while starts with docker-compose up:
web_1 | Traceback (most recent call last):
web_1 | File "/app/app.py", line 3, in <...
2
votes
1
answer
282
views
kombu.exceptions.OperationalError: [Errno 111] Connection refused (flask, docker-compose)
i'm having problems with my flask app
having the premises:
Python, Flask, Celerey, MongoDB, RabbitMQ.
When I make a request to the API, I get the following return:
kombu.exceptions.OperationalError: [...
1
vote
1
answer
50
views
Error creating a Python Flask project with Docker
I'm trying to create a project in a Container on Docker with Dockerfile and Compose but i'm getting an error when i'm trying to docker-compose up
Here is my files:
Dockerfile
FROM python:3.8-slim
...