-
Notifications
You must be signed in to change notification settings - Fork 4.8k
Expand file tree
/
Copy pathlogs.go
More file actions
31 lines (25 loc) · 717 Bytes
/
logs.go
File metadata and controls
31 lines (25 loc) · 717 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
package internalversion
import (
rest "k8s.io/client-go/rest"
kapi "k8s.io/kubernetes/pkg/api"
appsapi "github.com/openshift/origin/pkg/apps/apis/apps"
)
type RolloutLogInterface interface {
Logs(name string, options appsapi.DeploymentLogOptions) *rest.Request
}
func NewRolloutLogClient(c rest.Interface, ns string) RolloutLogInterface {
return &rolloutLogs{client: c, ns: ns}
}
type rolloutLogs struct {
client rest.Interface
ns string
}
func (c *rolloutLogs) Logs(name string, options appsapi.DeploymentLogOptions) *rest.Request {
return c.client.
Get().
Namespace(c.ns).
Resource("deploymentConfigs").
Name(name).
SubResource("log").
VersionedParams(&options, kapi.ParameterCodec)
}