update archive thumbnail
This commit is contained in:
1 parent
ca9e40f43d
commit
3555fa05a2
6 files changed
+27
-5
No files matched your search
@@ -9,11 +9,18 @@ from utils import blob
|
||||
|
||||
JPEG_QUALITY = 90
|
||||
|
||||
# 이름이 고정된 산출물. 경로가 정해져 있어 컬럼에 다시 적지 않고 만들어 쓴다
|
||||
THUMBNAIL = "thumbnail.jpg"
|
||||
|
||||
|
||||
def artifact_path(pipeline: str, task_id: str, name: str) -> str:
|
||||
return f"{pipeline}/{task_id}/{name}"
|
||||
|
||||
|
||||
def artifact_url(pipeline: str, task_id: str, name: str) -> str:
|
||||
return blob.public_url(artifact_path(pipeline, task_id, name))
|
||||
|
||||
|
||||
async def store_bytes(pipeline: str, task_id: str, name: str, data: bytes, *,
|
||||
download_as: str | None = None) -> str:
|
||||
"""download_as를 주면 브라우저가 그 주소를 열 때 그 이름으로 내려받는다"""
|
||||
|
||||
Reference in new issue
Block a user