This commit is contained in:
Madhan Raj Mookkandy 2020-09-08 13:04:05 -07:00
Родитель ebd9b0265d
Коммит 8a65ad58d6
77 изменённых файлов: 269 добавлений и 219 удалений

Просмотреть файл

@ -6,8 +6,8 @@ package client
import (
log "k8s.io/klog"
"github.com/microsoft/moc-proto/pkg/auth"
admin_pb "github.com/microsoft/moc-proto/rpc/cloudagent/admin"
"github.com/microsoft/moc/pkg/auth"
admin_pb "github.com/microsoft/moc/rpc/cloudagent/admin"
)
// GetLogClient returns the log client to communicate with the wssdcloud agent

Просмотреть файл

@ -16,7 +16,7 @@ import (
"google.golang.org/grpc/keepalive"
log "k8s.io/klog"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc/pkg/auth"
)
const (

Просмотреть файл

@ -6,8 +6,8 @@ package client
import (
log "k8s.io/klog"
"github.com/microsoft/moc-proto/pkg/auth"
cloud_pb "github.com/microsoft/moc-proto/rpc/cloudagent/cloud"
"github.com/microsoft/moc/pkg/auth"
cloud_pb "github.com/microsoft/moc/rpc/cloudagent/cloud"
)
// GetLocationClient returns the virtual machine client to comminicate with the wssd agent

Просмотреть файл

@ -5,8 +5,8 @@ package client
import (
log "k8s.io/klog"
"github.com/microsoft/moc-proto/pkg/auth"
compute_pb "github.com/microsoft/moc-proto/rpc/cloudagent/compute"
"github.com/microsoft/moc/pkg/auth"
compute_pb "github.com/microsoft/moc/rpc/cloudagent/compute"
)
// GetGalleryImageClient returns the virtual machine client to comminicate with the wssd agent

Просмотреть файл

@ -6,8 +6,8 @@ package client
import (
log "k8s.io/klog"
"github.com/microsoft/moc-proto/pkg/auth"
network_pb "github.com/microsoft/moc-proto/rpc/cloudagent/network"
"github.com/microsoft/moc/pkg/auth"
network_pb "github.com/microsoft/moc/rpc/cloudagent/network"
)
// GetVirtualNetworkClient returns the virtual network client to communicate with the wssdagent

Просмотреть файл

@ -7,8 +7,8 @@ import (
"google.golang.org/grpc"
log "k8s.io/klog"
"github.com/microsoft/moc-proto/pkg/auth"
security_pb "github.com/microsoft/moc-proto/rpc/cloudagent/security"
"github.com/microsoft/moc/pkg/auth"
security_pb "github.com/microsoft/moc/rpc/cloudagent/security"
)
// GetKeyVaultClient returns the keyvault client to communicate with the wssdagent

Просмотреть файл

@ -6,8 +6,8 @@ package client
import (
log "k8s.io/klog"
"github.com/microsoft/moc-proto/pkg/auth"
storage_pb "github.com/microsoft/moc-proto/rpc/cloudagent/storage"
"github.com/microsoft/moc/pkg/auth"
storage_pb "github.com/microsoft/moc/rpc/cloudagent/storage"
)
// GetVirtualHardDiskClient returns the virtual network client to communicate with the wssdagent

Просмотреть файл

@ -5,8 +5,8 @@ package logging
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/admin/logging/internal"
"github.com/microsoft/moc/pkg/auth"
)
// Service interfacetype Service interface {

Просмотреть файл

@ -6,10 +6,10 @@ package internal
import (
"context"
"errors"
"github.com/microsoft/moc-proto/pkg/auth"
loggingHelpers "github.com/microsoft/moc-proto/pkg/logging"
wssdadmin "github.com/microsoft/moc-proto/rpc/cloudagent/admin"
wssdclient "github.com/microsoft/moc-sdk-for-go/pkg/client"
"github.com/microsoft/moc/pkg/auth"
loggingHelpers "github.com/microsoft/moc/pkg/logging"
wssdadmin "github.com/microsoft/moc/rpc/cloudagent/admin"
"io"
"os"
"strconv"

Просмотреть файл

@ -5,8 +5,8 @@ package cluster
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/cloud"
"github.com/microsoft/moc/pkg/auth"
)
type Service interface {

Просмотреть файл

@ -4,10 +4,10 @@
package cluster
import (
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc-proto/pkg/status"
wssdcloud "github.com/microsoft/moc-proto/rpc/cloudagent/cloud"
"github.com/microsoft/moc-sdk-for-go/services/cloud"
"github.com/microsoft/moc/pkg/errors"
"github.com/microsoft/moc/pkg/status"
wssdcloud "github.com/microsoft/moc/rpc/cloudagent/cloud"
)
// Conversion functions from cloud to wssdcloud

Просмотреть файл

@ -6,8 +6,8 @@ package cluster
import (
"testing"
wssdcloud "github.com/microsoft/moc-proto/rpc/cloudagent/cloud"
"github.com/microsoft/moc-sdk-for-go/services/cloud"
wssdcloud "github.com/microsoft/moc/rpc/cloudagent/cloud"
)
var (

Просмотреть файл

@ -8,11 +8,11 @@ import (
"fmt"
"github.com/microsoft/moc-sdk-for-go/services/cloud"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-proto/pkg/errors"
wssdcloud "github.com/microsoft/moc-proto/rpc/cloudagent/cloud"
wssdcloudcommon "github.com/microsoft/moc-proto/rpc/common"
wssdclient "github.com/microsoft/moc-sdk-for-go/pkg/client"
"github.com/microsoft/moc/pkg/auth"
"github.com/microsoft/moc/pkg/errors"
wssdcloud "github.com/microsoft/moc/rpc/cloudagent/cloud"
wssdcloudcommon "github.com/microsoft/moc/rpc/common"
)
type client struct {

Просмотреть файл

@ -5,8 +5,8 @@ package group
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/cloud"
"github.com/microsoft/moc/pkg/auth"
)
type Service interface {

Просмотреть файл

@ -4,11 +4,11 @@
package group
import (
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc/pkg/errors"
"github.com/microsoft/moc-proto/pkg/status"
wssdcloud "github.com/microsoft/moc-proto/rpc/cloudagent/cloud"
"github.com/microsoft/moc-sdk-for-go/services/cloud"
"github.com/microsoft/moc/pkg/status"
wssdcloud "github.com/microsoft/moc/rpc/cloudagent/cloud"
)
// Conversion functions from cloud to wssdcloud

Просмотреть файл

@ -6,8 +6,8 @@ package group
import (
"testing"
wssdcloud "github.com/microsoft/moc-proto/rpc/cloudagent/cloud"
"github.com/microsoft/moc-sdk-for-go/services/cloud"
wssdcloud "github.com/microsoft/moc/rpc/cloudagent/cloud"
)
var (

Просмотреть файл

@ -6,12 +6,12 @@ package group
import (
"context"
"fmt"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/cloud"
"github.com/microsoft/moc/pkg/auth"
wssdcloud "github.com/microsoft/moc-proto/rpc/cloudagent/cloud"
wssdcloudcommon "github.com/microsoft/moc-proto/rpc/common"
wssdcloudclient "github.com/microsoft/moc-sdk-for-go/pkg/client"
wssdcloud "github.com/microsoft/moc/rpc/cloudagent/cloud"
wssdcloudcommon "github.com/microsoft/moc/rpc/common"
)
type client struct {

Просмотреть файл

@ -5,8 +5,8 @@ package kubernetes
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/cloud"
"github.com/microsoft/moc/pkg/auth"
)
// Service interface

Просмотреть файл

@ -4,10 +4,10 @@
package kubernetes
import (
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc-proto/pkg/status"
wssdcloud "github.com/microsoft/moc-proto/rpc/cloudagent/cloud"
"github.com/microsoft/moc-sdk-for-go/services/cloud"
"github.com/microsoft/moc/pkg/errors"
"github.com/microsoft/moc/pkg/status"
wssdcloud "github.com/microsoft/moc/rpc/cloudagent/cloud"
)
// Conversion functions from cloud to wssdcloud

Просмотреть файл

@ -6,8 +6,8 @@ package kubernetes
import (
"testing"
wssdcloud "github.com/microsoft/moc-proto/rpc/cloudagent/cloud"
"github.com/microsoft/moc-sdk-for-go/services/cloud"
wssdcloud "github.com/microsoft/moc/rpc/cloudagent/cloud"
)
var (

Просмотреть файл

@ -6,12 +6,12 @@ package kubernetes
import (
"context"
"fmt"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/cloud"
"github.com/microsoft/moc/pkg/auth"
wssdcloudk8s "github.com/microsoft/moc-proto/rpc/cloudagent/cloud"
wssdcloudcommon "github.com/microsoft/moc-proto/rpc/common"
wssdcloudclient "github.com/microsoft/moc-sdk-for-go/pkg/client"
wssdcloudk8s "github.com/microsoft/moc/rpc/cloudagent/cloud"
wssdcloudcommon "github.com/microsoft/moc/rpc/common"
)
type client struct {

Просмотреть файл

@ -5,8 +5,8 @@ package location
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/cloud"
"github.com/microsoft/moc/pkg/auth"
)
type Service interface {

Просмотреть файл

@ -4,11 +4,11 @@
package location
import (
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc/pkg/errors"
"github.com/microsoft/moc-proto/pkg/status"
wssdcloud "github.com/microsoft/moc-proto/rpc/cloudagent/cloud"
"github.com/microsoft/moc-sdk-for-go/services/cloud"
"github.com/microsoft/moc/pkg/status"
wssdcloud "github.com/microsoft/moc/rpc/cloudagent/cloud"
)
// Conversion functions from cloud to wssdcloud

Просмотреть файл

@ -6,8 +6,8 @@ package location
import (
"testing"
wssdcloud "github.com/microsoft/moc-proto/rpc/cloudagent/cloud"
"github.com/microsoft/moc-sdk-for-go/services/cloud"
wssdcloud "github.com/microsoft/moc/rpc/cloudagent/cloud"
)
var (

Просмотреть файл

@ -6,12 +6,12 @@ package location
import (
"context"
"fmt"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/cloud"
"github.com/microsoft/moc/pkg/auth"
wssdcloud "github.com/microsoft/moc-proto/rpc/cloudagent/cloud"
wssdcloudcommon "github.com/microsoft/moc-proto/rpc/common"
wssdcloudclient "github.com/microsoft/moc-sdk-for-go/pkg/client"
wssdcloud "github.com/microsoft/moc/rpc/cloudagent/cloud"
wssdcloudcommon "github.com/microsoft/moc/rpc/common"
)
type client struct {

Просмотреть файл

@ -5,8 +5,8 @@ package node
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/cloud"
"github.com/microsoft/moc/pkg/auth"
)
type Service interface {

Просмотреть файл

@ -6,10 +6,10 @@ package node
import (
"github.com/microsoft/moc-sdk-for-go/services/cloud"
"github.com/microsoft/moc-proto/pkg/convert"
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc-proto/pkg/status"
wssdcloud "github.com/microsoft/moc-proto/rpc/cloudagent/cloud"
"github.com/microsoft/moc/pkg/convert"
"github.com/microsoft/moc/pkg/errors"
"github.com/microsoft/moc/pkg/status"
wssdcloud "github.com/microsoft/moc/rpc/cloudagent/cloud"
)
// Conversion functions from cloud to wssdcloud

Просмотреть файл

@ -6,8 +6,8 @@ package node
import (
"testing"
wssdcloud "github.com/microsoft/moc-proto/rpc/cloudagent/cloud"
"github.com/microsoft/moc-sdk-for-go/services/cloud"
wssdcloud "github.com/microsoft/moc/rpc/cloudagent/cloud"
)
var (

Просмотреть файл

@ -8,12 +8,12 @@ import (
"fmt"
"github.com/microsoft/moc-sdk-for-go/services/cloud"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc/pkg/auth"
"github.com/microsoft/moc/pkg/errors"
wssdcloud "github.com/microsoft/moc-proto/rpc/cloudagent/cloud"
wssdcloudcommon "github.com/microsoft/moc-proto/rpc/common"
wssdclient "github.com/microsoft/moc-sdk-for-go/pkg/client"
wssdcloud "github.com/microsoft/moc/rpc/cloudagent/cloud"
wssdcloudcommon "github.com/microsoft/moc/rpc/common"
)
type client struct {

Просмотреть файл

@ -5,8 +5,8 @@ package galleryimage
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/compute"
"github.com/microsoft/moc/pkg/auth"
)
// Service interface

Просмотреть файл

@ -5,9 +5,9 @@ package galleryimage
import (
"github.com/microsoft/moc-sdk-for-go/services/compute"
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc-proto/pkg/status"
wssdcloudcompute "github.com/microsoft/moc-proto/rpc/cloudagent/compute"
"github.com/microsoft/moc/pkg/errors"
"github.com/microsoft/moc/pkg/status"
wssdcloudcompute "github.com/microsoft/moc/rpc/cloudagent/compute"
)
// Conversion functions from compute to wssdcloudcompute

Просмотреть файл

@ -6,12 +6,12 @@ package galleryimage
import (
"context"
"fmt"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-proto/pkg/errors"
wssdcloudcompute "github.com/microsoft/moc-proto/rpc/cloudagent/compute"
wssdcloudcommon "github.com/microsoft/moc-proto/rpc/common"
wssdcloudclient "github.com/microsoft/moc-sdk-for-go/pkg/client"
"github.com/microsoft/moc-sdk-for-go/services/compute"
"github.com/microsoft/moc/pkg/auth"
"github.com/microsoft/moc/pkg/errors"
wssdcloudcompute "github.com/microsoft/moc/rpc/cloudagent/compute"
wssdcloudcommon "github.com/microsoft/moc/rpc/common"
)
type client struct {

Просмотреть файл

@ -8,9 +8,9 @@ import (
"log"
"time"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc-sdk-for-go/services/compute"
"github.com/microsoft/moc/pkg/auth"
"github.com/microsoft/moc/pkg/errors"
)
type Service interface {

Просмотреть файл

@ -4,14 +4,14 @@
package virtualmachine
import (
"github.com/microsoft/moc-proto/pkg/convert"
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc/pkg/convert"
"github.com/microsoft/moc/pkg/errors"
"github.com/microsoft/moc-sdk-for-go/services/compute"
"github.com/microsoft/moc-proto/pkg/status"
wssdcloudcompute "github.com/microsoft/moc-proto/rpc/cloudagent/compute"
wssdcommon "github.com/microsoft/moc-proto/rpc/common"
"github.com/microsoft/moc/pkg/status"
wssdcloudcompute "github.com/microsoft/moc/rpc/cloudagent/compute"
wssdcommon "github.com/microsoft/moc/rpc/common"
)
func (c *client) getWssdVirtualMachine(vm *compute.VirtualMachine, group string) (*wssdcloudcompute.VirtualMachine, error) {

Просмотреть файл

@ -6,13 +6,13 @@ package virtualmachine
import (
"context"
"fmt"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/compute"
"github.com/microsoft/moc/pkg/auth"
wssdcloudproto "github.com/microsoft/moc-proto/rpc/common"
wssdcloudproto "github.com/microsoft/moc/rpc/common"
wssdcloudcompute "github.com/microsoft/moc-proto/rpc/cloudagent/compute"
wssdcloudclient "github.com/microsoft/moc-sdk-for-go/pkg/client"
wssdcloudcompute "github.com/microsoft/moc/rpc/cloudagent/compute"
)
type client struct {

Просмотреть файл

@ -5,8 +5,8 @@ package virtualmachineimage
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/compute"
"github.com/microsoft/moc/pkg/auth"
)
// Service interface

Просмотреть файл

@ -5,8 +5,8 @@ package virtualmachineimage
import (
"github.com/microsoft/moc-sdk-for-go/services/compute"
"github.com/microsoft/moc-proto/pkg/errors"
wssdcloudcompute "github.com/microsoft/moc-proto/rpc/cloudagent/compute"
"github.com/microsoft/moc/pkg/errors"
wssdcloudcompute "github.com/microsoft/moc/rpc/cloudagent/compute"
)
// Conversion functions from compute to wssdcloudcompute

Просмотреть файл

@ -6,11 +6,11 @@ package virtualmachineimage
import (
"context"
"fmt"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-proto/pkg/errors"
wssdcloudcompute "github.com/microsoft/moc-proto/rpc/cloudagent/compute"
wssdcloudcommon "github.com/microsoft/moc-proto/rpc/common"
"github.com/microsoft/moc-sdk-for-go/services/compute"
"github.com/microsoft/moc/pkg/auth"
"github.com/microsoft/moc/pkg/errors"
wssdcloudcompute "github.com/microsoft/moc/rpc/cloudagent/compute"
wssdcloudcommon "github.com/microsoft/moc/rpc/common"
)
type client struct {

Просмотреть файл

@ -6,8 +6,8 @@ package virtualmachinescaleset
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/compute"
"github.com/microsoft/moc/pkg/auth"
)
type Service interface {

Просмотреть файл

@ -4,12 +4,12 @@
package virtualmachinescaleset
import (
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc-proto/pkg/status"
wssdcloudcompute "github.com/microsoft/moc-proto/rpc/cloudagent/compute"
wssdcloudnetwork "github.com/microsoft/moc-proto/rpc/cloudagent/network"
wssdcommon "github.com/microsoft/moc-proto/rpc/common"
"github.com/microsoft/moc-sdk-for-go/services/compute"
"github.com/microsoft/moc/pkg/errors"
"github.com/microsoft/moc/pkg/status"
wssdcloudcompute "github.com/microsoft/moc/rpc/cloudagent/compute"
wssdcloudnetwork "github.com/microsoft/moc/rpc/cloudagent/network"
wssdcommon "github.com/microsoft/moc/rpc/common"
)
func (c *client) getVirtualMachineScaleSet(vmss *wssdcloudcompute.VirtualMachineScaleSet, group string) (*compute.VirtualMachineScaleSet, error) {

Просмотреть файл

@ -7,15 +7,15 @@ import (
"context"
"fmt"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc/pkg/auth"
"github.com/microsoft/moc/pkg/errors"
wssdcloudcommon "github.com/microsoft/moc-proto/rpc/common"
wssdcloudcommon "github.com/microsoft/moc/rpc/common"
wssdcloudcompute "github.com/microsoft/moc-proto/rpc/cloudagent/compute"
wssdcloudclient "github.com/microsoft/moc-sdk-for-go/pkg/client"
"github.com/microsoft/moc-sdk-for-go/services/compute"
"github.com/microsoft/moc-sdk-for-go/services/compute/virtualmachine"
wssdcloudcompute "github.com/microsoft/moc/rpc/cloudagent/compute"
)
type client struct {

Просмотреть файл

@ -4,7 +4,7 @@
package compute
import (
cloudcompute "github.com/microsoft/moc-proto/rpc/common"
cloudcompute "github.com/microsoft/moc/rpc/common"
)
func GetCloudSdkVirtualMachineSizeFromCloudVirtualMachineSize(size cloudcompute.VirtualMachineSizeType) VirtualMachineSizeTypes {

Просмотреть файл

@ -6,8 +6,8 @@ package loadbalancer
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/network"
"github.com/microsoft/moc/pkg/auth"
)
// Service interface

Просмотреть файл

@ -10,12 +10,12 @@ import (
"github.com/microsoft/moc-sdk-for-go/services/network"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc-proto/pkg/status"
wssdcloudnetwork "github.com/microsoft/moc-proto/rpc/cloudagent/network"
wssdcloudcommon "github.com/microsoft/moc-proto/rpc/common"
wssdcloudclient "github.com/microsoft/moc-sdk-for-go/pkg/client"
"github.com/microsoft/moc/pkg/auth"
"github.com/microsoft/moc/pkg/errors"
"github.com/microsoft/moc/pkg/status"
wssdcloudnetwork "github.com/microsoft/moc/rpc/cloudagent/network"
wssdcloudcommon "github.com/microsoft/moc/rpc/common"
)
type client struct {

Просмотреть файл

@ -6,8 +6,8 @@ package macpool
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/network"
"github.com/microsoft/moc/pkg/auth"
)
// Service interface

Просмотреть файл

@ -9,12 +9,12 @@ import (
"github.com/microsoft/moc-sdk-for-go/services/network"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc-proto/pkg/status"
wssdcloudnetwork "github.com/microsoft/moc-proto/rpc/cloudagent/network"
wssdcloudcommon "github.com/microsoft/moc-proto/rpc/common"
wssdcloudclient "github.com/microsoft/moc-sdk-for-go/pkg/client"
"github.com/microsoft/moc/pkg/auth"
"github.com/microsoft/moc/pkg/errors"
"github.com/microsoft/moc/pkg/status"
wssdcloudnetwork "github.com/microsoft/moc/rpc/cloudagent/network"
wssdcloudcommon "github.com/microsoft/moc/rpc/common"
)
type client struct {

Просмотреть файл

@ -5,8 +5,8 @@ package networkinterface
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/network"
"github.com/microsoft/moc/pkg/auth"
)
// Service interface

Просмотреть файл

@ -3,11 +3,11 @@
package networkinterface
import (
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc-proto/pkg/status"
wssdcloudnetwork "github.com/microsoft/moc-proto/rpc/cloudagent/network"
wssdcommonproto "github.com/microsoft/moc-proto/rpc/common"
"github.com/microsoft/moc-sdk-for-go/services/network"
"github.com/microsoft/moc/pkg/errors"
"github.com/microsoft/moc/pkg/status"
wssdcloudnetwork "github.com/microsoft/moc/rpc/cloudagent/network"
wssdcommonproto "github.com/microsoft/moc/rpc/common"
)
// Conversion functions from network interface to wssdcloud network interface

Просмотреть файл

@ -6,12 +6,12 @@ package networkinterface
import (
"context"
"fmt"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-proto/pkg/errors"
wssdcloudnetwork "github.com/microsoft/moc-proto/rpc/cloudagent/network"
wssdcloudcommon "github.com/microsoft/moc-proto/rpc/common"
wssdcloudclient "github.com/microsoft/moc-sdk-for-go/pkg/client"
"github.com/microsoft/moc-sdk-for-go/services/network"
"github.com/microsoft/moc/pkg/auth"
"github.com/microsoft/moc/pkg/errors"
wssdcloudnetwork "github.com/microsoft/moc/rpc/cloudagent/network"
wssdcloudcommon "github.com/microsoft/moc/rpc/common"
)
type client struct {

Просмотреть файл

@ -6,8 +6,8 @@ package vippool
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/network"
"github.com/microsoft/moc/pkg/auth"
)
// Service interface

Просмотреть файл

@ -9,12 +9,12 @@ import (
"github.com/microsoft/moc-sdk-for-go/services/network"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc-proto/pkg/status"
wssdcloudnetwork "github.com/microsoft/moc-proto/rpc/cloudagent/network"
wssdcloudcommon "github.com/microsoft/moc-proto/rpc/common"
wssdcloudclient "github.com/microsoft/moc-sdk-for-go/pkg/client"
"github.com/microsoft/moc/pkg/auth"
"github.com/microsoft/moc/pkg/errors"
"github.com/microsoft/moc/pkg/status"
wssdcloudnetwork "github.com/microsoft/moc/rpc/cloudagent/network"
wssdcloudcommon "github.com/microsoft/moc/rpc/common"
)
type client struct {

Просмотреть файл

@ -5,8 +5,8 @@ package virtualnetwork
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/network"
"github.com/microsoft/moc/pkg/auth"
)
// Service interface

Просмотреть файл

@ -3,11 +3,11 @@
package virtualnetwork
import (
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc-proto/pkg/status"
wssdcloudnetwork "github.com/microsoft/moc-proto/rpc/cloudagent/network"
wssdcommonproto "github.com/microsoft/moc-proto/rpc/common"
"github.com/microsoft/moc-sdk-for-go/services/network"
"github.com/microsoft/moc/pkg/errors"
"github.com/microsoft/moc/pkg/status"
wssdcloudnetwork "github.com/microsoft/moc/rpc/cloudagent/network"
wssdcommonproto "github.com/microsoft/moc/rpc/common"
)
// Conversion functions from network to wssdcloudnetwork

Просмотреть файл

@ -6,13 +6,13 @@ package virtualnetwork
import (
"context"
"fmt"
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc-sdk-for-go/services/network"
"github.com/microsoft/moc/pkg/errors"
"github.com/microsoft/moc-proto/pkg/auth"
wssdcloudnetwork "github.com/microsoft/moc-proto/rpc/cloudagent/network"
wssdcloudcommon "github.com/microsoft/moc-proto/rpc/common"
wssdcloudclient "github.com/microsoft/moc-sdk-for-go/pkg/client"
"github.com/microsoft/moc/pkg/auth"
wssdcloudnetwork "github.com/microsoft/moc/rpc/cloudagent/network"
wssdcloudcommon "github.com/microsoft/moc/rpc/common"
)
type client struct {

Просмотреть файл

@ -5,8 +5,8 @@ package authentication
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/security"
"github.com/microsoft/moc/pkg/auth"
)
// Service interface

Просмотреть файл

@ -5,10 +5,10 @@ package authentication
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
wssdsecurity "github.com/microsoft/moc-proto/rpc/cloudagent/security"
wssdclient "github.com/microsoft/moc-sdk-for-go/pkg/client"
"github.com/microsoft/moc-sdk-for-go/services/security"
"github.com/microsoft/moc/pkg/auth"
wssdsecurity "github.com/microsoft/moc/rpc/cloudagent/security"
//log "k8s.io/klog"
)

Просмотреть файл

@ -4,10 +4,10 @@
package certificate
import (
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc-proto/pkg/status"
wssdcloudsecurity "github.com/microsoft/moc-proto/rpc/cloudagent/security"
"github.com/microsoft/moc-sdk-for-go/services/security"
"github.com/microsoft/moc/pkg/errors"
"github.com/microsoft/moc/pkg/status"
wssdcloudsecurity "github.com/microsoft/moc/rpc/cloudagent/security"
)
func getCertificate(cert *wssdcloudsecurity.Certificate) *security.Certificate {

Просмотреть файл

@ -5,8 +5,8 @@ package certificate
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/security"
"github.com/microsoft/moc/pkg/auth"
)
// Service interface

Просмотреть файл

@ -7,10 +7,10 @@ import (
"context"
"fmt"
"github.com/microsoft/moc-proto/pkg/auth"
wssdcloudsecurity "github.com/microsoft/moc-proto/rpc/cloudagent/security"
wssdcloudclient "github.com/microsoft/moc-sdk-for-go/pkg/client"
"github.com/microsoft/moc-sdk-for-go/services/security"
"github.com/microsoft/moc/pkg/auth"
wssdcloudsecurity "github.com/microsoft/moc/rpc/cloudagent/security"
log "k8s.io/klog"
)

Просмотреть файл

@ -6,8 +6,8 @@ package identity
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/security"
"github.com/microsoft/moc/pkg/auth"
)
// Service interface

Просмотреть файл

@ -6,9 +6,9 @@ package identity
import (
"github.com/microsoft/moc-sdk-for-go/services/security"
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc-proto/pkg/status"
wssdcloudsecurity "github.com/microsoft/moc-proto/rpc/cloudagent/security"
"github.com/microsoft/moc/pkg/errors"
"github.com/microsoft/moc/pkg/status"
wssdcloudsecurity "github.com/microsoft/moc/rpc/cloudagent/security"
)
func getIdentity(id *wssdcloudsecurity.Identity) *security.Identity {

Просмотреть файл

@ -7,11 +7,11 @@ import (
"context"
"fmt"
"github.com/microsoft/moc-proto/pkg/auth"
wssdcloudsecurity "github.com/microsoft/moc-proto/rpc/cloudagent/security"
wssdcloudcommon "github.com/microsoft/moc-proto/rpc/common"
wssdcloudclient "github.com/microsoft/moc-sdk-for-go/pkg/client"
"github.com/microsoft/moc-sdk-for-go/services/security"
"github.com/microsoft/moc/pkg/auth"
wssdcloudsecurity "github.com/microsoft/moc/rpc/cloudagent/security"
wssdcloudcommon "github.com/microsoft/moc/rpc/common"
log "k8s.io/klog"
)

Просмотреть файл

@ -5,8 +5,8 @@ package keyvault
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/security"
"github.com/microsoft/moc/pkg/auth"
)
// Service interface

Просмотреть файл

@ -5,9 +5,9 @@ package key
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/security"
"github.com/microsoft/moc-sdk-for-go/services/security/keyvault"
"github.com/microsoft/moc/pkg/auth"
)
// Service interface
@ -38,8 +38,8 @@ func NewKeyClient(cloudFQDN string, authorizer auth.Authorizer) (*KeyClient, err
}
// Get methods invokes the client Get method
func (c *KeyClient) Get(ctx context.Context, group, name, vaultName string) (*[]keyvault.Key, error) {
return c.internal.Get(ctx, group, name, vaultName)
func (c *KeyClient) Get(ctx context.Context, group, vaultName, name string) (*[]keyvault.Key, error) {
return c.internal.Get(ctx, group, vaultName, name)
}
// CreateOrUpdate methods invokes create or update on the client
@ -49,26 +49,26 @@ func (c *KeyClient) CreateOrUpdate(ctx context.Context, group, vaultName, name s
}
// Delete methods invokes delete of the keyvault resource
func (c *KeyClient) Delete(ctx context.Context, group, name, vaultName string) error {
func (c *KeyClient) Delete(ctx context.Context, group, vaultName, name string) error {
return c.internal.Delete(ctx, group, name, vaultName)
}
// Encrypt methods invokes encrypt of the keyvault resource
func (c *KeyClient) Encrypt(ctx context.Context, group, vaultName, name string, parameters *keyvault.KeyOperationsParameters) (result *keyvault.KeyOperationResult, err error) {
return c.internal.Encrypt(ctx, group, name, vaultName, parameters)
return c.internal.Encrypt(ctx, group, vaultName, name, parameters)
}
// Decrypt methods invokes encrypt of the keyvault resource
func (c *KeyClient) Decrypt(ctx context.Context, group, vaultName, name string, parameters *keyvault.KeyOperationsParameters) (result *keyvault.KeyOperationResult, err error) {
return c.internal.Decrypt(ctx, group, name, vaultName, parameters)
return c.internal.Decrypt(ctx, group, vaultName, name, parameters)
}
// WrapKey
func (c *KeyClient) WrapKey(ctx context.Context, group, vaultName, name string, parameters *keyvault.KeyOperationsParameters) (result *keyvault.KeyOperationResult, err error) {
return c.internal.WrapKey(ctx, group, name, vaultName, parameters)
return c.internal.WrapKey(ctx, group, vaultName, name, parameters)
}
// UnwrapKey
func (c *KeyClient) UnwrapKey(ctx context.Context, group, vaultName, name string, parameters *keyvault.KeyOperationsParameters) (result *keyvault.KeyOperationResult, err error) {
return c.internal.UnwrapKey(ctx, group, name, vaultName, parameters)
return c.internal.UnwrapKey(ctx, group, vaultName, name, parameters)
}

Просмотреть файл

@ -4,13 +4,14 @@
package key
import (
"encoding/pem"
"github.com/microsoft/moc-sdk-for-go/services/security/keyvault"
"github.com/microsoft/moc-proto/pkg/convert"
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc-proto/pkg/status"
wssdcloudsecurity "github.com/microsoft/moc-proto/rpc/cloudagent/security"
wssdcloudcommon "github.com/microsoft/moc-proto/rpc/common"
"github.com/microsoft/moc/pkg/convert"
"github.com/microsoft/moc/pkg/errors"
"github.com/microsoft/moc/pkg/status"
wssdcloudsecurity "github.com/microsoft/moc/rpc/cloudagent/security"
wssdcloudcommon "github.com/microsoft/moc/rpc/common"
)
func getKey(sec *wssdcloudsecurity.Key, vaultName string) (keyvault.Key, error) {
@ -18,11 +19,23 @@ func getKey(sec *wssdcloudsecurity.Key, vaultName string) (keyvault.Key, error)
if err != nil {
return keyvault.Key{}, errors.Wrapf(err, "INVESTIAGE")
}
value := ""
switch sec.Type {
case wssdcloudcommon.JsonWebKeyType_RSA:
fallthrough
case wssdcloudcommon.JsonWebKeyType_RSA_HSM:
pubBlk := pem.Block{
Type: "RSA PUBLIC KEY",
Headers: nil,
Bytes: sec.PublicKey,
}
value = string(pem.EncodeToMemory(&pubBlk))
}
return keyvault.Key{
ID: &sec.Id,
Name: &sec.Name,
Version: &sec.Status.Version.Number,
Value: &value,
KeyProperties: &keyvault.KeyProperties{
Statuses: status.GetStatuses(sec.GetStatus()),
KeyType: getKeyType(sec.Type),
@ -31,29 +44,39 @@ func getKey(sec *wssdcloudsecurity.Key, vaultName string) (keyvault.Key, error)
}, nil
}
func getWssdKeyByVaultName(name string, groupName,
vaultName string, opType wssdcloudcommon.Operation) (*wssdcloudsecurity.Key, error) {
key := &wssdcloudsecurity.Key{
Name: name,
VaultName: vaultName,
GroupName: groupName,
Type: wssdcloudcommon.JsonWebKeyType_EC,
Size: wssdcloudcommon.KeySize_K_UNKNOWN,
KeyOps: []wssdcloudcommon.KeyOperation{},
Status: status.InitStatus(),
}
// No Update support
return key, nil
}
func getWssdKey(name string, sec *keyvault.Key,
groupName, vaultName string, opType wssdcloudcommon.Operation) (*wssdcloudsecurity.Key, error) {
keysize, err := getMOCKeySize(*sec.KeySize)
if err != nil {
return nil, err
}
keyops, err := getMOCKeyOperations(sec.KeyOps)
if err != nil {
return nil, err
}
key := &wssdcloudsecurity.Key{
Name: name,
VaultName: vaultName,
GroupName: groupName,
Type: getMOCKeyType(sec.KeyType),
Size: keysize,
KeyOps: keyops,
KeyOps: []wssdcloudcommon.KeyOperation{},
Status: status.InitStatus(),
}
// No Update support
return key, nil
}
@ -69,6 +92,8 @@ func getMOCKeyType(ktype keyvault.JSONWebKeyType) wssdcloudcommon.JsonWebKeyType
return wssdcloudcommon.JsonWebKeyType_RSA
case keyvault.RSAHSM:
return wssdcloudcommon.JsonWebKeyType_RSA_HSM
case keyvault.AES:
return wssdcloudcommon.JsonWebKeyType_AES
default:
return wssdcloudcommon.JsonWebKeyType_EC
}
@ -86,6 +111,8 @@ func getKeyType(ktype wssdcloudcommon.JsonWebKeyType) keyvault.JSONWebKeyType {
return keyvault.RSA
case wssdcloudcommon.JsonWebKeyType_RSA_HSM:
return keyvault.RSAHSM
case wssdcloudcommon.JsonWebKeyType_AES:
return keyvault.AES
default:
return keyvault.EC
}
@ -204,3 +231,17 @@ func getMOCAlgorithm(algo keyvault.JSONWebKeyEncryptionAlgorithm) (wssdcloudcomm
}
return wssdcloudcommon.Algorithm_A_UNKNOWN, errors.Wrapf(errors.InvalidInput, "Invalid Algorithm [%s]", algo)
}
func GetMOCAlgorithmType(algo string) (keyvault.JSONWebKeyEncryptionAlgorithm, error) {
switch algo {
case "RSA1_5":
return keyvault.RSA15, nil
case "RSA-OAEP":
return keyvault.RSAOAEP, nil
case "RSA-OAEP-256":
return keyvault.RSAOAEP256, nil
case "A-256-KW":
return keyvault.A256KW, nil
}
return keyvault.RSA15, errors.Wrapf(errors.InvalidInput, "Invalid Algorithm [%s]", algo)
}

Просмотреть файл

@ -8,11 +8,11 @@ import (
"fmt"
"github.com/microsoft/moc-sdk-for-go/services/security/keyvault"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-proto/pkg/errors"
wssdcloudsecurity "github.com/microsoft/moc-proto/rpc/cloudagent/security"
wssdcloudcommon "github.com/microsoft/moc-proto/rpc/common"
wssdcloudclient "github.com/microsoft/moc-sdk-for-go/pkg/client"
"github.com/microsoft/moc/pkg/auth"
"github.com/microsoft/moc/pkg/errors"
wssdcloudsecurity "github.com/microsoft/moc/rpc/cloudagent/security"
wssdcloudcommon "github.com/microsoft/moc/rpc/common"
)
type client struct {
@ -30,7 +30,7 @@ func newKeyClient(subID string, authorizer auth.Authorizer) (*client, error) {
// Get
func (c *client) Get(ctx context.Context, group, vaultName, name string) (*[]keyvault.Key, error) {
request, err := getKeyRequest(wssdcloudcommon.Operation_GET, group, vaultName, name, nil)
request, err := getKeyRequestByVaultName(wssdcloudcommon.Operation_GET, group, vaultName, name)
if err != nil {
return nil, err
}
@ -43,7 +43,7 @@ func (c *client) Get(ctx context.Context, group, vaultName, name string) (*[]key
// get
func (c *client) get(ctx context.Context, group, vaultName, name string) ([]*wssdcloudsecurity.Key, error) {
request, err := getKeyRequest(wssdcloudcommon.Operation_GET, group, vaultName, name, nil)
request, err := getKeyRequestByVaultName(wssdcloudcommon.Operation_GET, group, vaultName, name)
if err != nil {
return nil, err
}
@ -59,11 +59,13 @@ func (c *client) get(ctx context.Context, group, vaultName, name string) ([]*wss
// CreateOrUpdate
func (c *client) CreateOrUpdate(ctx context.Context, group, vaultName, name string,
param *keyvault.Key) (*keyvault.Key, error) {
err := c.validate(ctx, group, vaultName, name, param)
if err != nil {
return nil, err
}
if param.KeySize == nil {
return nil, errors.Wrapf(errors.InvalidInput, "Invalid KeySize - Missing")
}
request, err := getKeyRequest(wssdcloudcommon.Operation_POST, group, vaultName, name, param)
if err != nil {
return nil, err
@ -81,7 +83,6 @@ func (c *client) CreateOrUpdate(ctx context.Context, group, vaultName, name stri
if len(*sec) == 0 {
return nil, fmt.Errorf("[Key][Create] Unexpected error: Creating a key returned no result")
}
return &((*sec)[0]), err
}
@ -89,9 +90,6 @@ func (c *client) validate(ctx context.Context, group, vaultName, name string, pa
if param == nil {
return errors.Wrapf(errors.InvalidInput, "Invalid Configuration")
}
if len(vaultName) == 0 {
return errors.Wrapf(errors.InvalidInput, "Missing Vault Name")
}
if len(vaultName) == 0 {
errors.Wrapf(errors.InvalidInput, "Keyvault name is missing")
@ -99,9 +97,6 @@ func (c *client) validate(ctx context.Context, group, vaultName, name string, pa
if len(name) == 0 {
errors.Wrapf(errors.InvalidInput, "Keyvault name is missing")
}
if param.KeySize == nil {
errors.Wrapf(errors.InvalidInput, "Invalid KeySize - Missing")
}
return nil
}
@ -189,12 +184,24 @@ func getKeysFromResponse(response *wssdcloudsecurity.KeyResponse, vaultName stri
return &tmp, nil
}
func getKeyRequestByVaultName(opType wssdcloudcommon.Operation, groupName, vaultName, name string) (*wssdcloudsecurity.KeyRequest, error) {
request := &wssdcloudsecurity.KeyRequest{
OperationType: opType,
Keys: []*wssdcloudsecurity.Key{},
}
key, err := getWssdKeyByVaultName(name, groupName, vaultName, opType)
if err != nil {
return nil, err
}
request.Keys = append(request.Keys, key)
return request, nil
}
func getKeyRequest(opType wssdcloudcommon.Operation, groupName, vaultName, name string, param *keyvault.Key) (*wssdcloudsecurity.KeyRequest, error) {
request := &wssdcloudsecurity.KeyRequest{
OperationType: opType,
Keys: []*wssdcloudsecurity.Key{},
}
key, err := getWssdKey(name, param, groupName, vaultName, opType)
if err != nil {
return nil, err

Просмотреть файл

@ -7,10 +7,10 @@ import (
"github.com/Azure/go-autorest/autorest"
"github.com/Azure/go-autorest/autorest/date"
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc-proto/pkg/status"
wssdcloudsecurity "github.com/microsoft/moc-proto/rpc/cloudagent/security"
"github.com/microsoft/moc-sdk-for-go/services/security"
"github.com/microsoft/moc/pkg/errors"
"github.com/microsoft/moc/pkg/status"
wssdcloudsecurity "github.com/microsoft/moc/rpc/cloudagent/security"
)
type SecretProperties struct {
@ -57,6 +57,8 @@ const (
RSA JSONWebKeyType = "RSA"
// RSAHSM RSA with a private key which is not exportable from the HSM.
RSAHSM JSONWebKeyType = "RSA-HSM"
// AES Advanced Encrytion Standard.
AES JSONWebKeyType = "AES"
)
// JSONWebKeyCurveName enumerates the values for json web key curve name.
@ -77,7 +79,7 @@ const (
type KeyProperties struct {
// Exportable - Indicates if the private key can be exported.
Exportable *bool `json:"exportable,omitempty"`
// KeyType - The type of key pair to be used for the certificate. Possible values include: 'EC', 'ECHSM', 'RSA', 'RSAHSM', 'Oct'
// KeyType - The type of key pair to be used for the certificate. Possible values include: 'EC', 'ECHSM', 'RSA', 'RSAHSM', 'Oct', 'AES'
KeyType JSONWebKeyType `json:"kty,omitempty"`
KeyOps *[]JSONWebKeyOperation `json:"key_ops,omitempty"`
// KeySize - The key size in bits. For example: 2048, 3072, or 4096 for RSA.

Просмотреть файл

@ -5,9 +5,9 @@ package secret
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/security"
"github.com/microsoft/moc-sdk-for-go/services/security/keyvault"
"github.com/microsoft/moc/pkg/auth"
)
// Service interface

Просмотреть файл

@ -6,10 +6,10 @@ package secret
import (
"github.com/microsoft/moc-sdk-for-go/services/security/keyvault"
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc-proto/pkg/status"
wssdcloudsecurity "github.com/microsoft/moc-proto/rpc/cloudagent/security"
wssdcloudcommon "github.com/microsoft/moc-proto/rpc/common"
"github.com/microsoft/moc/pkg/errors"
"github.com/microsoft/moc/pkg/status"
wssdcloudsecurity "github.com/microsoft/moc/rpc/cloudagent/security"
wssdcloudcommon "github.com/microsoft/moc/rpc/common"
)
func getSecret(sec *wssdcloudsecurity.Secret, vaultName string) *keyvault.Secret {

Просмотреть файл

@ -8,11 +8,11 @@ import (
"fmt"
"github.com/microsoft/moc-sdk-for-go/services/security/keyvault"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-proto/pkg/errors"
wssdcloudsecurity "github.com/microsoft/moc-proto/rpc/cloudagent/security"
wssdcloudcommon "github.com/microsoft/moc-proto/rpc/common"
wssdcloudclient "github.com/microsoft/moc-sdk-for-go/pkg/client"
"github.com/microsoft/moc/pkg/auth"
"github.com/microsoft/moc/pkg/errors"
wssdcloudsecurity "github.com/microsoft/moc/rpc/cloudagent/security"
wssdcloudcommon "github.com/microsoft/moc/rpc/common"
)
type client struct {

Просмотреть файл

@ -6,12 +6,12 @@ package keyvault
import (
"context"
"fmt"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-proto/pkg/errors"
wssdcloudsecurity "github.com/microsoft/moc-proto/rpc/cloudagent/security"
wssdcloudcommon "github.com/microsoft/moc-proto/rpc/common"
wssdcloudclient "github.com/microsoft/moc-sdk-for-go/pkg/client"
"github.com/microsoft/moc-sdk-for-go/services/security"
"github.com/microsoft/moc/pkg/auth"
"github.com/microsoft/moc/pkg/errors"
wssdcloudsecurity "github.com/microsoft/moc/rpc/cloudagent/security"
wssdcloudcommon "github.com/microsoft/moc/rpc/common"
)
type client struct {

Просмотреть файл

@ -5,8 +5,8 @@ package container
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-sdk-for-go/services/storage"
"github.com/microsoft/moc/pkg/auth"
)
// Service interface

Просмотреть файл

@ -5,9 +5,9 @@ package container
import (
"github.com/microsoft/moc-sdk-for-go/services/storage"
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc-proto/pkg/status"
wssdcloudstorage "github.com/microsoft/moc-proto/rpc/cloudagent/storage"
"github.com/microsoft/moc/pkg/errors"
"github.com/microsoft/moc/pkg/status"
wssdcloudstorage "github.com/microsoft/moc/rpc/cloudagent/storage"
)
// Conversion functions from storage to wssdcloudstorage

Просмотреть файл

@ -6,12 +6,12 @@ package container
import (
"context"
"fmt"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-proto/pkg/errors"
wssdcloudstorage "github.com/microsoft/moc-proto/rpc/cloudagent/storage"
wssdcloudcommon "github.com/microsoft/moc-proto/rpc/common"
wssdcloudclient "github.com/microsoft/moc-sdk-for-go/pkg/client"
"github.com/microsoft/moc-sdk-for-go/services/storage"
"github.com/microsoft/moc/pkg/auth"
"github.com/microsoft/moc/pkg/errors"
wssdcloudstorage "github.com/microsoft/moc/rpc/cloudagent/storage"
wssdcloudcommon "github.com/microsoft/moc/rpc/common"
)
type client struct {

Просмотреть файл

@ -5,9 +5,9 @@ package virtualharddisk
import (
"context"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc-sdk-for-go/services/storage"
"github.com/microsoft/moc/pkg/auth"
"github.com/microsoft/moc/pkg/errors"
)
// Service interface

Просмотреть файл

@ -5,9 +5,9 @@ package virtualharddisk
import (
"github.com/microsoft/moc-sdk-for-go/services/storage"
"github.com/microsoft/moc-proto/pkg/errors"
"github.com/microsoft/moc-proto/pkg/status"
wssdcloudstorage "github.com/microsoft/moc-proto/rpc/cloudagent/storage"
"github.com/microsoft/moc/pkg/errors"
"github.com/microsoft/moc/pkg/status"
wssdcloudstorage "github.com/microsoft/moc/rpc/cloudagent/storage"
)
// Conversion functions from storage to wssdcloudstorage

Просмотреть файл

@ -6,12 +6,12 @@ package virtualharddisk
import (
"context"
"fmt"
"github.com/microsoft/moc-proto/pkg/auth"
"github.com/microsoft/moc-proto/pkg/errors"
wssdcloudstorage "github.com/microsoft/moc-proto/rpc/cloudagent/storage"
wssdcloudcommon "github.com/microsoft/moc-proto/rpc/common"
wssdcloudclient "github.com/microsoft/moc-sdk-for-go/pkg/client"
"github.com/microsoft/moc-sdk-for-go/services/storage"
"github.com/microsoft/moc/pkg/auth"
"github.com/microsoft/moc/pkg/errors"
wssdcloudstorage "github.com/microsoft/moc/rpc/cloudagent/storage"
wssdcloudcommon "github.com/microsoft/moc/rpc/common"
)
type client struct {