Skip to content

Together-Coding/Runtime-Agent

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

36 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Runtime-Agent

Runtime-Agent runs in a Runtime-Container to initialize its machine and to link a user in web IDE with a terminal of the container. It also prepares for code execution by downloading project code from IDE server.

architecture

What it does

  • When Runtime-Container is launched and this server is up, it is assigned a unique API key from Runtime-Bridge and creates random password used for SSH connection.
  • It creates local SSH connection, and forwards messages from the user in web IDE to SSH and vice versa.
  • It prepares for code execution by downloading project code from IDE server into its local directory.

Requirements

  • Python 3.6 to 3.9

    version 3.10 or newer is not allowed because this runs in runtime-containers. Especially, GCC container has python 3.9.

Development

  • Install packages
    $ pip install -r requirements.txt
  • Start server
    $ DEBUG=true uvicorn agent:app --reload

Deployment

There is no need to deploy directly. Runtime-Agent runs inside of Runtime-Container. All you have to do is specify the version of the commit hash you want to use in Dockerfiles of runtime-container.

API Document

API documents can be found here: http://localhost:8000/docs.

They are generated by swagger integrated into FastAPI. It automatically updates documents whenever you modify your code. See more details from here.

api document

About

SSH Relay and Agent Server Living in Container for Web IDE

Topics

Resources

License

Stars

Watchers

Forks

Languages