Skip to content

Commit

Permalink
PAN-2270: Set proper path based on broker url
Browse files Browse the repository at this point in the history
  • Loading branch information
jacekv committed Nov 19, 2024
1 parent 10acd4f commit 2e92036
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion pantos/servicenode/celery.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,13 +42,16 @@ def is_main_module() -> bool:
_logger.info('Initializing the Celery application...')
initialize_application(False)

ca_certs = {} if config['celery']['broker'].startswith('amqp') else {
'ca_certs': certifi.where()
}
celery_app = celery.Celery(
'pantos.servicenode', broker=config['celery']['broker'],
backend=config['celery']['backend'], include=[
'pantos.common.blockchains.tasks',
'pantos.servicenode.business.transfers',
'pantos.servicenode.business.plugins'
], broker_use_ssl={'ca_certs': certifi.where()})
], broker_use_ssl=ca_certs)
"""Celery application instance."""

# Additional Celery configuration
Expand Down

0 comments on commit 2e92036

Please sign in to comment.