Assist (#57)
* feat(api): assist peerJS server * feat(api): install assist_server dependencies and start it with the API * feat(api): assist: list live sessions * feat(nginx): expose assist_server and block peers listing * feat(api): merged sourcemaps reader and assist-server feat(api): change image definition feat(api): changed service start command feat(utilities): created full server & image definition feat(nginx): reset chalice configuration * feat(utilities): utilities.yaml * feat(nginx): utilities URL * feat(utilities): utilities template * feat(ci): Adding utilities GH action. Signed-off-by: Rajesh Rajendran <rjshrjndrn@gmail.com> * feat(utilities): build script * feat(utilities): build script fix image name * feat(utilities): tag and push image as latest * feat(api): tag and push image as latest * feat(api): extract peers host Co-authored-by: Rajesh Rajendran <rjshrjndrn@gmail.com>
This commit is contained in:
parent
171dca5eaa
commit
d4d62323dd
3 changed files with 4 additions and 1 deletions
|
|
@ -33,6 +33,7 @@
|
|||
"sourcemaps_reader": "http://utilities.app.svc.cluster.local:9000/sourcemaps",
|
||||
"sourcemaps_bucket": "sourcemaps",
|
||||
"js_cache_bucket": "sessions-assets",
|
||||
"peers": "http://utilities.app.svc.cluster.local:9000/peers",
|
||||
"async_Token": "",
|
||||
"EMAIL_HOST": "",
|
||||
"EMAIL_PORT": "587",
|
||||
|
|
|
|||
|
|
@ -1,6 +1,7 @@
|
|||
from chalicelib.utils import pg_client, helper
|
||||
from chalicelib.core import projects
|
||||
import requests
|
||||
from chalicelib.utils.helper import environ
|
||||
|
||||
SESSION_PROJECTION_COLS = """s.project_id,
|
||||
s.session_id::text AS session_id,
|
||||
|
|
@ -20,7 +21,7 @@ SESSION_PROJECTION_COLS = """s.project_id,
|
|||
|
||||
def get_live_sessions(project_id):
|
||||
project_key = projects.get_project_key(project_id)
|
||||
connected_peers = requests.get(f"http://127.0.0.1:9000/peers/{project_key}")
|
||||
connected_peers = requests.get(environ["peers"] + f"/{project_key}")
|
||||
if connected_peers.status_code != 200:
|
||||
print("!! issue with the peer-server")
|
||||
print(connected_peers.text)
|
||||
|
|
|
|||
|
|
@ -62,6 +62,7 @@ env:
|
|||
S3_KEY: minios3AccessKeyS3cr3t
|
||||
S3_SECRET: m1n10s3CretK3yPassw0rd
|
||||
sourcemaps_reader: 'http://utilities.app.svc.cluster.local:9000/sourcemaps'
|
||||
peers: 'http://utilities.app.svc.cluster.local:9000/peers'
|
||||
# Enable logging for python app
|
||||
# Ref: https://stackoverflow.com/questions/43969743/logs-in-kubernetes-pod-not-showing-up
|
||||
PYTHONUNBUFFERED: '0'
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue