Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 5 additions & 6 deletions src/images/base/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,8 +1,4 @@
# buster (10) is the last version to support Python 2.
# bullseye (11) although does have a Python 2 interpreter,
# almost *all* Python 2 packages, however, have been removed from bullseye
# and bookworm (12) does not ship Python 2 at all
FROM debian:buster-slim
FROM debian:bullseye-slim

# gcc and python3-dev are necessary to build some wheels
# netbase offer /etc/protocols which is used by `getprotobyname` syscall
Expand All @@ -12,12 +8,15 @@ RUN apt-get update -y \
python3-dev \
netbase \
curl \
libpq-dev \
libpq-dev \
python3 \
python3-pip \
python3-ldap \
libxml2-dev \
libxmlsec1-dev \
xmlsec1 \
pkg-config \
libxmlsec1-openssl \
openssh-client \
inotify-tools \
&& apt-get autoremove -y \
Expand Down
1 change: 1 addition & 0 deletions src/images/base/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -24,3 +24,4 @@ MarkupSafe==0.23 # jinja2 2.11.3 did not pin MarkupSafe versions, will bring bre
paramiko==2.12.0 # FIXME: can we update to 3.x?
pycryptodome==3.6.6
prometheus-client==0.9.0
xmlsec
1 change: 1 addition & 0 deletions src/services/gcp/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ The InfraBox GCP Service can be used to dynamically provision a Kubernetes Clust
"diskSize": 100,
"machineType": "n1-standard-1",
"enableNetworkPolicy": false,
"stackType": "ipv4-ipv6",
"disableLegacyAuthorization": false,
"enablePodSecurityPolicy": true,
"numNodes": 1,
Expand Down
2 changes: 2 additions & 0 deletions src/services/gcp/infrabox-service-gcp/templates/crd.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,8 @@ spec:
type: string
enableManagedPrometheus:
type: boolean
stackType:
type: string
status:
x-kubernetes-preserve-unknown-fields: true
names:
Expand Down
55 changes: 28 additions & 27 deletions src/services/gcp/pkg/apis/gcp/v1alpha1/types.go
Original file line number Diff line number Diff line change
@@ -1,49 +1,50 @@
package v1alpha1

import (
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
)

// +genclient
// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object

type GKECluster struct {
metav1.TypeMeta `json:",inline"`
metav1.ObjectMeta `json:"metadata,omitempty"`
metav1.TypeMeta `json:",inline"`
metav1.ObjectMeta `json:"metadata,omitempty"`

Spec GKEClusterSpec `json:"spec"`
Status GKEClusterStatus `json:"status"`
Spec GKEClusterSpec `json:"spec"`
Status GKEClusterStatus `json:"status"`
}

type GKEClusterSpec struct {
DiskSize int32 `json:"diskSize,omitempty"`
MachineType string `json:"machineType,omitempty"`
EnableNetworkPolicy bool `json:"enableNetworkPolicy,omitempty"`
DisableLegacyAuthorization bool `json:"disableLegacyAuthorization,omitempty"`
EnablePodSecurityPolicy bool `json:"enablePodSecurityPolicy,omitempty"`
NumNodes int32 `json:"numNodes,omitempty"`
Preemptible bool `json:"preemptible,omitempty"`
EnableAutoscaling bool `json:"enableAutoscaling,omitempty"`
MaxNodes int32 `json:"maxNodes,omitempty"`
MinNodes int32 `json:"minNodes,omitempty"`
ClusterVersion string `json:"clusterVersion,omitempty"`
Zone string `json:"zone"`
ServiceCidr string `json:"serviceCidr,omitempty"`
ClusterCidr string `json:"clusterCidr,omitempty"`
EnableManagedPrometheus bool `json:"enableManagedPrometheus,omitempty"`
DiskSize int32 `json:"diskSize,omitempty"`
MachineType string `json:"machineType,omitempty"`
EnableNetworkPolicy bool `json:"enableNetworkPolicy,omitempty"`
StackType string `json:"stackType,omitempty"`
DisableLegacyAuthorization bool `json:"disableLegacyAuthorization,omitempty"`
EnablePodSecurityPolicy bool `json:"enablePodSecurityPolicy,omitempty"`
NumNodes int32 `json:"numNodes,omitempty"`
Preemptible bool `json:"preemptible,omitempty"`
EnableAutoscaling bool `json:"enableAutoscaling,omitempty"`
MaxNodes int32 `json:"maxNodes,omitempty"`
MinNodes int32 `json:"minNodes,omitempty"`
ClusterVersion string `json:"clusterVersion,omitempty"`
Zone string `json:"zone"`
ServiceCidr string `json:"serviceCidr,omitempty"`
ClusterCidr string `json:"clusterCidr,omitempty"`
EnableManagedPrometheus bool `json:"enableManagedPrometheus,omitempty"`
}

type GKEClusterStatus struct {
Status string `json:"status,omitempty"`
Message string `json:"message,omitempty"`
ClusterName string `json:"clusterName,omitempty"`
FirstCleanedAt string `json:"firstCleanedAt,omitempty"`
Status string `json:"status,omitempty"`
Message string `json:"message,omitempty"`
ClusterName string `json:"clusterName,omitempty"`
FirstCleanedAt string `json:"firstCleanedAt,omitempty"`
}

// +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object
type GKEClusterList struct {
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata"`
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata"`

Items []GKECluster `json:"items"`
Items []GKECluster `json:"items"`
}
Loading