Skip to content

Commit

Permalink
Polish deployment related issues
Browse files Browse the repository at this point in the history
  • Loading branch information
kumaranvpl committed Nov 21, 2024
1 parent 6ac0887 commit c72958f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion {{cookiecutter.project_slug}}/fly.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ primary_region = 'ams'
dockerfile = 'docker/Dockerfile'

[http_service]
internal_port = 8888
internal_port = {% if cookiecutter.app_type == 'fastapi' %}8008{% else %}8888{% endif %}
force_https = true
auto_stop_machines = 'stop'
auto_start_machines = true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,8 @@
<div id="workflows"></div>
<ul id="messages"></ul>
<script>
const API_URL = 'http://127.0.0.1:8008/fastagency';
const WS_URL = 'ws://127.0.0.1:8008/fastagency/ws'; // nosemgrep
const API_URL = location.protocol + '//' + location.host + '/fastagency';// Use wss:// if location.protocol is https else use ws://
const WS_URL = (location.protocol === 'https:' ? 'wss://' : 'ws://') + location.host + '/fastagency/ws'; // nosemgrep
let socket;
async function fetchWorkflows() {
Expand Down Expand Up @@ -115,6 +115,7 @@
"""


# Optional basic HTML page to interact with the workflows
@app.get("/")
async def get() -> HTMLResponse:
return HTMLResponse(html)
Expand Down

0 comments on commit c72958f

Please sign in to comment.