Documentation
¶
Index ¶
- type DesiredPodState
- type KubeClient
- func (kc *KubeClient) BuildGameType(gameType *models.GameType) (*api.Pod, error)
- func (kc *KubeClient) StartBot(ip string, botID int32, proj *models.Project, game *models.Game) (*api.Pod, error)
- func (kc *KubeClient) StartGame(game *models.Game) (*api.Pod, error)
- func (kc *KubeClient) WatchToCompletion(pod *api.Pod) (*api.Pod, error)
- func (kc *KubeClient) WatchToStartup(pod *api.Pod) (*api.Pod, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DesiredPodState ¶
type KubeClient ¶
type KubeClient struct {
// contains filtered or unexported fields
}
func NewClient ¶
func NewClient() (*KubeClient, error)
NewClient returns a client that can communicate to the apiserver to start jobs. IMPORTANT: Creating a client with this function only work if running from inside kubernetes cluster! @returns valid client if successful, error otherwise
func (*KubeClient) BuildGameType ¶
BuildGameType kicks off a gametype build @returns error if client fails to start the gametype builder pod
func (*KubeClient) StartBot ¶
func (kc *KubeClient) StartBot(ip string, botID int32, proj *models.Project, game *models.Game) (*api.Pod, error)
StarBot starts a bot, which runs a users code in the container built for their language @returns error if client fails to start the bot pod
func (*KubeClient) StartGame ¶
StartGame starts a game, requires a game and the projects associated with the game @returns error if client fails to start the game runner pod
func (*KubeClient) WatchToCompletion ¶
func (*KubeClient) WatchToStartup ¶
Click to show internal directories.
Click to hide internal directories.