5

I am running flower inside docker,but when I am trying to access it from browser , it's waiting for the response.

Command used to run flower docker-compose

celery flower -A nrn --address=0.0.0.0 --port=5555 --url-prefix=flower ,port is mapped to 5555.

docker ps -a docker ps -a output When the docker-compose runs and if I immediately open flower, the dashboard comes but it won't respond.Moreover, if I try to open flower it won't display the dashboard as well. enter image description here

nginx.conf

worker_processes  1;
events {
  worker_connections  1024;
}
http {
    upstream rapid_nrn {
    ip_hash;
    server web:6500;
}
upstream rapid_nrn_dj {
    ip_hash;
    server django:8000;
}
upstream rapid_nrn_flower {
    ip_hash;
    server flower:5555;
}
server {
    listen 80;
    location ~^/flower/? {
        proxy_pass http://localhost:5555;
        rewrite ^/flower/?(.*)$ /$1 break;

        sub_filter '="/' '="/flower/';
        sub_filter_last_modified on;
        sub_filter_once off;


        proxy_set_header Host $host;
        proxy_redirect off;
        proxy_http_version 1.1;
        proxy_set_header Upgrade $http_upgrade;
        proxy_set_header Connection "upgrade";
    }
}
}

logs of flower conatainer

[I 200115 07:33:12 command:136] Visit me at http://0.0.0.0:5555
[I 200115 07:33:12 command:141] Broker: redis://127.0.0.1:6379//
[I 200115 07:33:12 command:144] Registered tasks: 
    ['celery.accumulate',
     'celery.backend_cleanup',
     'celery.chain',
     'celery.chord',
     'celery.chord_unlock',
     'celery.chunks',
     'celery.group',
     'celery.map',
     'celery.starmap',
     'nrn.celery.debug_task',
     'send.tasks.send_mails']

*redis docker-compose**

redismb:
    image: redis:2.8.19
    hostname: redis
    ports:
      - "6379:6379"
    networks:
      - nra

redis configuration in django's settings.py

CELERY_BROKER_URL = os.environ.get('redis', 'redis://127.0.0.1:6379/')

celery logs

enter image description here Any help is highly appreciated.

Pragyan
  • 567
  • 1
  • 5
  • 18
  • 1
    You should analyse the log from Flower and see whether it can communicate with the broker. Since I do not see any workers, I would assume that it can't... – DejanLekic Jan 15 '20 at 13:21
  • @DejanLekic have attached the logs as well as broker configuration – Pragyan Jan 15 '20 at 14:02
  • I tried by running flower with --broker option as well – Pragyan Jan 15 '20 at 14:23
  • 1
    celery flower -A nrn --address=0.0.0.0 --port=5555 --url-prefix=flower --broker=redis://redis – Pragyan Jan 15 '20 at 14:23
  • 1
    the log changed to " [I 200115 14:20:30 command:136] Visit me at http://0.0.0.0:5555 [I 200115 14:20:30 command:141] Broker: redis://redis:6379// [I 200115 14:20:30 command:144] Registered tasks: "but still not accessible from browser – Pragyan Jan 15 '20 at 14:24

0 Answers0