Skip to content

Commit

Permalink
added spiffs support on server
Browse files Browse the repository at this point in the history
  • Loading branch information
Foroxon committed Mar 2, 2024
1 parent 1e63f49 commit 6b534c4
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions deploy/update_server/update_server.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,12 @@ async def update(request):
async def update_beta(request):
return FileResponse(f'{shared_beta_path}/{request.path_params["filename"]}.bin')

async def spiffs_update(request):
return FileResponse(f'{shared_path}/spiffs/{request.path_params["filename"]}.bin')

async def spiffs_update_beta(request):
return FileResponse(f'{shared_beta_path}/spiffs/{request.path_params["filename"]}.bin')


async def update_cache():
mc = Client(memcached_host, 11211)
Expand All @@ -81,7 +87,9 @@ async def update_cache():
Route('/list', list),
Route('/betalist', list_beta),
Route('/{filename}.bin', update),
Route('/spiffs/{filename}.bin', spiffs_update),
Route('/beta/{filename}.bin', update_beta),
Route('/beta/spiffs/{filename}.bin', spiffs_update_beta),
])


Expand Down

0 comments on commit 6b534c4

Please sign in to comment.