client

package
v0.0.0-alpha.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 16, 2022 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	*github.Client
}

func New

func New(opts ...ClientOption) *Client

func (*Client) CreateRunnerToken

func (gh *Client) CreateRunnerToken(ctx context.Context, runnerURL string) (RunnerToken, error)

func (*Client) GetRunner

func (gh *Client) GetRunner(ctx context.Context, runnerURL string, runnerID int64) (Runner, error)

type ClientOption

type ClientOption func(o *clientOption)

func WithAccessToken

func WithAccessToken(token string) ClientOption

func WithEndpoint

func WithEndpoint(endpoint string) ClientOption

type Runner

type Runner interface {
	GetName() string
	GetBusy() bool
	GetOS() string
	GetStatus() string
}

type RunnerToken

type RunnerToken interface {
	GetToken() string
	GetExpiresAt() github.Timestamp
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL