Giter VIP home page Giter VIP logo

cloudsim_k8s_launcher's Introduction

cloudsim_k8s_launcher

cloudsim_k8s_launcher is responsible for creating and closing k8s resources containing unreal engine pixel streaming application in the cluster

Deploy for CloudSim

  1. Edit the dockerfile to setup the environment variable (important)
  • PORT - the port the launcher listen to(no need to change)
  • HOST - the ip address of the host running the k8s cluster. The host runs the cloudsim_k8s_launcher.
  • MONGO_IP - ip address of the mongodb for keeping world state data, usually the same host \
  • MONGO_PORT - port of mongodb
  • IMAGE_REPO - when launcher create the resource, it will pull images from the docker hub. This specify where to pull the image. Default: robcog or xiaojunll
  1. Build the image
docker build -t robcog/cloudsim_k8s_launcher .
docker push robcog/cloudsim_k8s_launcher
  1. Deploy the image, the launcher will listen to port 30002, you can change that in cloudsim_k8s_launcher.yaml
kubectl apply -f cloudsim_k8s_launcher.yaml
  1. How to use the launcher Send HTTP POST request to the launcher with JSON data, one does not need to send post request directly, use the Prolog query in knowrob_ameva:
ag_create_clients(Num, LevelName, ClientId) 

once the launcher receives the request from knowrob_ameva, it will create an unreal engine application in k8s, and pass the ip address of knowrob, so the unreal engine application can connect to knowrob_ameva

JSON data:

{
	'KRServerPort' : xxx,             // it depends on the port  that knowrob listen to
	                                  // ue_start_src(Port) knowrob use this to specify port	                                      
	'KRProtocol' : 'kr_websocket',   // default, you can change the value in knowrob_ameva
	'LevelName' : xxxx                 // the image name of the unreal engine image, it is usually named with level name
}

PS: there is no need to pass the ip of the knowrob_ameva

  1. configuration in knowrob_ameva in knowrob_ameva, ag_create_clients(Num, LevelName, ClientId) is used to post request to the launcher to create k8s resources. After deploying the launcher, one needs to configure the ip address and port of the launcher in ag_conn.cpp

cloudsim_k8s_launcher's People

Contributors

xxjunxx avatar andreihaidu avatar

Stargazers

 avatar

Watchers

James Cloos avatar  avatar Abhijit Vyas avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.