Adjust endpoint so it can receive tusd hooks

Without any proxying and tusd running as a separate service:
``
tusd -upload-dir=./database/tmp -hooks-http=http://localhost:8000/api/upload/_resumable_upload -hooks-http-forward-headers=X-Api-Key --hooks-enabled-events=post-finish
```

Adjust ./database/tmp to new_file_path, and this should work. Now we
just need to proxy `api/upload/resumable_upload` to `<tusd_port>/files`
and we're good for a production setup.
This commit is contained in:
mvdbeek
2021-10-12 13:34:55 +02:00
parent 32065d123a
commit 0e1ff5a30c
3 changed files with 39 additions and 34 deletions
+1 -2
View File
@@ -3,13 +3,12 @@ import os
import aiotus
import asyncclick as click
creation_url = "http://localhost:8000/"
UPLOAD_ENDPOINT = '/api/upload/resumable_upload'
@click.command()
@click.option("--url", default='http://localhost:8080', help="URL of Galaxy instance")
@click.option("--api_key", envvar="GALAXY_API_KEY", help="API key for Galaxy instance")
@click.option("--api_key", envvar="GALAXY_API_KEY", required=True, help="API key for Galaxy instance")
@click.option('--history_id', type=str, required=True, help="Target History ID")
@click.option('--file_type', default="auto", type=str, help="Galaxy file type to use")
@click.option('--dbkey', default="?", type=str, help="Genome Build for dataset")