Pull latest image when main.py is run

This commit is contained in:
Gabriel Simmer 2024-08-03 21:33:21 +01:00
parent 9766f7b81b
commit 566a4a4a38
Signed by: arch
SSH key fingerprint: SHA256:m3OEcdtrnBpMX+2BDGh/byv3hrCekCLzDYMdvGEKPPQ

View file

@ -6,6 +6,7 @@ import hashlib
URL = 'https://arch.dog'
def main():
subprocess.run(['/usr/bin/docker', 'pull', 'git.gmem.ca/arch/servo:latest'])
filename = os.path.join('/tmp', str(uuid.uuid4()))
ARGS = ['-z', '-y2', f'-o{filename}', '--resolution=1920x1080']
print(f'rendering {URL} to {filename}')