2021-02-12 15:01:35 +00:00
|
|
|
directories = {
|
|
|
|
'/opt/matrix-media-repo': {
|
|
|
|
'owner': 'matrix-media-repo',
|
|
|
|
'group': 'matrix-media-repo',
|
|
|
|
},
|
|
|
|
'/var/matrix/media': {
|
|
|
|
'owner': 'matrix-media-repo',
|
|
|
|
'group': 'matrix-media-repo',
|
|
|
|
},
|
|
|
|
}
|
|
|
|
|
|
|
|
users = {
|
|
|
|
'matrix-media-repo': {
|
|
|
|
'home': '/opt/matrix-media-repo',
|
|
|
|
},
|
|
|
|
}
|
|
|
|
|
|
|
|
files = {
|
|
|
|
'/opt/matrix-media-repo/config.yaml': {
|
|
|
|
'owner': 'matrix-media-repo',
|
|
|
|
'content_type': 'mako',
|
|
|
|
},
|
|
|
|
'/etc/systemd/system/matrix-media-repo.service': {
|
|
|
|
'triggers': {
|
|
|
|
'action:systemd-reload',
|
|
|
|
'svc_systemd:matrix-media-repo:restart',
|
|
|
|
},
|
|
|
|
},
|
2022-04-03 06:04:16 +00:00
|
|
|
'/opt/matrix-media-repo/media_repo': {
|
|
|
|
'content_hash': node.metadata.get('matrix-media-repo/sha1', None),
|
|
|
|
'content_type': 'download',
|
|
|
|
'mode': '0755',
|
|
|
|
'source': 'https://github.com/turt2live/matrix-media-repo/releases/download/{}/media_repo-linux-x64'.format(node.metadata.get('matrix-media-repo/version')),
|
2021-02-12 15:01:35 +00:00
|
|
|
'triggers': {
|
2021-03-05 06:21:23 +00:00
|
|
|
'svc_systemd:matrix-media-repo:restart',
|
2021-02-12 15:01:35 +00:00
|
|
|
},
|
|
|
|
},
|
|
|
|
}
|
|
|
|
|
|
|
|
svc_systemd = {
|
|
|
|
'matrix-media-repo': {
|
|
|
|
'needs': {
|
|
|
|
'file:/etc/systemd/system/matrix-media-repo.service',
|
|
|
|
'file:/opt/matrix-media-repo/config.yaml',
|
2022-04-03 06:04:16 +00:00
|
|
|
'file:/opt/matrix-media-repo/media_repo',
|
2021-05-14 18:02:39 +00:00
|
|
|
'postgres_db:matrix-media-repo',
|
2021-02-12 15:01:35 +00:00
|
|
|
},
|
|
|
|
},
|
|
|
|
}
|