Skip to content

Commit

Permalink
add allow private network header in local setup (openai#248)
Browse files Browse the repository at this point in the history
  • Loading branch information
egor-romanov authored May 16, 2023
1 parent 0d3c789 commit d37b831
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion local_server/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,9 @@
@app.route("/.well-known/ai-plugin.json")
async def get_manifest(request):
file_path = "./local_server/ai-plugin.json"
return FileResponse(file_path, media_type="text/json")
simple_headers = {}
simple_headers["Access-Control-Allow-Private-Network"] = "true"
return FileResponse(file_path, media_type="text/json", headers=simple_headers)


@app.route("/.well-known/logo.png")
Expand Down

0 comments on commit d37b831

Please sign in to comment.