This commit is contained in:
Zsolt Ero
2024-08-29 01:09:13 +02:00
parent 3d83e0809e
commit 4d20bba7d1
2 changed files with 5 additions and 2 deletions

View File

@@ -4,5 +4,5 @@
# debug, once per minute create indexes
# * * * * * ofm sudo /data/ofm/venv/bin/python -u /data/ofm/tile_gen/bin/tile_gen.py make-indexes >> /data/ofm/tile_gen/logs/debug-cron.log 2>&1
#* * * * * ofm sudo /data/ofm/venv/bin/python -u /data/ofm/tile_gen/bin/tile_gen.py make-indexes >> /data/ofm/tile_gen/logs/debug-cron.log 2>&1

View File

@@ -48,6 +48,8 @@ def prepare_venv(c):
def prepare_tile_gen(c):
c.sudo('rm -f /etc/cron.d/ofm_tile_gen')
install_planetiler(c)
c.sudo(f'rm -rf {TILE_GEN_BIN}')
@@ -69,11 +71,12 @@ def prepare_tile_gen(c):
c.sudo(f'{VENV_BIN}/pip install -e {TILE_GEN_BIN} --use-pep517')
c.sudo('mkdir -p /data/ofm/tile_gen/logs')
put(c, SCRIPTS_DIR / 'tile_gen' / 'cron.d' / 'ofm_tile_gen', '/etc/cron.d/')
c.sudo('chown ofm:ofm /data/ofm/tile_gen/{,*}')
c.sudo(f'chown ofm:ofm -R {TILE_GEN_BIN}')
put(c, SCRIPTS_DIR / 'tile_gen' / 'cron.d' / 'ofm_tile_gen', '/etc/cron.d/')
def upload_http_host_config(c):
domain_le = dotenv_val('DOMAIN_LE').lower()