Exemplo n.º 1
0
def test_get_marathon_client_from_config():
    with mock.patch('paasta_tools.deployd.common.load_marathon_config',
                    autospec=True), mock.patch(
                        'paasta_tools.deployd.common.get_marathon_client',
                        autospec=True) as mock_marathon_client:
        assert get_marathon_client_from_config(
        ) == mock_marathon_client.return_value
Exemplo n.º 2
0
 def __init__(self):
     super(DeployDaemon, self).__init__()
     self.started = False
     self.daemon = True
     service_configuration_lib.disable_yaml_cache()
     self.config = load_system_paasta_config()
     self.setup_logging()
     self.bounce_q = DedupedPriorityQueue("BounceQueue")
     self.inbox_q = PaastaQueue("InboxQueue")
     self.control = PaastaQueue("ControlQueue")
     self.inbox = Inbox(self.inbox_q, self.bounce_q)
     self.marathon_client = get_marathon_client_from_config()
Exemplo n.º 3
0
 def my_init(self, filewatcher):
     self.filewatcher = filewatcher
     self.marathon_client = get_marathon_client_from_config()
Exemplo n.º 4
0
 def my_init(self, filewatcher):
     self.filewatcher = filewatcher
     self.public_config = load_system_paasta_config()
     self.marathon_client = get_marathon_client_from_config()
Exemplo n.º 5
0
 def __init__(self, inbox_q, cluster, config, **kwargs):
     super(MaintenanceWatcher, self).__init__(inbox_q, cluster, config)
     self.draining = set()
     self.marathon_client = get_marathon_client_from_config()