Skip to content
This repository has been archived by the owner on Dec 7, 2023. It is now read-only.

Switch imports to gitops-toolkit #354

Merged
merged 4 commits into from
Aug 19, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion cmd/ignite-spawn/ignite-spawn.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@ import (
"path"

log "github.com/sirupsen/logrus"
patchutil "github.com/weaveworks/gitops-toolkit/pkg/util/patch"
api "github.com/weaveworks/ignite/pkg/apis/ignite"
"github.com/weaveworks/ignite/pkg/apis/ignite/scheme"
"github.com/weaveworks/ignite/pkg/constants"
"github.com/weaveworks/ignite/pkg/container"
dmcleanup "github.com/weaveworks/ignite/pkg/dmlegacy/cleanup"
"github.com/weaveworks/ignite/pkg/prometheus"
patchutil "github.com/weaveworks/ignite/pkg/util/patch"
)

func main() {
Expand Down
2 changes: 1 addition & 1 deletion cmd/ignite/run/helpers.go
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package run

import (
"github.com/weaveworks/gitops-toolkit/pkg/filter"
api "github.com/weaveworks/ignite/pkg/apis/ignite"
"github.com/weaveworks/ignite/pkg/filter"
"github.com/weaveworks/ignite/pkg/providers"
)

Expand Down
2 changes: 1 addition & 1 deletion cmd/ignite/run/images.go
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package run

import (
"github.com/weaveworks/gitops-toolkit/pkg/filter"
api "github.com/weaveworks/ignite/pkg/apis/ignite"
"github.com/weaveworks/ignite/pkg/filter"
"github.com/weaveworks/ignite/pkg/providers"
"github.com/weaveworks/ignite/pkg/util"
)
Expand Down
8 changes: 4 additions & 4 deletions cmd/ignite/run/inspect.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ import (
"fmt"
"strings"

"github.com/weaveworks/gitops-toolkit/pkg/filter"
"github.com/weaveworks/gitops-toolkit/pkg/runtime"
api "github.com/weaveworks/ignite/pkg/apis/ignite"
"github.com/weaveworks/ignite/pkg/apis/ignite/scheme"
meta "github.com/weaveworks/ignite/pkg/apis/meta/v1alpha1"
"github.com/weaveworks/ignite/pkg/filter"
"github.com/weaveworks/ignite/pkg/providers"
)

Expand All @@ -18,12 +18,12 @@ type InspectFlags struct {

type inspectOptions struct {
*InspectFlags
object meta.Object
object runtime.Object
}

func (i *InspectFlags) NewInspectOptions(k, objectMatch string) (*inspectOptions, error) {
var err error
var kind meta.Kind
var kind runtime.Kind
io := &inspectOptions{InspectFlags: i}

switch strings.ToLower(k) {
Expand Down
2 changes: 1 addition & 1 deletion cmd/ignite/run/kernels.go
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package run

import (
"github.com/weaveworks/gitops-toolkit/pkg/filter"
api "github.com/weaveworks/ignite/pkg/apis/ignite"
"github.com/weaveworks/ignite/pkg/filter"
"github.com/weaveworks/ignite/pkg/providers"
"github.com/weaveworks/ignite/pkg/util"
)
Expand Down
2 changes: 1 addition & 1 deletion cmd/ignite/run/rmi.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import (
"os"

log "github.com/sirupsen/logrus"
"github.com/weaveworks/gitops-toolkit/pkg/filter"
api "github.com/weaveworks/ignite/pkg/apis/ignite"
"github.com/weaveworks/ignite/pkg/filter"
"github.com/weaveworks/ignite/pkg/operations/lookup"
"github.com/weaveworks/ignite/pkg/providers"
)
Expand Down
2 changes: 1 addition & 1 deletion cmd/ignite/run/rmk.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import (
"os"

log "github.com/sirupsen/logrus"
"github.com/weaveworks/gitops-toolkit/pkg/filter"
api "github.com/weaveworks/ignite/pkg/apis/ignite"
"github.com/weaveworks/ignite/pkg/filter"
"github.com/weaveworks/ignite/pkg/operations/lookup"
"github.com/weaveworks/ignite/pkg/providers"
)
Expand Down
76 changes: 38 additions & 38 deletions docs/api/ignite_v1alpha1.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,9 +121,9 @@

``` go
const (
KindImage meta.Kind = "Image"
KindKernel meta.Kind = "Kernel"
KindVM meta.Kind = "VM"
KindImage runtime.Kind = "Image"
KindKernel runtime.Kind = "Kernel"
KindVM runtime.Kind = "VM"
)
```

Expand Down Expand Up @@ -340,7 +340,7 @@ func SetDefaults_VMSpec(obj *VMSpec)
func SetDefaults_VMStatus(obj *VMStatus)
```

## <a name="FileMapping">type</a> [FileMapping](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=7677:7772#L206)
## <a name="FileMapping">type</a> [FileMapping](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=7771:7866#L207)

``` go
type FileMapping struct {
Expand All @@ -351,15 +351,15 @@ type FileMapping struct {

FileMapping defines mappings between files on the host and VM

## <a name="Image">type</a> [Image](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=342:806#L17)
## <a name="Image">type</a> [Image](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=403:876#L18)

``` go
type Image struct {
meta.TypeMeta `json:",inline"`
// meta.ObjectMeta is also embedded into the struct, and defines the human-readable name, and the machine-readable ID
runtime.TypeMeta `json:",inline"`
// runtime.ObjectMeta is also embedded into the struct, and defines the human-readable name, and the machine-readable ID
// Name is available at the .metadata.name JSON path
// ID is available at the .metadata.uid JSON path (the Go type is k8s.io/apimachinery/pkg/types.UID, which is only a typed string)
meta.ObjectMeta `json:"metadata"`
runtime.ObjectMeta `json:"metadata"`

Spec ImageSpec `json:"spec"`
Status ImageStatus `json:"status"`
Expand All @@ -369,7 +369,7 @@ type Image struct {
Image represents a cached OCI image ready to be used with Ignite
+k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

## <a name="ImageSourceType">type</a> [ImageSourceType](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=995:1022#L34)
## <a name="ImageSourceType">type</a> [ImageSourceType](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=1065:1092#L35)

``` go
type ImageSourceType string
Expand All @@ -384,7 +384,7 @@ const (
)
```

## <a name="ImageSpec">type</a> [ImageSpec](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=854:921#L29)
## <a name="ImageSpec">type</a> [ImageSpec](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=924:991#L30)

``` go
type ImageSpec struct {
Expand All @@ -394,7 +394,7 @@ type ImageSpec struct {

ImageSpec declares what the image contains

## <a name="ImageStatus">type</a> [ImageStatus](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=2320:2469#L68)
## <a name="ImageStatus">type</a> [ImageStatus](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=2390:2539#L69)

``` go
type ImageStatus struct {
Expand All @@ -405,15 +405,15 @@ type ImageStatus struct {

ImageStatus defines the status of the image

## <a name="Kernel">type</a> [Kernel](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=4848:5315#L132)
## <a name="Kernel">type</a> [Kernel](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=4924:5400#L133)

``` go
type Kernel struct {
meta.TypeMeta `json:",inline"`
// meta.ObjectMeta is also embedded into the struct, and defines the human-readable name, and the machine-readable ID
runtime.TypeMeta `json:",inline"`
// runtime.ObjectMeta is also embedded into the struct, and defines the human-readable name, and the machine-readable ID
// Name is available at the .metadata.name JSON path
// ID is available at the .metadata.uid JSON path (the Go type is k8s.io/apimachinery/pkg/types.UID, which is only a typed string)
meta.ObjectMeta `json:"metadata"`
runtime.ObjectMeta `json:"metadata"`

Spec KernelSpec `json:"spec"`
Status KernelStatus `json:"status"`
Expand All @@ -425,7 +425,7 @@ kernels This file is stored in
/var/lib/firecracker/kernels/{oci-image-digest}/metadata.json
+k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

## <a name="KernelSpec">type</a> [KernelSpec](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=5368:5541#L144)
## <a name="KernelSpec">type</a> [KernelSpec](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=5453:5626#L145)

``` go
type KernelSpec struct {
Expand All @@ -435,7 +435,7 @@ type KernelSpec struct {

KernelSpec describes the properties of a kernel

## <a name="KernelStatus">type</a> [KernelStatus](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=5592:5708#L151)
## <a name="KernelStatus">type</a> [KernelStatus](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=5677:5793#L152)

``` go
type KernelStatus struct {
Expand All @@ -446,7 +446,7 @@ type KernelStatus struct {

KernelStatus describes the status of a kernel

## <a name="NetworkMode">type</a> [NetworkMode](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=8126:8149#L221)
## <a name="NetworkMode">type</a> [NetworkMode](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=8220:8243#L222)

``` go
type NetworkMode string
Expand All @@ -463,13 +463,13 @@ const (
)
```

### <a name="NetworkMode.String">func</a> (NetworkMode) [String](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=8189:8226#L225)
### <a name="NetworkMode.String">func</a> (NetworkMode) [String](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=8283:8320#L226)

``` go
func (nm NetworkMode) String() string
```

## <a name="OCIImageClaim">type</a> [OCIImageClaim](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=1218:1636#L42)
## <a name="OCIImageClaim">type</a> [OCIImageClaim](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=1288:1706#L43)

``` go
type OCIImageClaim struct {
Expand All @@ -485,7 +485,7 @@ type OCIImageClaim struct {

OCIImageClaim defines a claim for importing an OCI image

## <a name="OCIImageSource">type</a> [OCIImageSource](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=1743:2271#L54)
## <a name="OCIImageSource">type</a> [OCIImageSource](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=1813:2341#L55)

``` go
type OCIImageSource struct {
Expand All @@ -505,11 +505,11 @@ type OCIImageSource struct {
OCIImageSource specifies how the OCI image was imported. It is the
status variant of OCIImageClaim

## <a name="Pool">type</a> [Pool](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=2744:2924#L77)
## <a name="Pool">type</a> [Pool](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=2814:3000#L78)

``` go
type Pool struct {
meta.TypeMeta `json:",inline"`
runtime.TypeMeta `json:",inline"`

Spec PoolSpec `json:"spec"`
Status PoolStatus `json:"status"`
Expand All @@ -521,7 +521,7 @@ snapshotter part of Ignite, and the file (existing as a singleton) is
present at /var/lib/firecracker/snapshotter/pool.json
+k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

## <a name="PoolDevice">type</a> [PoolDevice](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=4215:4605#L119)
## <a name="PoolDevice">type</a> [PoolDevice](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=4291:4681#L120)

``` go
type PoolDevice struct {
Expand All @@ -537,7 +537,7 @@ type PoolDevice struct {

PoolDevice defines one device in the pool

## <a name="PoolDeviceType">type</a> [PoolDeviceType](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=3944:3970#L109)
## <a name="PoolDeviceType">type</a> [PoolDeviceType](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=4020:4046#L110)

``` go
type PoolDeviceType string
Expand All @@ -552,7 +552,7 @@ const (
)
```

## <a name="PoolSpec">type</a> [PoolSpec](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=2971:3684#L87)
## <a name="PoolSpec">type</a> [PoolSpec](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=3047:3760#L88)

``` go
type PoolSpec struct {
Expand All @@ -573,7 +573,7 @@ type PoolSpec struct {

PoolSpec defines the Pool’s specification

## <a name="PoolStatus">type</a> [PoolStatus](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=3734:3942#L103)
## <a name="PoolStatus">type</a> [PoolStatus](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=3810:4018#L104)

``` go
type PoolStatus struct {
Expand All @@ -585,7 +585,7 @@ type PoolStatus struct {

PoolStatus defines the Pool’s current status

## <a name="SSH">type</a> [SSH](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=7992:8069#L215)
## <a name="SSH">type</a> [SSH](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=8086:8163#L216)

``` go
type SSH struct {
Expand All @@ -610,15 +610,15 @@ func (s *SSH) MarshalJSON() ([]byte, error)
func (s *SSH) UnmarshalJSON(b []byte) error
```

## <a name="VM">type</a> [VM](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=5910:6365#L159)
## <a name="VM">type</a> [VM](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=5995:6459#L160)

``` go
type VM struct {
meta.TypeMeta `json:",inline"`
// meta.ObjectMeta is also embedded into the struct, and defines the human-readable name, and the machine-readable ID
runtime.TypeMeta `json:",inline"`
// runtime.ObjectMeta is also embedded into the struct, and defines the human-readable name, and the machine-readable ID
// Name is available at the .metadata.name JSON path
// ID is available at the .metadata.uid JSON path (the Go type is k8s.io/apimachinery/pkg/types.UID, which is only a typed string)
meta.ObjectMeta `json:"metadata"`
runtime.ObjectMeta `json:"metadata"`

Spec VMSpec `json:"spec"`
Status VMStatus `json:"status"`
Expand All @@ -629,15 +629,15 @@ VM represents a virtual machine run by Firecracker These files are
stored in /var/lib/firecracker/vm/{vm-id}/metadata.json
+k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

## <a name="VMImageSpec">type</a> [VMImageSpec](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=7298:7367#L191)
## <a name="VMImageSpec">type</a> [VMImageSpec](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=7392:7461#L192)

``` go
type VMImageSpec struct {
OCIClaim OCIImageClaim `json:"ociClaim"`
}
```

## <a name="VMKernelSpec">type</a> [VMKernelSpec](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=7369:7490#L195)
## <a name="VMKernelSpec">type</a> [VMKernelSpec](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=7463:7584#L196)

``` go
type VMKernelSpec struct {
Expand All @@ -646,7 +646,7 @@ type VMKernelSpec struct {
}
```

## <a name="VMNetworkSpec">type</a> [VMNetworkSpec](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=7492:7610#L200)
## <a name="VMNetworkSpec">type</a> [VMNetworkSpec](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=7586:7704#L201)

``` go
type VMNetworkSpec struct {
Expand All @@ -655,7 +655,7 @@ type VMNetworkSpec struct {
}
```

## <a name="VMSpec">type</a> [VMSpec](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=6413:7296#L171)
## <a name="VMSpec">type</a> [VMSpec](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=6507:7390#L172)

``` go
type VMSpec struct {
Expand All @@ -681,7 +681,7 @@ type VMSpec struct {

VMSpec describes the configuration of a VM

## <a name="VMState">type</a> [VMState](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=8623:8642#L238)
## <a name="VMState">type</a> [VMState](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=8717:8736#L239)

``` go
type VMState string
Expand All @@ -697,7 +697,7 @@ const (
)
```

## <a name="VMStatus">type</a> [VMStatus](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=8802:9023#L247)
## <a name="VMStatus">type</a> [VMStatus](https://github.com/weaveworks/ignite/tree/master/pkg/apis/ignite/v1alpha1/types.go?s=8896:9117#L248)

``` go
type VMStatus struct {
Expand Down
Loading