restructure rcloud-base as a single base controller (#37)

* restructure rcloud-base as a single base controller
* updated master.rest
* moved sentry from internal to pkg as it is used by relay
* removing unused rpc and it's dependencies
* Fix usermgmt tests
* Don't redefine variables in rest file
Co-authored-by: Abin Simon <abin.simon@rafay.co>
This commit is contained in:
nirav-rafay
2022-03-03 17:59:06 +05:30
committed by GitHub
parent 4ff3d06ef7
commit c66bdc25cd
1176 changed files with 9472 additions and 88767 deletions

View File

@@ -0,0 +1,12 @@
kind: ConfigMap
apiVersion: v1
metadata:
name: example-config
namespace: default
data:
example.property.1: helloss
example.property.2: world
example.property.file: |-
property.1=value-1
property.2=value-2
property.3=value-3

View File

@@ -0,0 +1,17 @@
apiVersion: apiextensions.k8s.io/v1beta1
kind: CustomResourceDefinition
metadata:
name: crontabs.stable.example.com
spec:
group: stable.example.com
versions:
- name: v1
served: true
storage: true
scope: Namespaced
names:
plural: crontabs
singular: crontab
kind: CronTab
shortNames:
- ct

View File

View File

@@ -0,0 +1,21 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: nginx-deployment
labels:
app: nginx
spec:
replicas: 3
selector:
matchLabels:
app: nginx
template:
metadata:
labels:
app: nginx
spec:
containers:
- name: nginx
image: nginx:1.7.9
ports:
- containerPort: 80

View File

@@ -0,0 +1,25 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: nginx-deployment
labels:
app: nginx
annotations:
test: test1
spec:
replicas: 2
selector:
matchLabels:
app: nginx
template:
metadata:
labels:
app: nginx
spec:
containers:
- name: side-car
image: sidecar:latest
- name: nginx
image: nginx:1.7.10
ports:
- containerPort: 80

View File

@@ -0,0 +1,10 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: etcd0
spec:
template:
spec:
containers:
- name: etcd0
image: quay.io/coreos/etcd:v3.4

View File

@@ -0,0 +1,64 @@
apiVersion: apps/v1
kind: Deployment
metadata:
labels:
app: etcd0
etcd_node: etcd0
name: etcd0
spec:
replicas: 1
selector:
matchLabels:
app: etcd0
etcd_node: etcd0
template:
metadata:
labels:
app: etcd0
etcd_node: etcd0
spec:
containers:
- command:
- /usr/local/bin/etcd
- --name
- etcd0
- --initial-advertise-peer-urls
- http://etcd0:2380
- --listen-peer-urls
- http://0.0.0.0:2380
- --listen-client-urls
- http://0.0.0.0:2379
- --advertise-client-urls
- http://etcd0:2379
- --initial-cluster
- etcd0=http://etcd0:2380
- --initial-cluster-state
- new
env:
- name: ETCDCTL_API
value: "3"
image: quay.io/coreos/etcd:v3.3
name: etcd0
ports:
- containerPort: 2379
name: client
protocol: TCP
- containerPort: 2380
name: server
protocol: TCP
resources:
limits:
cpu: 100m
memory: 256Mi
requests:
cpu: 100m
memory: 256Mi
volumeMounts:
- mountPath: /etcd0.etcd
name: etcd-storage
hostname: etcd0
priorityClassName: rafay-cluster-critical
volumes:
- name: etcd-storage
persistentVolumeClaim:
claimName: etcd-pv-claim

View File

View File

@@ -0,0 +1,8 @@
apiVersion: v1
kind: Secret
metadata:
name: mysecret
type: Opaque
data:
username: YWRtaW4=
password: MWYyZDFlMmU2N2Rm

View File

@@ -0,0 +1,15 @@
apiVersion: apps/v1
kind: StatefulSet
metadata:
name: rafay-connector
spec:
template:
spec:
containers:
- name: connector
image: rafaysystems/rafay-connector:latest-1
imagePullSecrets:
- name: rcloud-registry-creds
command:
- test1
- ""

View File

@@ -0,0 +1,29 @@
apiVersion: apps/v1
kind: StatefulSet
metadata:
name: rafay-connector
namespace: rafay-system
spec:
selector:
matchLabels:
app: rafay-connector
serviceName: "connector"
replicas: 1
template:
metadata:
labels:
app: rafay-connector
spec:
priorityClassName: rafay-cluster-critical
terminationGracePeriodSeconds: 10
containers:
- name: connector
image: rafaysystems/rafay-connector:latest
imagePullPolicy: Always
volumeMounts:
- name: connector-config
mountPath: /etc/config
volumes:
- name: connector-config
configMap:
name: connector-config

View File

@@ -0,0 +1,7 @@
apiVersion: "stable.example.com/v1"
kind: CronTab
metadata:
name: my-new-cron-object
spec:
cronSpec: "* * * * */5"
image: my-awesome-cron-image

View File

@@ -0,0 +1,7 @@
apiVersion: "stable.example.com/v1"
kind: CronTab
metadata:
name: my-new-cron-object
spec:
cronSpec: "* * * * */5"
image: my-awesome-cron-image2