Projet

Général

Profil

0001-agent-notify-primary-agent-when-hobo-registers-secon.patch

Frédéric Péters, 19 juillet 2019 21:38

Télécharger (1,42 ko)

Voir les différences:

Subject: [PATCH] agent: notify primary agent when hobo registers secondary
 services (#34970)

 hobo/agent/hobo/management/commands/hobo_deploy.py | 6 ++++++
 1 file changed, 6 insertions(+)
hobo/agent/hobo/management/commands/hobo_deploy.py
4 4
from tenant_schemas.utils import tenant_context
5 5

  
6 6
from hobo.agent.common.management.commands import hobo_deploy
7
from hobo.deploy.signals import notify_agents
7 8
from hobo.environment.models import AVAILABLE_SERVICES, Hobo, Variable
8 9
from hobo.multitenant.middleware import TenantMiddleware, TenantNotFound
9 10

  
......
95 96
                            name='ou-slug', auto=True, service_pk=None)
96 97
                    variable.value = me['slug']
97 98
                    variable.save()
99

  
100
            if me.get('secondary'):
101
                # on the primary hobo, notify other primary services, this will
102
                # get authentic to know about secondary services
103
                notify_agents(None)
98
-