init protobuf&grpc for slurm
This commit is contained in:
parent
d77969659e
commit
d757a4ba66
|
@ -1,7 +1,7 @@
|
||||||
package ali
|
package ali
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server"
|
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server"
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/common/tenanter"
|
"code.gitlink.org.cn/JCCE/PCM.git/common/tenanter"
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbpod"
|
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbpod"
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbtenant"
|
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbtenant"
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
package ali
|
package ali
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server"
|
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server"
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/common/tenanter"
|
"code.gitlink.org.cn/JCCE/PCM.git/common/tenanter"
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbpod"
|
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbpod"
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbtenant"
|
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbtenant"
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
package ali
|
package ali
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server"
|
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server"
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbpod"
|
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbpod"
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbtenant"
|
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbtenant"
|
||||||
"github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests"
|
"github.com/aliyun/alibaba-cloud-sdk-go/sdk/requests"
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
package ali
|
package ali
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server"
|
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server"
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/common/tenanter"
|
"code.gitlink.org.cn/JCCE/PCM.git/common/tenanter"
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbpod"
|
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbpod"
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbtenant"
|
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbtenant"
|
||||||
|
|
|
@ -299,7 +299,7 @@ const (
|
||||||
|
|
||||||
// +genclient
|
// +genclient
|
||||||
// +genclient:nonNamespaced
|
// +genclient:nonNamespaced
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// PersistentVolume (PV) is a storage resource provisioned by an administrator.
|
// PersistentVolume (PV) is a storage resource provisioned by an administrator.
|
||||||
// It is analogous to a node.
|
// It is analogous to a node.
|
||||||
|
@ -415,7 +415,7 @@ type PersistentVolumeStatus struct {
|
||||||
Reason string `json:"reason,omitempty" protobuf:"bytes,3,opt,name=reason"`
|
Reason string `json:"reason,omitempty" protobuf:"bytes,3,opt,name=reason"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// PersistentVolumeList is a list of PersistentVolume items.
|
// PersistentVolumeList is a list of PersistentVolume items.
|
||||||
type PersistentVolumeList struct {
|
type PersistentVolumeList struct {
|
||||||
|
@ -430,7 +430,7 @@ type PersistentVolumeList struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
// +genclient
|
// +genclient
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// PersistentVolumeClaim is a user's request for and claim to a persistent volume
|
// PersistentVolumeClaim is a user's request for and claim to a persistent volume
|
||||||
type PersistentVolumeClaim struct {
|
type PersistentVolumeClaim struct {
|
||||||
|
@ -452,7 +452,7 @@ type PersistentVolumeClaim struct {
|
||||||
Status PersistentVolumeClaimStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
Status PersistentVolumeClaimStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// PersistentVolumeClaimList is a list of PersistentVolumeClaim items.
|
// PersistentVolumeClaimList is a list of PersistentVolumeClaim items.
|
||||||
type PersistentVolumeClaimList struct {
|
type PersistentVolumeClaimList struct {
|
||||||
|
@ -3408,7 +3408,8 @@ type PodDNSConfigOption struct {
|
||||||
|
|
||||||
// IP address information for entries in the (plural) PodIPs field.
|
// IP address information for entries in the (plural) PodIPs field.
|
||||||
// Each entry includes:
|
// Each entry includes:
|
||||||
// IP: An IP address allocated to the pod. Routable at least within the cluster.
|
//
|
||||||
|
// IP: An IP address allocated to the pod. Routable at least within the cluster.
|
||||||
type PodIP struct {
|
type PodIP struct {
|
||||||
// ip is an IP address (IPv4 or IPv6) assigned to the pod
|
// ip is an IP address (IPv4 or IPv6) assigned to the pod
|
||||||
IP string `json:"ip,omitempty" protobuf:"bytes,1,opt,name=ip"`
|
IP string `json:"ip,omitempty" protobuf:"bytes,1,opt,name=ip"`
|
||||||
|
@ -3664,7 +3665,7 @@ type PodStatus struct {
|
||||||
EphemeralContainerStatuses []ContainerStatus `json:"ephemeralContainerStatuses,omitempty" protobuf:"bytes,13,rep,name=ephemeralContainerStatuses"`
|
EphemeralContainerStatuses []ContainerStatus `json:"ephemeralContainerStatuses,omitempty" protobuf:"bytes,13,rep,name=ephemeralContainerStatuses"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// PodStatusResult is a wrapper for PodStatus returned by kubelet that can be encode/decoded
|
// PodStatusResult is a wrapper for PodStatus returned by kubelet that can be encode/decoded
|
||||||
type PodStatusResult struct {
|
type PodStatusResult struct {
|
||||||
|
@ -3685,7 +3686,7 @@ type PodStatusResult struct {
|
||||||
// +genclient
|
// +genclient
|
||||||
// +genclient:method=GetEphemeralContainers,verb=get,subresource=ephemeralcontainers,result=EphemeralContainers
|
// +genclient:method=GetEphemeralContainers,verb=get,subresource=ephemeralcontainers,result=EphemeralContainers
|
||||||
// +genclient:method=UpdateEphemeralContainers,verb=update,subresource=ephemeralcontainers,input=EphemeralContainers,result=EphemeralContainers
|
// +genclient:method=UpdateEphemeralContainers,verb=update,subresource=ephemeralcontainers,input=EphemeralContainers,result=EphemeralContainers
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// Pod is a collection of containers that can run on a host. This resource is created
|
// Pod is a collection of containers that can run on a host. This resource is created
|
||||||
// by clients and scheduled onto hosts.
|
// by clients and scheduled onto hosts.
|
||||||
|
@ -3710,7 +3711,7 @@ type Pod struct {
|
||||||
Status PodStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
Status PodStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// PodList is a list of Pods.
|
// PodList is a list of Pods.
|
||||||
type PodList struct {
|
type PodList struct {
|
||||||
|
@ -3739,7 +3740,7 @@ type PodTemplateSpec struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
// +genclient
|
// +genclient
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// PodTemplate describes a template for creating copies of a predefined pod.
|
// PodTemplate describes a template for creating copies of a predefined pod.
|
||||||
type PodTemplate struct {
|
type PodTemplate struct {
|
||||||
|
@ -3755,7 +3756,7 @@ type PodTemplate struct {
|
||||||
Template PodTemplateSpec `json:"template,omitempty" protobuf:"bytes,2,opt,name=template"`
|
Template PodTemplateSpec `json:"template,omitempty" protobuf:"bytes,2,opt,name=template"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// PodTemplateList is a list of PodTemplates.
|
// PodTemplateList is a list of PodTemplates.
|
||||||
type PodTemplateList struct {
|
type PodTemplateList struct {
|
||||||
|
@ -3863,9 +3864,9 @@ type ReplicationControllerCondition struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
// +genclient
|
// +genclient
|
||||||
// +genclient:method=GetScale,verb=get,subresource=scale,result=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/api/autoscaling/v1.Scale
|
// +genclient:method=GetScale,verb=get,subresource=scale,result=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/api/autoscaling/v1.Scale
|
||||||
// +genclient:method=UpdateScale,verb=update,subresource=scale,input=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/api/autoscaling/v1.Scale,result=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/api/autoscaling/v1.Scale
|
// +genclient:method=UpdateScale,verb=update,subresource=scale,input=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/api/autoscaling/v1.Scale,result=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/api/autoscaling/v1.Scale
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// ReplicationController represents the configuration of a replication controller.
|
// ReplicationController represents the configuration of a replication controller.
|
||||||
type ReplicationController struct {
|
type ReplicationController struct {
|
||||||
|
@ -3891,7 +3892,7 @@ type ReplicationController struct {
|
||||||
Status ReplicationControllerStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
Status ReplicationControllerStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// ReplicationControllerList is a collection of replication controllers.
|
// ReplicationControllerList is a collection of replication controllers.
|
||||||
type ReplicationControllerList struct {
|
type ReplicationControllerList struct {
|
||||||
|
@ -4374,7 +4375,7 @@ type ServicePort struct {
|
||||||
|
|
||||||
// +genclient
|
// +genclient
|
||||||
// +genclient:skipVerbs=deleteCollection
|
// +genclient:skipVerbs=deleteCollection
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// Service is a named abstraction of software service (for example, mysql) consisting of local port
|
// Service is a named abstraction of software service (for example, mysql) consisting of local port
|
||||||
// (for example 3306) that the proxy listens on, and the selector that determines which pods
|
// (for example 3306) that the proxy listens on, and the selector that determines which pods
|
||||||
|
@ -4405,7 +4406,7 @@ const (
|
||||||
ClusterIPNone = "None"
|
ClusterIPNone = "None"
|
||||||
)
|
)
|
||||||
|
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// ServiceList holds a list of services.
|
// ServiceList holds a list of services.
|
||||||
type ServiceList struct {
|
type ServiceList struct {
|
||||||
|
@ -4420,8 +4421,8 @@ type ServiceList struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
// +genclient
|
// +genclient
|
||||||
// +genclient:method=CreateToken,verb=create,subresource=token,input=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/api/authentication/v1.TokenRequest,result=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/api/authentication/v1.TokenRequest
|
// +genclient:method=CreateToken,verb=create,subresource=token,input=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/api/authentication/v1.TokenRequest,result=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/api/authentication/v1.TokenRequest
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// ServiceAccount binds together:
|
// ServiceAccount binds together:
|
||||||
// * a name, understood by users, and perhaps by peripheral systems, for an identity
|
// * a name, understood by users, and perhaps by peripheral systems, for an identity
|
||||||
|
@ -4454,7 +4455,7 @@ type ServiceAccount struct {
|
||||||
AutomountServiceAccountToken *bool `json:"automountServiceAccountToken,omitempty" protobuf:"varint,4,opt,name=automountServiceAccountToken"`
|
AutomountServiceAccountToken *bool `json:"automountServiceAccountToken,omitempty" protobuf:"varint,4,opt,name=automountServiceAccountToken"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// ServiceAccountList is a list of ServiceAccount objects
|
// ServiceAccountList is a list of ServiceAccount objects
|
||||||
type ServiceAccountList struct {
|
type ServiceAccountList struct {
|
||||||
|
@ -4470,20 +4471,21 @@ type ServiceAccountList struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
// +genclient
|
// +genclient
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// Endpoints is a collection of endpoints that implement the actual service. Example:
|
// Endpoints is a collection of endpoints that implement the actual service. Example:
|
||||||
// Name: "mysvc",
|
//
|
||||||
// Subsets: [
|
// Name: "mysvc",
|
||||||
// {
|
// Subsets: [
|
||||||
// Addresses: [{"ip": "10.10.1.1"}, {"ip": "10.10.2.2"}],
|
// {
|
||||||
// Ports: [{"name": "a", "port": 8675}, {"name": "b", "port": 309}]
|
// Addresses: [{"ip": "10.10.1.1"}, {"ip": "10.10.2.2"}],
|
||||||
// },
|
// Ports: [{"name": "a", "port": 8675}, {"name": "b", "port": 309}]
|
||||||
// {
|
// },
|
||||||
// Addresses: [{"ip": "10.10.3.3"}],
|
// {
|
||||||
// Ports: [{"name": "a", "port": 93}, {"name": "b", "port": 76}]
|
// Addresses: [{"ip": "10.10.3.3"}],
|
||||||
// },
|
// Ports: [{"name": "a", "port": 93}, {"name": "b", "port": 76}]
|
||||||
// ]
|
// },
|
||||||
|
// ]
|
||||||
type Endpoints struct {
|
type Endpoints struct {
|
||||||
metav1.TypeMeta `json:",inline"`
|
metav1.TypeMeta `json:",inline"`
|
||||||
// Standard object's metadata.
|
// Standard object's metadata.
|
||||||
|
@ -4505,13 +4507,16 @@ type Endpoints struct {
|
||||||
// EndpointSubset is a group of addresses with a common set of ports. The
|
// EndpointSubset is a group of addresses with a common set of ports. The
|
||||||
// expanded set of endpoints is the Cartesian product of Addresses x Ports.
|
// expanded set of endpoints is the Cartesian product of Addresses x Ports.
|
||||||
// For example, given:
|
// For example, given:
|
||||||
// {
|
//
|
||||||
// Addresses: [{"ip": "10.10.1.1"}, {"ip": "10.10.2.2"}],
|
// {
|
||||||
// Ports: [{"name": "a", "port": 8675}, {"name": "b", "port": 309}]
|
// Addresses: [{"ip": "10.10.1.1"}, {"ip": "10.10.2.2"}],
|
||||||
// }
|
// Ports: [{"name": "a", "port": 8675}, {"name": "b", "port": 309}]
|
||||||
|
// }
|
||||||
|
//
|
||||||
// The resulting set of endpoints can be viewed as:
|
// The resulting set of endpoints can be viewed as:
|
||||||
// a: [ 10.10.1.1:8675, 10.10.2.2:8675 ],
|
//
|
||||||
// b: [ 10.10.1.1:309, 10.10.2.2:309 ]
|
// a: [ 10.10.1.1:8675, 10.10.2.2:8675 ],
|
||||||
|
// b: [ 10.10.1.1:309, 10.10.2.2:309 ]
|
||||||
type EndpointSubset struct {
|
type EndpointSubset struct {
|
||||||
// IP addresses which offer the related ports that are marked as ready. These endpoints
|
// IP addresses which offer the related ports that are marked as ready. These endpoints
|
||||||
// should be considered safe for load balancers and clients to utilize.
|
// should be considered safe for load balancers and clients to utilize.
|
||||||
|
@ -4577,7 +4582,7 @@ type EndpointPort struct {
|
||||||
AppProtocol *string `json:"appProtocol,omitempty" protobuf:"bytes,4,opt,name=appProtocol"`
|
AppProtocol *string `json:"appProtocol,omitempty" protobuf:"bytes,4,opt,name=appProtocol"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// EndpointsList is a list of endpoints.
|
// EndpointsList is a list of endpoints.
|
||||||
type EndpointsList struct {
|
type EndpointsList struct {
|
||||||
|
@ -4970,7 +4975,7 @@ type ResourceList map[ResourceName]resource.Quantity
|
||||||
|
|
||||||
// +genclient
|
// +genclient
|
||||||
// +genclient:nonNamespaced
|
// +genclient:nonNamespaced
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// Node is a worker node in Kubernetes.
|
// Node is a worker node in Kubernetes.
|
||||||
// Each node will have a unique identifier in the cache (i.e. in etcd).
|
// Each node will have a unique identifier in the cache (i.e. in etcd).
|
||||||
|
@ -4994,7 +4999,7 @@ type Node struct {
|
||||||
Status NodeStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
Status NodeStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// NodeList is the whole list of all Nodes which have been registered with master.
|
// NodeList is the whole list of all Nodes which have been registered with master.
|
||||||
type NodeList struct {
|
type NodeList struct {
|
||||||
|
@ -5088,7 +5093,7 @@ type NamespaceCondition struct {
|
||||||
// +genclient
|
// +genclient
|
||||||
// +genclient:nonNamespaced
|
// +genclient:nonNamespaced
|
||||||
// +genclient:skipVerbs=deleteCollection
|
// +genclient:skipVerbs=deleteCollection
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// Namespace provides a scope for Names.
|
// Namespace provides a scope for Names.
|
||||||
// Use of multiple namespaces is optional.
|
// Use of multiple namespaces is optional.
|
||||||
|
@ -5110,7 +5115,7 @@ type Namespace struct {
|
||||||
Status NamespaceStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
Status NamespaceStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// NamespaceList is a list of Namespaces.
|
// NamespaceList is a list of Namespaces.
|
||||||
type NamespaceList struct {
|
type NamespaceList struct {
|
||||||
|
@ -5125,7 +5130,7 @@ type NamespaceList struct {
|
||||||
Items []Namespace `json:"items" protobuf:"bytes,2,rep,name=items"`
|
Items []Namespace `json:"items" protobuf:"bytes,2,rep,name=items"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// Binding ties one object to another; for example, a pod is bound to a node by a scheduler.
|
// Binding ties one object to another; for example, a pod is bound to a node by a scheduler.
|
||||||
// Deprecated in 1.7, please use the bindings subresource of pods instead.
|
// Deprecated in 1.7, please use the bindings subresource of pods instead.
|
||||||
|
@ -5140,7 +5145,7 @@ type Binding struct {
|
||||||
Target ObjectReference `json:"target" protobuf:"bytes,2,opt,name=target"`
|
Target ObjectReference `json:"target" protobuf:"bytes,2,opt,name=target"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// A list of ephemeral containers used with the Pod ephemeralcontainers subresource.
|
// A list of ephemeral containers used with the Pod ephemeralcontainers subresource.
|
||||||
type EphemeralContainers struct {
|
type EphemeralContainers struct {
|
||||||
|
@ -5161,11 +5166,11 @@ type EphemeralContainers struct {
|
||||||
type Preconditions struct {
|
type Preconditions struct {
|
||||||
// Specifies the target UID.
|
// Specifies the target UID.
|
||||||
// +optional
|
// +optional
|
||||||
UID *types.UID `json:"uid,omitempty" protobuf:"bytes,1,opt,name=uid,casttype=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/types.UID"`
|
UID *types.UID `json:"uid,omitempty" protobuf:"bytes,1,opt,name=uid,casttype=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/types.UID"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:conversion-gen:explicit-from=net/url.Values
|
// +k8s:conversion-gen:explicit-from=net/url.Values
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// PodLogOptions is the query options for a Pod's logs REST call.
|
// PodLogOptions is the query options for a Pod's logs REST call.
|
||||||
type PodLogOptions struct {
|
type PodLogOptions struct {
|
||||||
|
@ -5217,7 +5222,7 @@ type PodLogOptions struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:conversion-gen:explicit-from=net/url.Values
|
// +k8s:conversion-gen:explicit-from=net/url.Values
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// PodAttachOptions is the query options to a Pod's remote attach call.
|
// PodAttachOptions is the query options to a Pod's remote attach call.
|
||||||
// ---
|
// ---
|
||||||
|
@ -5255,7 +5260,7 @@ type PodAttachOptions struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:conversion-gen:explicit-from=net/url.Values
|
// +k8s:conversion-gen:explicit-from=net/url.Values
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// PodExecOptions is the query options to a Pod's remote exec call.
|
// PodExecOptions is the query options to a Pod's remote exec call.
|
||||||
// ---
|
// ---
|
||||||
|
@ -5294,7 +5299,7 @@ type PodExecOptions struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:conversion-gen:explicit-from=net/url.Values
|
// +k8s:conversion-gen:explicit-from=net/url.Values
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// PodPortForwardOptions is the query options to a Pod's port forward call
|
// PodPortForwardOptions is the query options to a Pod's port forward call
|
||||||
// when using WebSockets.
|
// when using WebSockets.
|
||||||
|
@ -5312,7 +5317,7 @@ type PodPortForwardOptions struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:conversion-gen:explicit-from=net/url.Values
|
// +k8s:conversion-gen:explicit-from=net/url.Values
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// PodProxyOptions is the query options to a Pod's proxy call.
|
// PodProxyOptions is the query options to a Pod's proxy call.
|
||||||
type PodProxyOptions struct {
|
type PodProxyOptions struct {
|
||||||
|
@ -5324,7 +5329,7 @@ type PodProxyOptions struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:conversion-gen:explicit-from=net/url.Values
|
// +k8s:conversion-gen:explicit-from=net/url.Values
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// NodeProxyOptions is the query options to a Node's proxy call.
|
// NodeProxyOptions is the query options to a Node's proxy call.
|
||||||
type NodeProxyOptions struct {
|
type NodeProxyOptions struct {
|
||||||
|
@ -5336,7 +5341,7 @@ type NodeProxyOptions struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:conversion-gen:explicit-from=net/url.Values
|
// +k8s:conversion-gen:explicit-from=net/url.Values
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// ServiceProxyOptions is the query options to a Service's proxy call.
|
// ServiceProxyOptions is the query options to a Service's proxy call.
|
||||||
type ServiceProxyOptions struct {
|
type ServiceProxyOptions struct {
|
||||||
|
@ -5364,9 +5369,10 @@ type ServiceProxyOptions struct {
|
||||||
// and the version of the actual struct is irrelevant.
|
// and the version of the actual struct is irrelevant.
|
||||||
// 5. We cannot easily change it. Because this type is embedded in many locations, updates to this type
|
// 5. We cannot easily change it. Because this type is embedded in many locations, updates to this type
|
||||||
// will affect numerous schemas. Don't make new APIs embed an underspecified API type they do not control.
|
// will affect numerous schemas. Don't make new APIs embed an underspecified API type they do not control.
|
||||||
|
//
|
||||||
// Instead of using this type, create a locally provided and used type that is well-focused on your reference.
|
// Instead of using this type, create a locally provided and used type that is well-focused on your reference.
|
||||||
// For example, ServiceReferences for admission registration: https://github.com/kubernetes/api/blob/release-1.17/admissionregistration/v1/types.go#L533 .
|
// For example, ServiceReferences for admission registration: https://github.com/kubernetes/api/blob/release-1.17/admissionregistration/v1/types.go#L533 .
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
type ObjectReference struct {
|
type ObjectReference struct {
|
||||||
// Kind of the referent.
|
// Kind of the referent.
|
||||||
// More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
|
// More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
|
||||||
|
@ -5383,7 +5389,7 @@ type ObjectReference struct {
|
||||||
// UID of the referent.
|
// UID of the referent.
|
||||||
// More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids
|
// More info: https://kubernetes.io/docs/concepts/overview/working-with-objects/names/#uids
|
||||||
// +optional
|
// +optional
|
||||||
UID types.UID `json:"uid,omitempty" protobuf:"bytes,4,opt,name=uid,casttype=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/types.UID"`
|
UID types.UID `json:"uid,omitempty" protobuf:"bytes,4,opt,name=uid,casttype=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/types.UID"`
|
||||||
// API version of the referent.
|
// API version of the referent.
|
||||||
// +optional
|
// +optional
|
||||||
APIVersion string `json:"apiVersion,omitempty" protobuf:"bytes,5,opt,name=apiVersion"`
|
APIVersion string `json:"apiVersion,omitempty" protobuf:"bytes,5,opt,name=apiVersion"`
|
||||||
|
@ -5428,7 +5434,7 @@ type TypedLocalObjectReference struct {
|
||||||
Name string `json:"name" protobuf:"bytes,3,opt,name=name"`
|
Name string `json:"name" protobuf:"bytes,3,opt,name=name"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// SerializedReference is a reference to serialized object.
|
// SerializedReference is a reference to serialized object.
|
||||||
type SerializedReference struct {
|
type SerializedReference struct {
|
||||||
|
@ -5457,7 +5463,7 @@ const (
|
||||||
)
|
)
|
||||||
|
|
||||||
// +genclient
|
// +genclient
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// Event is a report of an event somewhere in the cluster. Events
|
// Event is a report of an event somewhere in the cluster. Events
|
||||||
// have a limited retention time and triggers and messages may evolve
|
// have a limited retention time and triggers and messages may evolve
|
||||||
|
@ -5541,7 +5547,7 @@ type EventSeries struct {
|
||||||
// +k8s:deprecated=state,protobuf=3
|
// +k8s:deprecated=state,protobuf=3
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// EventList is a list of events.
|
// EventList is a list of events.
|
||||||
type EventList struct {
|
type EventList struct {
|
||||||
|
@ -5555,7 +5561,7 @@ type EventList struct {
|
||||||
Items []Event `json:"items" protobuf:"bytes,2,rep,name=items"`
|
Items []Event `json:"items" protobuf:"bytes,2,rep,name=items"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// List holds a list of objects, which may not be known by the server.
|
// List holds a list of objects, which may not be known by the server.
|
||||||
type List metav1.List
|
type List metav1.List
|
||||||
|
@ -5600,7 +5606,7 @@ type LimitRangeSpec struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
// +genclient
|
// +genclient
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// LimitRange sets resource usage limits for each kind of resource in a Namespace.
|
// LimitRange sets resource usage limits for each kind of resource in a Namespace.
|
||||||
type LimitRange struct {
|
type LimitRange struct {
|
||||||
|
@ -5616,7 +5622,7 @@ type LimitRange struct {
|
||||||
Spec LimitRangeSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
|
Spec LimitRangeSpec `json:"spec,omitempty" protobuf:"bytes,2,opt,name=spec"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// LimitRangeList is a list of LimitRange items.
|
// LimitRangeList is a list of LimitRange items.
|
||||||
type LimitRangeList struct {
|
type LimitRangeList struct {
|
||||||
|
@ -5759,7 +5765,7 @@ type ResourceQuotaStatus struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
// +genclient
|
// +genclient
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// ResourceQuota sets aggregate quota restrictions enforced per namespace
|
// ResourceQuota sets aggregate quota restrictions enforced per namespace
|
||||||
type ResourceQuota struct {
|
type ResourceQuota struct {
|
||||||
|
@ -5780,7 +5786,7 @@ type ResourceQuota struct {
|
||||||
Status ResourceQuotaStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
Status ResourceQuotaStatus `json:"status,omitempty" protobuf:"bytes,3,opt,name=status"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// ResourceQuotaList is a list of ResourceQuota items.
|
// ResourceQuotaList is a list of ResourceQuota items.
|
||||||
type ResourceQuotaList struct {
|
type ResourceQuotaList struct {
|
||||||
|
@ -5796,7 +5802,7 @@ type ResourceQuotaList struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
// +genclient
|
// +genclient
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// Secret holds secret data of a certain type. The total bytes of the values in
|
// Secret holds secret data of a certain type. The total bytes of the values in
|
||||||
// the Data field must be less than MaxSecretSize bytes.
|
// the Data field must be less than MaxSecretSize bytes.
|
||||||
|
@ -5921,7 +5927,7 @@ const (
|
||||||
SecretTypeBootstrapToken SecretType = "bootstrap.kubernetes.io/token"
|
SecretTypeBootstrapToken SecretType = "bootstrap.kubernetes.io/token"
|
||||||
)
|
)
|
||||||
|
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// SecretList is a list of Secret.
|
// SecretList is a list of Secret.
|
||||||
type SecretList struct {
|
type SecretList struct {
|
||||||
|
@ -5937,7 +5943,7 @@ type SecretList struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
// +genclient
|
// +genclient
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// ConfigMap holds configuration data for pods to consume.
|
// ConfigMap holds configuration data for pods to consume.
|
||||||
type ConfigMap struct {
|
type ConfigMap struct {
|
||||||
|
@ -5973,7 +5979,7 @@ type ConfigMap struct {
|
||||||
BinaryData map[string][]byte `json:"binaryData,omitempty" protobuf:"bytes,3,rep,name=binaryData"`
|
BinaryData map[string][]byte `json:"binaryData,omitempty" protobuf:"bytes,3,rep,name=binaryData"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// ConfigMapList is a resource containing a list of ConfigMap objects.
|
// ConfigMapList is a resource containing a list of ConfigMap objects.
|
||||||
type ConfigMapList struct {
|
type ConfigMapList struct {
|
||||||
|
@ -6015,7 +6021,7 @@ type ComponentCondition struct {
|
||||||
|
|
||||||
// +genclient
|
// +genclient
|
||||||
// +genclient:nonNamespaced
|
// +genclient:nonNamespaced
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// ComponentStatus (and ComponentStatusList) holds the cluster validation info.
|
// ComponentStatus (and ComponentStatusList) holds the cluster validation info.
|
||||||
// Deprecated: This API is deprecated in v1.19+
|
// Deprecated: This API is deprecated in v1.19+
|
||||||
|
@ -6033,7 +6039,7 @@ type ComponentStatus struct {
|
||||||
Conditions []ComponentCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,2,rep,name=conditions"`
|
Conditions []ComponentCondition `json:"conditions,omitempty" patchStrategy:"merge" patchMergeKey:"type" protobuf:"bytes,2,rep,name=conditions"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// Status of all the conditions for the component as a list of ComponentStatus objects.
|
// Status of all the conditions for the component as a list of ComponentStatus objects.
|
||||||
// Deprecated: This API is deprecated in v1.19+
|
// Deprecated: This API is deprecated in v1.19+
|
||||||
|
@ -6219,7 +6225,7 @@ type WindowsSecurityContextOptions struct {
|
||||||
RunAsUserName *string `json:"runAsUserName,omitempty" protobuf:"bytes,3,opt,name=runAsUserName"`
|
RunAsUserName *string `json:"runAsUserName,omitempty" protobuf:"bytes,3,opt,name=runAsUserName"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
// +k8s:deepcopy-gen:interfaces=code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/apimachinery/pkg/runtime.Object
|
||||||
|
|
||||||
// RangeAllocation is not a public type.
|
// RangeAllocation is not a public type.
|
||||||
type RangeAllocation struct {
|
type RangeAllocation struct {
|
||||||
|
|
|
@ -21,7 +21,7 @@ package kubernetes
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
corev1 "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/client-go/kubernetes/typed/core/v1"
|
corev1 "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/client-go/kubernetes/typed/core/v1"
|
||||||
discovery "k8s.io/client-go/discovery"
|
discovery "k8s.io/client-go/discovery"
|
||||||
admissionregistrationv1 "k8s.io/client-go/kubernetes/typed/admissionregistration/v1"
|
admissionregistrationv1 "k8s.io/client-go/kubernetes/typed/admissionregistration/v1"
|
||||||
admissionregistrationv1beta1 "k8s.io/client-go/kubernetes/typed/admissionregistration/v1beta1"
|
admissionregistrationv1beta1 "k8s.io/client-go/kubernetes/typed/admissionregistration/v1beta1"
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
package v1
|
package v1
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server"
|
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server"
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/common/tenanter"
|
"code.gitlink.org.cn/JCCE/PCM.git/common/tenanter"
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbpod"
|
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbpod"
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbtenant"
|
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbtenant"
|
||||||
|
@ -15,7 +15,7 @@ import (
|
||||||
"strconv"
|
"strconv"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
v1 "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/api/core/v1"
|
v1 "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/api/core/v1"
|
||||||
types "k8s.io/apimachinery/pkg/types"
|
types "k8s.io/apimachinery/pkg/types"
|
||||||
watch "k8s.io/apimachinery/pkg/watch"
|
watch "k8s.io/apimachinery/pkg/watch"
|
||||||
corev1 "k8s.io/client-go/applyconfigurations/core/v1"
|
corev1 "k8s.io/client-go/applyconfigurations/core/v1"
|
||||||
|
|
|
@ -6,7 +6,7 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"sync"
|
"sync"
|
||||||
|
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/service"
|
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/service"
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/common/tenanter"
|
"code.gitlink.org.cn/JCCE/PCM.git/common/tenanter"
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbpod"
|
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbpod"
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbtenant"
|
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbtenant"
|
||||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -1,7 +1,9 @@
|
||||||
package main
|
package main
|
||||||
|
|
||||||
import "slurm/jobinfo"
|
import (
|
||||||
import "fmt"
|
job_info "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm/jobinfo"
|
||||||
|
"fmt"
|
||||||
|
)
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
job_list := job_info.Get_all_jobs()
|
job_list := job_info.Get_all_jobs()
|
||||||
|
|
|
@ -2,8 +2,8 @@ package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
node_info "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm/nodeinfo"
|
node_info "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm/nodeinfo"
|
||||||
|
"fmt"
|
||||||
)
|
)
|
||||||
import "fmt"
|
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
node_list := node_info.Get_all_nodes()
|
node_list := node_info.Get_all_nodes()
|
||||||
|
|
|
@ -1,7 +1,9 @@
|
||||||
package main
|
package main
|
||||||
|
|
||||||
import "slurm"
|
import (
|
||||||
import "fmt"
|
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm"
|
||||||
|
"fmt"
|
||||||
|
)
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
|
|
||||||
|
|
|
@ -1,12 +1,12 @@
|
||||||
package main
|
package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm"
|
||||||
job_info "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm/jobinfo"
|
job_info "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm/jobinfo"
|
||||||
|
"fmt"
|
||||||
|
"os"
|
||||||
|
"strconv"
|
||||||
)
|
)
|
||||||
import "slurm"
|
|
||||||
import "fmt"
|
|
||||||
import "os"
|
|
||||||
import "strconv"
|
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
|
|
||||||
|
|
|
@ -1,9 +1,11 @@
|
||||||
package main
|
package main
|
||||||
|
|
||||||
import "slurm/nodeinfo"
|
import (
|
||||||
import "slurm"
|
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm"
|
||||||
import "fmt"
|
node_info "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm/nodeinfo"
|
||||||
import "os"
|
"fmt"
|
||||||
|
"os"
|
||||||
|
)
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
if len(os.Args) < 2 {
|
if len(os.Args) < 2 {
|
||||||
|
|
|
@ -1,9 +1,11 @@
|
||||||
package main
|
package main
|
||||||
|
|
||||||
import "slurm/jobinfo"
|
import (
|
||||||
import "slurm"
|
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm"
|
||||||
import "fmt"
|
job_info "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm/jobinfo"
|
||||||
import "os"
|
"fmt"
|
||||||
|
"os"
|
||||||
|
)
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
|
|
||||||
|
|
|
@ -1,110 +0,0 @@
|
||||||
package main
|
|
||||||
|
|
||||||
import (
|
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm"
|
|
||||||
job_info "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm/jobinfo"
|
|
||||||
submit_job "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm/submitjob"
|
|
||||||
"fmt"
|
|
||||||
"os"
|
|
||||||
"os/exec"
|
|
||||||
"os/user"
|
|
||||||
"path/filepath"
|
|
||||||
"strconv"
|
|
||||||
"time"
|
|
||||||
)
|
|
||||||
|
|
||||||
func fileExists(filename string) bool {
|
|
||||||
info, err := os.Stat(filename)
|
|
||||||
if os.IsNotExist(err) {
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
return !info.IsDir()
|
|
||||||
}
|
|
||||||
func build_container(file_name, container_name string) {
|
|
||||||
|
|
||||||
cmd := exec.Command("sudo", "/usr/local/bin/singularity", "build", container_name, file_name)
|
|
||||||
fmt.Print("Now build new container")
|
|
||||||
fmt.Printf("%s\n", cmd.String())
|
|
||||||
stdoutStderr, err := cmd.CombinedOutput()
|
|
||||||
if err != nil {
|
|
||||||
fmt.Printf("error in creating container %s \n", err)
|
|
||||||
|
|
||||||
fmt.Printf("%s\n", stdoutStderr)
|
|
||||||
// return
|
|
||||||
}
|
|
||||||
fmt.Printf("%s\n", stdoutStderr)
|
|
||||||
}
|
|
||||||
|
|
||||||
func main() {
|
|
||||||
job_desc := submit_job.Job_descriptor{}
|
|
||||||
|
|
||||||
dir, _ := os.Getwd()
|
|
||||||
container := filepath.Join(dir, "mpi_container.img")
|
|
||||||
definition := filepath.Join(dir, "mpi_container.def")
|
|
||||||
if !fileExists(container) {
|
|
||||||
build_container(definition, container)
|
|
||||||
}
|
|
||||||
|
|
||||||
if !fileExists(container) {
|
|
||||||
return
|
|
||||||
}
|
|
||||||
/* use Cmd to create our script */
|
|
||||||
|
|
||||||
job_desc.Script = "#!/bin/bash\n export PATH=$PATH:/usr/local/bin\n hostname \n"
|
|
||||||
cmd := exec.Command("/home0/opt/openmpi/bin/mpirun", "-mca btl_tcp_if_include eth1", "/usr/local/bin/singularity", "exec", container, "/opt/mpi_pingpong")
|
|
||||||
job_desc.Script += cmd.String()
|
|
||||||
fmt.Printf("cmd %s\n", job_desc.Script)
|
|
||||||
user, _ := user.Current()
|
|
||||||
userid, _ := strconv.Atoi(user.Uid)
|
|
||||||
job_desc.User_id = uint32(userid)
|
|
||||||
groupid, _ := strconv.Atoi(user.Gid)
|
|
||||||
|
|
||||||
job_desc.Group_id = uint32(groupid)
|
|
||||||
job_desc.Name = "mpi_job"
|
|
||||||
job_desc.Partition = "long"
|
|
||||||
job_desc.Time_limit = uint32(60)
|
|
||||||
job_desc.Min_nodes = uint32(2)
|
|
||||||
job_desc.Num_tasks = uint32(2)
|
|
||||||
job_desc.Std_out = ("./%j-out.txt")
|
|
||||||
job_desc.Std_err = ("./%j-err.txt")
|
|
||||||
job_desc.Work_dir = dir
|
|
||||||
|
|
||||||
answer := submit_job.Submit_job(&job_desc)
|
|
||||||
if answer.Error_code != 0 {
|
|
||||||
msg := slurm.GetErrorString(answer.Error_code)
|
|
||||||
fmt.Printf("Error: %s\n", msg)
|
|
||||||
return
|
|
||||||
}
|
|
||||||
fmt.Printf("Submitted Job %d\n", answer.Job_id)
|
|
||||||
|
|
||||||
job_list := job_info.Get_job(answer.Job_id)
|
|
||||||
if job_list.Error_code != 0 {
|
|
||||||
msg := slurm.GetErrorString(job_list.Error_code)
|
|
||||||
fmt.Printf("Error: %s\n", msg)
|
|
||||||
return
|
|
||||||
|
|
||||||
}
|
|
||||||
job := job_list.Job_list[0]
|
|
||||||
|
|
||||||
fmt.Printf("job %d is %s\n", answer.Job_id, job.Job_stateS)
|
|
||||||
state := job.Job_stateS
|
|
||||||
for state == "Pending" || state == "Running" {
|
|
||||||
time.Sleep(2 * time.Second)
|
|
||||||
job_list = job_info.Get_job(answer.Job_id)
|
|
||||||
if job_list.Error_code != 0 {
|
|
||||||
msg := slurm.GetErrorString(job_list.Error_code)
|
|
||||||
fmt.Printf("Error: %s\n", msg)
|
|
||||||
return
|
|
||||||
|
|
||||||
}
|
|
||||||
job = job_list.Job_list[0]
|
|
||||||
|
|
||||||
state = job.Job_stateS
|
|
||||||
|
|
||||||
fmt.Printf("job %d is %s\n", answer.Job_id, job.Job_stateS)
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
fmt.Printf("Total runtime Job %d: %s\n", job.Job_id, job_info.Get_job_runtime(job).String())
|
|
||||||
|
|
||||||
}
|
|
|
@ -0,0 +1,111 @@
|
||||||
|
package main
|
||||||
|
|
||||||
|
//
|
||||||
|
//import (
|
||||||
|
// "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm"
|
||||||
|
// job_info "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm/jobinfo"
|
||||||
|
// submit_job "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm/submitjob"
|
||||||
|
// "fmt"
|
||||||
|
// "os"
|
||||||
|
// "os/exec"
|
||||||
|
// "os/user"
|
||||||
|
// "path/filepath"
|
||||||
|
// "strconv"
|
||||||
|
// "time"
|
||||||
|
//)
|
||||||
|
//
|
||||||
|
//func fileExists(filename string) bool {
|
||||||
|
// info, err := os.Stat(filename)
|
||||||
|
// if os.IsNotExist(err) {
|
||||||
|
// return false
|
||||||
|
// }
|
||||||
|
// return !info.IsDir()
|
||||||
|
//}
|
||||||
|
//func build_container(file_name, container_name string) {
|
||||||
|
//
|
||||||
|
// cmd := exec.Command("sudo", "/usr/local/bin/singularity", "build", container_name, file_name)
|
||||||
|
// fmt.Print("Now build new container")
|
||||||
|
// fmt.Printf("%s\n", cmd.String())
|
||||||
|
// stdoutStderr, err := cmd.CombinedOutput()
|
||||||
|
// if err != nil {
|
||||||
|
// fmt.Printf("error in creating container %s \n", err)
|
||||||
|
//
|
||||||
|
// fmt.Printf("%s\n", stdoutStderr)
|
||||||
|
// // return
|
||||||
|
// }
|
||||||
|
// fmt.Printf("%s\n", stdoutStderr)
|
||||||
|
//}
|
||||||
|
//
|
||||||
|
//func main() {
|
||||||
|
// job_desc := submit_job.Job_descriptor{}
|
||||||
|
//
|
||||||
|
// dir, _ := os.Getwd()
|
||||||
|
// container := filepath.Join(dir, "mpi_container.img")
|
||||||
|
// definition := filepath.Join(dir, "mpi_container.def")
|
||||||
|
// if !fileExists(container) {
|
||||||
|
// build_container(definition, container)
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// if !fileExists(container) {
|
||||||
|
// return
|
||||||
|
// }
|
||||||
|
// /* use Cmd to create our script */
|
||||||
|
//
|
||||||
|
// job_desc.Script = "#!/bin/bash\n export PATH=$PATH:/usr/local/bin\n hostname \n"
|
||||||
|
// cmd := exec.Command("/home0/opt/openmpi/bin/mpirun", "-mca btl_tcp_if_include eth1", "/usr/local/bin/singularity", "exec", container, "/opt/mpi_pingpong")
|
||||||
|
// job_desc.Script += cmd.String()
|
||||||
|
// fmt.Printf("cmd %s\n", job_desc.Script)
|
||||||
|
// user, _ := user.Current()
|
||||||
|
// userid, _ := strconv.Atoi(user.Uid)
|
||||||
|
// job_desc.User_id = uint32(userid)
|
||||||
|
// groupid, _ := strconv.Atoi(user.Gid)
|
||||||
|
//
|
||||||
|
// job_desc.Group_id = uint32(groupid)
|
||||||
|
// job_desc.Name = "mpi_job"
|
||||||
|
// job_desc.Partition = "long"
|
||||||
|
// job_desc.Time_limit = uint32(60)
|
||||||
|
// job_desc.Min_nodes = uint32(2)
|
||||||
|
// job_desc.Num_tasks = uint32(2)
|
||||||
|
// job_desc.Std_out = ("./%j-out.txt")
|
||||||
|
// job_desc.Std_err = ("./%j-err.txt")
|
||||||
|
// job_desc.Work_dir = dir
|
||||||
|
//
|
||||||
|
// answer := submit_job.Submit_job(&job_desc)
|
||||||
|
// if answer.Error_code != 0 {
|
||||||
|
// msg := slurm.GetErrorString(answer.Error_code)
|
||||||
|
// fmt.Printf("Error: %s\n", msg)
|
||||||
|
// return
|
||||||
|
// }
|
||||||
|
// fmt.Printf("Submitted Job %d\n", answer.Job_id)
|
||||||
|
//
|
||||||
|
// job_list := job_info.Get_job(answer.Job_id)
|
||||||
|
// if job_list.Error_code != 0 {
|
||||||
|
// msg := slurm.GetErrorString(job_list.Error_code)
|
||||||
|
// fmt.Printf("Error: %s\n", msg)
|
||||||
|
// return
|
||||||
|
//
|
||||||
|
// }
|
||||||
|
// job := job_list.Job_list[0]
|
||||||
|
//
|
||||||
|
// fmt.Printf("job %d is %s\n", answer.Job_id, job.Job_stateS)
|
||||||
|
// state := job.Job_stateS
|
||||||
|
// for state == "Pending" || state == "Running" {
|
||||||
|
// time.Sleep(2 * time.Second)
|
||||||
|
// job_list = job_info.Get_job(answer.Job_id)
|
||||||
|
// if job_list.Error_code != 0 {
|
||||||
|
// msg := slurm.GetErrorString(job_list.Error_code)
|
||||||
|
// fmt.Printf("Error: %s\n", msg)
|
||||||
|
// return
|
||||||
|
//
|
||||||
|
// }
|
||||||
|
// job = job_list.Job_list[0]
|
||||||
|
//
|
||||||
|
// state = job.Job_stateS
|
||||||
|
//
|
||||||
|
// fmt.Printf("job %d is %s\n", answer.Job_id, job.Job_stateS)
|
||||||
|
//
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// fmt.Printf("Total runtime Job %d: %s\n", job.Job_id, job_info.Get_job_runtime(job).String())
|
||||||
|
//
|
||||||
|
//}
|
|
@ -1,158 +1,159 @@
|
||||||
package main
|
package main
|
||||||
|
|
||||||
import (
|
//
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm"
|
//import (
|
||||||
job_info "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm/jobinfo"
|
// "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm"
|
||||||
submit_job "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm/submitjob"
|
// job_info "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm/jobinfo"
|
||||||
"fmt"
|
// submit_job "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_slurm/cgo/src/slurm/submitjob"
|
||||||
"os"
|
// "fmt"
|
||||||
"os/exec"
|
// "os"
|
||||||
"os/user"
|
// "os/exec"
|
||||||
"path/filepath"
|
// "os/user"
|
||||||
"strconv"
|
// "path/filepath"
|
||||||
"time"
|
// "strconv"
|
||||||
)
|
// "time"
|
||||||
|
//)
|
||||||
func fileExists(filename string) bool {
|
//
|
||||||
info, err := os.Stat(filename)
|
//func fileExists(filename string) bool {
|
||||||
if os.IsNotExist(err) {
|
// info, err := os.Stat(filename)
|
||||||
return false
|
// if os.IsNotExist(err) {
|
||||||
}
|
// return false
|
||||||
return !info.IsDir()
|
// }
|
||||||
}
|
// return !info.IsDir()
|
||||||
func build_container(file_name, container_name string) {
|
//}
|
||||||
|
//func build_container(file_name, container_name string) {
|
||||||
cmd := exec.Command("sudo", "/usr/local/bin/singularity", "build", container_name, file_name)
|
//
|
||||||
fmt.Print("Now build new container")
|
// cmd := exec.Command("sudo", "/usr/local/bin/singularity", "build", container_name, file_name)
|
||||||
fmt.Printf("%s\n", cmd.String())
|
// fmt.Print("Now build new container")
|
||||||
stdoutStderr, err := cmd.CombinedOutput()
|
// fmt.Printf("%s\n", cmd.String())
|
||||||
if err != nil {
|
// stdoutStderr, err := cmd.CombinedOutput()
|
||||||
fmt.Printf("error in creating container %s \n", err)
|
// if err != nil {
|
||||||
|
// fmt.Printf("error in creating container %s \n", err)
|
||||||
fmt.Printf("%s\n", stdoutStderr)
|
//
|
||||||
// return
|
// fmt.Printf("%s\n", stdoutStderr)
|
||||||
}
|
// // return
|
||||||
fmt.Printf("%s\n", stdoutStderr)
|
// }
|
||||||
}
|
// fmt.Printf("%s\n", stdoutStderr)
|
||||||
|
//}
|
||||||
func main() {
|
//
|
||||||
job_desc := submit_job.Job_descriptor{}
|
//func main() {
|
||||||
|
// job_desc := submit_job.Job_descriptor{}
|
||||||
dir, _ := os.Getwd()
|
//
|
||||||
container := filepath.Join(dir, "openmp_container.img")
|
// dir, _ := os.Getwd()
|
||||||
definition := filepath.Join(dir, "openmp_container.def")
|
// container := filepath.Join(dir, "openmp_container.img")
|
||||||
if !fileExists(container) {
|
// definition := filepath.Join(dir, "openmp_container.def")
|
||||||
build_container(definition, container)
|
// if !fileExists(container) {
|
||||||
}
|
// build_container(definition, container)
|
||||||
|
// }
|
||||||
if !fileExists(container) {
|
//
|
||||||
return
|
// if !fileExists(container) {
|
||||||
}
|
// return
|
||||||
/* use Cmd to create our script */
|
// }
|
||||||
|
// /* use Cmd to create our script */
|
||||||
job_desc.Script = "#!/bin/bash\n export PATH=$PATH:/usr/local/bin\n hostname \n"
|
//
|
||||||
job_desc.Script += "export OMP_NUM_THREADS=$SLURM_JOB_CPUS_PER_NODE\n"
|
// job_desc.Script = "#!/bin/bash\n export PATH=$PATH:/usr/local/bin\n hostname \n"
|
||||||
cmd := exec.Command("/usr/local/bin/singularity", "exec", container, "/opt/openmp_example")
|
// job_desc.Script += "export OMP_NUM_THREADS=$SLURM_JOB_CPUS_PER_NODE\n"
|
||||||
|
// cmd := exec.Command("/usr/local/bin/singularity", "exec", container, "/opt/openmp_example")
|
||||||
job_desc.Script += cmd.String()
|
//
|
||||||
fmt.Printf("cmd %s\n", job_desc.Script)
|
// job_desc.Script += cmd.String()
|
||||||
user, _ := user.Current()
|
// fmt.Printf("cmd %s\n", job_desc.Script)
|
||||||
userid, _ := strconv.Atoi(user.Uid)
|
// user, _ := user.Current()
|
||||||
job_desc.User_id = uint32(userid)
|
// userid, _ := strconv.Atoi(user.Uid)
|
||||||
groupid, _ := strconv.Atoi(user.Gid)
|
// job_desc.User_id = uint32(userid)
|
||||||
|
// groupid, _ := strconv.Atoi(user.Gid)
|
||||||
job_desc.Group_id = uint32(groupid)
|
//
|
||||||
job_desc.Name = "test_job"
|
// job_desc.Group_id = uint32(groupid)
|
||||||
job_desc.Partition = "long"
|
// job_desc.Name = "test_job"
|
||||||
job_desc.Time_limit = uint32(60)
|
// job_desc.Partition = "long"
|
||||||
job_desc.Min_nodes = uint32(1)
|
// job_desc.Time_limit = uint32(60)
|
||||||
job_desc.Num_tasks = uint32(1)
|
// job_desc.Min_nodes = uint32(1)
|
||||||
|
// job_desc.Num_tasks = uint32(1)
|
||||||
job_desc.Cpus_per_task = uint16(2)
|
//
|
||||||
job_desc.Std_out = ("./%j-out.txt")
|
// job_desc.Cpus_per_task = uint16(2)
|
||||||
job_desc.Std_err = ("./%j-err.txt")
|
// job_desc.Std_out = ("./%j-out.txt")
|
||||||
job_desc.Work_dir = dir
|
// job_desc.Std_err = ("./%j-err.txt")
|
||||||
|
// job_desc.Work_dir = dir
|
||||||
answer := submit_job.Submit_job(&job_desc)
|
//
|
||||||
if answer.Error_code != 0 {
|
// answer := submit_job.Submit_job(&job_desc)
|
||||||
msg := slurm.GetErrorString(answer.Error_code)
|
// if answer.Error_code != 0 {
|
||||||
fmt.Printf("Error: %s\n", msg)
|
// msg := slurm.GetErrorString(answer.Error_code)
|
||||||
return
|
// fmt.Printf("Error: %s\n", msg)
|
||||||
}
|
// return
|
||||||
fmt.Printf("Submitted Job %d\n", answer.Job_id)
|
// }
|
||||||
|
// fmt.Printf("Submitted Job %d\n", answer.Job_id)
|
||||||
/*Now, we submit the same jon again, ut with some oversubsciption */
|
//
|
||||||
job_desc.Script = "#!/bin/bash\n export PATH=$PATH:/usr/local/bin\n hostname \n"
|
// /*Now, we submit the same jon again, ut with some oversubsciption */
|
||||||
job_desc.Script += "export OMP_NUM_THREADS=4\n"
|
// job_desc.Script = "#!/bin/bash\n export PATH=$PATH:/usr/local/bin\n hostname \n"
|
||||||
|
// job_desc.Script += "export OMP_NUM_THREADS=4\n"
|
||||||
job_desc.Script += cmd.String()
|
//
|
||||||
fmt.Printf("cmd %s\n", job_desc.Script)
|
// job_desc.Script += cmd.String()
|
||||||
answer2 := submit_job.Submit_job(&job_desc)
|
// fmt.Printf("cmd %s\n", job_desc.Script)
|
||||||
if answer2.Error_code != 0 {
|
// answer2 := submit_job.Submit_job(&job_desc)
|
||||||
msg := slurm.GetErrorString(answer.Error_code)
|
// if answer2.Error_code != 0 {
|
||||||
fmt.Printf("Error: %s\n", msg)
|
// msg := slurm.GetErrorString(answer.Error_code)
|
||||||
return
|
// fmt.Printf("Error: %s\n", msg)
|
||||||
}
|
// return
|
||||||
fmt.Printf("Submitted Job %d\n", answer2.Job_id)
|
// }
|
||||||
|
// fmt.Printf("Submitted Job %d\n", answer2.Job_id)
|
||||||
job_list := job_info.Get_job(answer.Job_id)
|
//
|
||||||
if job_list.Error_code != 0 {
|
// job_list := job_info.Get_job(answer.Job_id)
|
||||||
msg := slurm.GetErrorString(job_list.Error_code)
|
// if job_list.Error_code != 0 {
|
||||||
fmt.Printf("Error: %s\n", msg)
|
// msg := slurm.GetErrorString(job_list.Error_code)
|
||||||
return
|
// fmt.Printf("Error: %s\n", msg)
|
||||||
|
// return
|
||||||
}
|
//
|
||||||
job := job_list.Job_list[0]
|
// }
|
||||||
|
// job := job_list.Job_list[0]
|
||||||
fmt.Printf("job is %s\n", job.Job_stateS)
|
//
|
||||||
state := job.Job_stateS
|
// fmt.Printf("job is %s\n", job.Job_stateS)
|
||||||
for state == "Pending" || state == "Running" {
|
// state := job.Job_stateS
|
||||||
time.Sleep(2 * time.Second)
|
// for state == "Pending" || state == "Running" {
|
||||||
job_list = job_info.Get_job(answer.Job_id)
|
// time.Sleep(2 * time.Second)
|
||||||
if job_list.Error_code != 0 {
|
// job_list = job_info.Get_job(answer.Job_id)
|
||||||
msg := slurm.GetErrorString(job_list.Error_code)
|
// if job_list.Error_code != 0 {
|
||||||
fmt.Printf("Error: %s\n", msg)
|
// msg := slurm.GetErrorString(job_list.Error_code)
|
||||||
return
|
// fmt.Printf("Error: %s\n", msg)
|
||||||
|
// return
|
||||||
}
|
//
|
||||||
job = job_list.Job_list[0]
|
// }
|
||||||
|
// job = job_list.Job_list[0]
|
||||||
state = job.Job_stateS
|
//
|
||||||
|
// state = job.Job_stateS
|
||||||
fmt.Printf("job is %s\n", job.Job_stateS)
|
//
|
||||||
|
// fmt.Printf("job is %s\n", job.Job_stateS)
|
||||||
}
|
//
|
||||||
|
// }
|
||||||
fmt.Printf("Total runtime first job %s\n", job_info.Get_job_runtime(job).String())
|
//
|
||||||
/*wait for second job */
|
// fmt.Printf("Total runtime first job %s\n", job_info.Get_job_runtime(job).String())
|
||||||
job_list = job_info.Get_job(answer2.Job_id)
|
// /*wait for second job */
|
||||||
if job_list.Error_code != 0 {
|
// job_list = job_info.Get_job(answer2.Job_id)
|
||||||
msg := slurm.GetErrorString(job_list.Error_code)
|
// if job_list.Error_code != 0 {
|
||||||
fmt.Printf("Error: %s\n", msg)
|
// msg := slurm.GetErrorString(job_list.Error_code)
|
||||||
return
|
// fmt.Printf("Error: %s\n", msg)
|
||||||
|
// return
|
||||||
}
|
//
|
||||||
job = job_list.Job_list[0]
|
// }
|
||||||
|
// job = job_list.Job_list[0]
|
||||||
fmt.Printf("job is %s\n", job.Job_stateS)
|
//
|
||||||
state = job.Job_stateS
|
// fmt.Printf("job is %s\n", job.Job_stateS)
|
||||||
for state == "Pending" || state == "Running" {
|
// state = job.Job_stateS
|
||||||
time.Sleep(2 * time.Second)
|
// for state == "Pending" || state == "Running" {
|
||||||
job_list = job_info.Get_job(answer2.Job_id)
|
// time.Sleep(2 * time.Second)
|
||||||
if job_list.Error_code != 0 {
|
// job_list = job_info.Get_job(answer2.Job_id)
|
||||||
msg := slurm.GetErrorString(job_list.Error_code)
|
// if job_list.Error_code != 0 {
|
||||||
fmt.Printf("Error: %s\n", msg)
|
// msg := slurm.GetErrorString(job_list.Error_code)
|
||||||
return
|
// fmt.Printf("Error: %s\n", msg)
|
||||||
|
// return
|
||||||
}
|
//
|
||||||
job = job_list.Job_list[0]
|
// }
|
||||||
|
// job = job_list.Job_list[0]
|
||||||
state = job.Job_stateS
|
//
|
||||||
|
// state = job.Job_stateS
|
||||||
fmt.Printf("job is %s\n", job.Job_stateS)
|
//
|
||||||
|
// fmt.Printf("job is %s\n", job.Job_stateS)
|
||||||
}
|
//
|
||||||
|
// }
|
||||||
fmt.Printf("Total runtime second job %s\n", job_info.Get_job_runtime(job).String())
|
//
|
||||||
|
// fmt.Printf("Total runtime second job %s\n", job_info.Get_job_runtime(job).String())
|
||||||
}
|
//
|
||||||
|
//}
|
||||||
|
|
|
@ -4,7 +4,7 @@ import (
|
||||||
"context"
|
"context"
|
||||||
"sync"
|
"sync"
|
||||||
|
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/vm/service/ecser"
|
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_vm/service/ecser"
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/common/tenanter"
|
"code.gitlink.org.cn/JCCE/PCM.git/common/tenanter"
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbecs"
|
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbecs"
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbtenant"
|
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbtenant"
|
||||||
|
@ -12,7 +12,7 @@ import (
|
||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
)
|
)
|
||||||
|
|
||||||
//CreateMultipleEcs 创建多云ECS
|
// CreateMultipleEcs 创建多云ECS
|
||||||
func CreateMultipleEcs(ctx context.Context, reqs *pbecs.CreateEcsMultipleReq) (*pbecs.CreateEcsMultipleResp, error) {
|
func CreateMultipleEcs(ctx context.Context, reqs *pbecs.CreateEcsMultipleReq) (*pbecs.CreateEcsMultipleResp, error) {
|
||||||
var (
|
var (
|
||||||
wg sync.WaitGroup
|
wg sync.WaitGroup
|
||||||
|
@ -110,7 +110,7 @@ func UpdateEcs(ctx context.Context, req *pbecs.UpdateEcsReq) (*pbecs.UpdateEcsRe
|
||||||
return ecs.UpdateEcs(ctx, req)
|
return ecs.UpdateEcs(ctx, req)
|
||||||
}
|
}
|
||||||
|
|
||||||
//ListDetail returns the detail of ecs instances
|
// ListDetail returns the detail of ecs instances
|
||||||
func ListDetail(ctx context.Context, req *pbecs.ListDetailReq) (*pbecs.ListDetailResp, error) {
|
func ListDetail(ctx context.Context, req *pbecs.ListDetailReq) (*pbecs.ListDetailResp, error) {
|
||||||
var (
|
var (
|
||||||
ecs ecser.Ecser
|
ecs ecser.Ecser
|
||||||
|
@ -138,7 +138,7 @@ func ListDetail(ctx context.Context, req *pbecs.ListDetailReq) (*pbecs.ListDetai
|
||||||
return ecs.ListDetail(ctx, req)
|
return ecs.ListDetail(ctx, req)
|
||||||
}
|
}
|
||||||
|
|
||||||
//List returns the list of ecs instances
|
// List returns the list of ecs instances
|
||||||
func List(ctx context.Context, req *pbecs.ListReq) (*pbecs.ListResp, error) {
|
func List(ctx context.Context, req *pbecs.ListReq) (*pbecs.ListResp, error) {
|
||||||
var (
|
var (
|
||||||
wg sync.WaitGroup
|
wg sync.WaitGroup
|
||||||
|
|
|
@ -3,7 +3,7 @@ package server
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/vm/server/ecs"
|
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_vm/server/ecs"
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbecs"
|
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbecs"
|
||||||
|
|
||||||
"github.com/golang/glog"
|
"github.com/golang/glog"
|
||||||
|
@ -61,7 +61,7 @@ func (s *Server) ListEcsDetail(ctx context.Context, req *pbecs.ListDetailReq) (*
|
||||||
return resp, nil
|
return resp, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
//ListEcs return ecs list
|
// ListEcs return ecs list
|
||||||
func (s *Server) ListEcs(ctx context.Context, req *pbecs.ListReq) (*pbecs.ListResp, error) {
|
func (s *Server) ListEcs(ctx context.Context, req *pbecs.ListReq) (*pbecs.ListResp, error) {
|
||||||
resp, err := ecs.List(ctx, req)
|
resp, err := ecs.List(ctx, req)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
package server
|
package server
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server"
|
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server"
|
||||||
"context"
|
"context"
|
||||||
|
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbpod"
|
"code.gitlink.org.cn/JCCE/PCM.git/lan_trans/idl/pbpod"
|
||||||
|
|
|
@ -1,15 +1,19 @@
|
||||||
package main
|
package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
pcm_pod_ali "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/ali"
|
pcm_pod_ali "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/ali"
|
||||||
)
|
)
|
||||||
|
|
||||||
/*****
|
/*
|
||||||
|
****
|
||||||
regionId ali:cn-hangzhou tc:ap-guangzhou hw: cn-east-3
|
regionId ali:cn-hangzhou tc:ap-guangzhou hw: cn-east-3
|
||||||
image: tencent nginx:latest
|
image: tencent nginx:latest
|
||||||
ali registry-vpc.cn-hangzhou.aliyuncs.com/eci_open/nginx
|
|
||||||
huawei library/nginx:stable-alpine-perl
|
ali registry-vpc.cn-hangzhou.aliyuncs.com/eci_open/nginx
|
||||||
*****/
|
huawei library/nginx:stable-alpine-perl
|
||||||
|
|
||||||
|
****
|
||||||
|
*/
|
||||||
func aliCreatePCM() (_err error) {
|
func aliCreatePCM() (_err error) {
|
||||||
request := pcm_pod_ali.CreateCreateContainerGroupRequest()
|
request := pcm_pod_ali.CreateCreateContainerGroupRequest()
|
||||||
|
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
package main
|
package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
corev1 "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/api/core/v1"
|
corev1 "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/api/core/v1"
|
||||||
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/kubernetes/client-go/kubernetes"
|
"code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/kubernetes/client-go/kubernetes"
|
||||||
"context"
|
"context"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/pkg/errors"
|
"github.com/pkg/errors"
|
||||||
|
|
|
@ -1,17 +1,21 @@
|
||||||
package main
|
package main
|
||||||
|
|
||||||
import (
|
import (
|
||||||
pcm_pod_tencent "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pod/server/tencent"
|
pcm_pod_tencent "code.gitlink.org.cn/JCCE/PCM.git/adaptor/pcm_pod/server/tencent"
|
||||||
"fmt"
|
"fmt"
|
||||||
"strconv"
|
"strconv"
|
||||||
)
|
)
|
||||||
|
|
||||||
/*****
|
/*
|
||||||
|
****
|
||||||
regionId tencent:cn-hangzhou tc:ap-guangzhou hw: cn-east-3
|
regionId tencent:cn-hangzhou tc:ap-guangzhou hw: cn-east-3
|
||||||
image: tencent nginx:latest
|
image: tencent nginx:latest
|
||||||
tencent registry-vpc.cn-hangzhou.tencentyuncs.com/eci_open/nginx
|
|
||||||
huawei library/nginx:stable-alpine-perl
|
tencent registry-vpc.cn-hangzhou.tencentyuncs.com/eci_open/nginx
|
||||||
*****/
|
huawei library/nginx:stable-alpine-perl
|
||||||
|
|
||||||
|
****
|
||||||
|
*/
|
||||||
func tencentCreatePCM() (_err error) {
|
func tencentCreatePCM() (_err error) {
|
||||||
request := pcm_pod_tencent.NewCreateEKSContainerInstancesRequest()
|
request := pcm_pod_tencent.NewCreateEKSContainerInstancesRequest()
|
||||||
|
|
||||||
|
|
2
go.mod
2
go.mod
|
@ -1,6 +1,6 @@
|
||||||
module code.gitlink.org.cn/JCCE/PCM.git
|
module code.gitlink.org.cn/JCCE/PCM.git
|
||||||
|
|
||||||
go 1.17
|
go 1.19
|
||||||
|
|
||||||
require (
|
require (
|
||||||
github.com/alibabacloud-go/darabonba-openapi v0.1.4
|
github.com/alibabacloud-go/darabonba-openapi v0.1.4
|
||||||
|
|
|
@ -0,0 +1,31 @@
|
||||||
|
syntax = "proto3";
|
||||||
|
package demo;
|
||||||
|
|
||||||
|
option go_package = "code.gitlink.org.cn/JCCE/PCM.git/lan_trans/gen/idl/slurm";
|
||||||
|
|
||||||
|
import "google/api/annotations.proto";
|
||||||
|
import "protoc-gen-openapiv2/options/annotations.proto";
|
||||||
|
|
||||||
|
message GetNodesReq{}
|
||||||
|
|
||||||
|
|
||||||
|
message GetNodesResp {
|
||||||
|
int32 boards = 1 ;
|
||||||
|
int32 cpus = 2 ;
|
||||||
|
string name = 3 ;
|
||||||
|
int32 realMemory = 4 ;
|
||||||
|
int32 sockets = 5 ;
|
||||||
|
int32 threads = 6 ;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Slurm Services
|
||||||
|
service SlurmService {
|
||||||
|
|
||||||
|
// Echo 样例接口
|
||||||
|
rpc GetNodes(GetNodesReq) returns (GetNodesResp) {
|
||||||
|
option (google.api.http) = {
|
||||||
|
post : "/apis/ecs/createMultiple"
|
||||||
|
body : "*"
|
||||||
|
};
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue