Update Docker make file
- Include PIP proxies. - Add docker compose targets. Signed-off-by: Roberto Rosario <roberto.rosario@mayan-edms.com>
This commit is contained in:
@@ -181,5 +181,28 @@ class PlatformTemplateSupervisordDocker(PlatformTemplate):
|
||||
return {'workers': Worker.all()}
|
||||
|
||||
|
||||
class PlatformTemplateWorkerQueues(PlatformTemplate):
|
||||
label = _('Template showing the queues of a worker.')
|
||||
name = 'worker_queues'
|
||||
|
||||
variables = (
|
||||
Variable(
|
||||
name='WORKER_NAME', default=None,
|
||||
environment_name='MAYAN_WORKER_NAME'
|
||||
),
|
||||
)
|
||||
|
||||
def get_context(self):
|
||||
worker_name = self.get_variables_context().get('WORKER_NAME')
|
||||
queues = Worker.get(name=worker_name).queues
|
||||
|
||||
return {
|
||||
'queues': queues, 'queue_names': sorted(
|
||||
map(lambda x: x.name, queues)
|
||||
)
|
||||
}
|
||||
|
||||
|
||||
PlatformTemplate.register(klass=PlatformTemplateSupervisord)
|
||||
PlatformTemplate.register(klass=PlatformTemplateSupervisordDocker)
|
||||
PlatformTemplate.register(klass=PlatformTemplateWorkerQueues)
|
||||
|
||||
Reference in New Issue
Block a user