From 119413605935dac0013e4ea4bc39719cf6fd3a22 Mon Sep 17 00:00:00 2001 From: Choonho Son Date: Wed, 19 Jun 2024 06:04:57 +0000 Subject: [PATCH] Add v2.x example Signed-off-by: Choonho Son --- example-v2/rbac.yaml | 35 ++ example-v2/values/release-2x.yaml | 515 ++++++++++++++++++++++++++++++ 2 files changed, 550 insertions(+) create mode 100644 example-v2/rbac.yaml create mode 100644 example-v2/values/release-2x.yaml diff --git a/example-v2/rbac.yaml b/example-v2/rbac.yaml new file mode 100644 index 0000000..8de8805 --- /dev/null +++ b/example-v2/rbac.yaml @@ -0,0 +1,35 @@ +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: Role +metadata: + name: supervisor-plugin-control-role + namespace: cloudforet-plugin +rules: +- apiGroups: + - "*" + resources: + - replicaSets + - pods + - deployments + - services + - endpoints + verbs: + - get + - list + - watch + - create + - delete +--- +apiVersion: rbac.authorization.k8s.io/v1 +kind: RoleBinding +metadata: + name: supervisor-role-binding + namespace: cloudforet-plugin +roleRef: + apiGroup: rbac.authorization.k8s.io + kind: Role + name: supervisor-plugin-control-role +subjects: +- kind: ServiceAccount + name: default + namespace: cloudforet diff --git a/example-v2/values/release-2x.yaml b/example-v2/values/release-2x.yaml new file mode 100644 index 0000000..5bb3ceb --- /dev/null +++ b/example-v2/values/release-2x.yaml @@ -0,0 +1,515 @@ +####################################### +# Configuration of spaceone +####################################### +enabled: true +image: + name: alpine + version: 3.3 + +resources: { } +# requests: +# memory: "128Mi" +# cpu: "25m" +# limits: +# memory: "256Mi" +# cpu: "50m" + +# imagePullSecrets: +# - name: + +####################################### +# Configuration of sub-charts +####################################### + +# Service +mongodb: + enabled: true + resources: { } + +redis: + enabled: true + resources: { } + +spacectl: + enabled: true + image: + name: cloudforet/spacectl + version: 2.0.9 + +marketplace-assets: + enabled: false + image: + name: cloudforet/marketplace-assets + version: 1.12.0 + +console: + enable: true + image: + name: cloudforet/console + version: 2.0.dev107 + production_json: + CONSOLE_API: + ENDPOINT: http://127.0.0.1:8081 + CONSOLE_API_V2: + ENDPOINT: http://127.0.0.1:8082 + +console-api: + enable: true + image: + name: cloudforet/console-api + version: 2.0.dev35 + +identity: + enabled: true + image: + name: cloudforet/identity + version: 2.0.dev150 + application_grpc: + DATABASES: + default: + db: v2-identity + read_preference: PRIMARY + + ENDPOINTS: [ ] + INTERNAL_ENDPOINTS: + - service: identity + name: Identity Service + endpoint: grpc://identity:50051 + - service: inventory + name: Inventory Service + endpoint: grpc://inventory:50051 + - service: repository + name: Repository Service + endpoint: grpc://repository:50051 + - service: secret + name: Secret Service + endpoint: grpc://secret:50051 + - service: monitoring + name: Monitoring Service + endpoint: grpc://monitoring:50051 + - service: config + name: Config Service + endpoint: grpc://config:50051 + - service: plugin + name: Plugin Manager + endpoint: grpc://plugin:50051 + - service: statistics + name: Statistics Service + endpoint: grpc://statistics:50051 + - service: notification + name: Notification Service + endpoint: grpc://notification:50051 + - service: cost_analysis + name: Cost Analysis Service + endpoint: grpc://cost-analysis:50051 + - service: board + name: Board Service + endpoint: grpc://board:50051 + - service: file_manager + name: File Manager + endpoint: grpc://file-manager:50051 + - service: dashboard + name: Dashboard Service + endpoint: grpc://dashboard:50051 + +secret: + enabled: true + image: + name: cloudforet/secret + version: 2.0.dev28 + application_grpc: + DATABASES: + default: + db: v2-secret + read_preference: PRIMARY + BACKEND: MongoDBConnector + CONNECTORS: + MongoDBConnector: + host: mongodb + port: 27017 + username: admin + password: password + +repository: + enabled: true + image: + name: cloudforet/repository + version: 2.0.dev45 + + application_grpc: + DATABASES: + default: + db: v2-repository + read_preference: PRIMARY + +plugin: + enabled: true + scheduler: true + worker: true + image: + name: cloudforet/plugin + version: 2.0.dev16 + + application_grpc: + DATABASES: + default: + db: v2-plugin + read_preference: PRIMARY + application_scheduler: + DATABASES: + default: + db: v2-plugin + read_preference: PRIMARY + application_worker: + DATABASES: + default: + db: v2-plugin + read_preference: PRIMARY + +config: + enabled: true + image: + name: cloudforet/config + version: 2.0.dev11 + + application_grpc: + DATABASES: + default: + db: v2-config + read_preference: PRIMARY + +inventory: + enabled: true + scheduler: true + worker: true + image: + name: cloudforet/inventory + version: 2.0.dev208 + + application_grpc: + collect_queue: collector_q + DATABASES: + default: + db: v2-inventory + read_preference: PRIMARY + + application_scheduler: + DATABASES: + default: + db: v2-inventory + read_preference: PRIMARY + + application_worker: + HANDLERS: + authentication: [ ] + authorization: [ ] + mutation: [ ] + DATABASES: + default: + db: v2-inventory + read_preference: PRIMARY + +monitoring: + enabled: true + scheduler: true + worker: true + rest: true + image: + name: cloudforet/monitoring + version: 2.0.dev54 + + application_grpc: + DATABASES: + default: + db: v2-monitoring + read_preference: PRIMARY + INSTALLED_DATA_SOURCE_PLUGINS: + - name: AWS CloudWatch + plugin_info: + plugin_id: plugin-aws-cloudwatch-mon-datasource + provider: aws + - name: Azure Monitor + plugin_info: + plugin_id: plugin-azure-monitor-mon-datasource + provider: azure + - name: Google Cloud Monitoring + plugin_info: + plugin_id: plugin-google-stackdriver-mon-datasource + provider: google_cloud + - name: AWS CloudTrail + plugin_info: + plugin_id: plugin-aws-cloudtrail-mon-datasource + provider: aws + - name: Azure Activity Log + plugin_info: + plugin_id: plugin-azure-activity-log-mon-datasource + provider: azure + + application_scheduler: + DATABASES: + default: + db: v2-monitoring + read_preference: PRIMARY + + application_worker: + DATABASES: + default: + db: v2-monitoring + read_preference: PRIMARY + +statistics: + enabled: true + scheduler: true + worker: true + image: + name: cloudforet/statistics + version: 2.0.dev23 + + application_grpc: + DATABASES: + default: + db: v2-statistics + read_preference: PRIMARY + application_scheduler: + DATABASES: + default: + db: v2-statistics + read_preference: PRIMARY + application_worker: + DATABASES: + default: + db: v2-statistics + read_preference: PRIMARY + +cost-analysis: + enabled: true + scheduler: true + worker: true + replicas_worker: 1 + image: + name: cloudforet/cost-analysis + version: 2.0.dev128 + + application_grpc: + DATABASES: + default: + db: v2-cost-analysis + read_preference: PRIMARY + + application_scheduler: + DATABASES: + default: + db: v2-cost-analysis + read_preference: PRIMARY + + application_worker: + DATABASES: + default: + db: v2-cost-analysis + read_preference: PRIMARY + +notification: + enabled: true + scheduler: true + worker: true + image: + name: cloudforet/notification + version: 2.0.dev27 + + application_grpc: + DEFAULT_QUOTA: + plugin-ms-teams-noti-protocol: + month: -1 + day: -1 + plugin-slack-noti-protocol: + month: -1 + day: -1 + plugin-telegram-noti-protocol: + month: -1 + day: -1 + INSTALLED_PROTOCOL_PLUGINS: + - name: MS Teams + plugin_info: + plugin_id: plugin-ms-teams-noti-protocol + - name: Slack + plugin_info: + plugin_id: slack-notification-protocol + options: { } + schema: slack_webhook + - name: Telegram + plugin_info: + plugin_id: plugin-telegram-noti-protocol + options: { } + schema: telegram_auth_token + DATABASES: + default: + db: v2-notification + read_preference: PRIMARY + application_scheduler: + DATABASES: + default: + db: v2-notification + read_preference: PRIMARY + application_worker: + DEFAULT_QUOTA: + plugin-ms-teams-noti-protocol: + month: -1 + day: -1 + plugin-slack-noti-protocol: + month: -1 + day: -1 + plugin-telegram-noti-protocol: + month: -1 + day: -1 + DATABASES: + default: + db: v2-notification + read_preference: PRIMARY + +board: + enabled: true + image: + name: cloudforet/board + version: 2.0.dev12 + application_grpc: + DATABASES: + default: + db: v2-board + read_preference: PRIMARY + +file-manager: + enabled: true + image: + name: cloudforet/file-manager + version: 2.0.dev18 + application_grpc: + DATABASES: + default: + db: v2-file-manager + read_preference: PRIMARY + +dashboard: + enabled: true + image: + name: cloudforet/dashboard + version: 2.0.dev34 + application_grpc: + DATABASES: + default: + db: v2-dashboard + read_preference: PRIMARY + +console-api-v2: + enabled: true + image: + name: cloudforet/console-api-v2 + version: 2.0.dev133 + +search: + enabled: true + image: + name: cloudforet/search + version: 0.1.dev5 + +supervisor: + enabled: true + image: + name: cloudforet/supervisor + version: 2.0.dev19 + application_scheduler: + NAME: root + HOSTNAME: supervisor.svc.cluster.local + BACKEND: KubernetesConnector + CONNECTORS: + RepositoryConnector: + endpoint: + v1: grpc://repository:50051 + PluginConnector: + endpoint: + v1: grpc://plugin:50051 + KubernetesConnector: + namespace: cloudforet-plugin + start_port: 50051 + end_port: 50052 + headless: true + replica: + inventory.Collector: 1 + monitoring.DataSource: 1 + cost_analysis.DataSource: 1 + + +global: + namespace: cloudforet + supervisor_namespace: cloudforet-plugin + backend: + sidecar: [ ] + volumes: [ ] + frontend: + sidecar: [ ] + volumes: [ ] + + shared_conf: + HANDLERS: + authentication: + - backend: spaceone.core.handler.authentication_handler:SpaceONEAuthenticationHandler + authorization: + - backend: spaceone.core.handler.authorization_handler:SpaceONEAuthorizationHandler + mutation: + - backend: spaceone.core.handler.mutation_handler:SpaceONEMutationHandler + CONNECTORS: + IdentityConnector: + endpoint: + v1: grpc://identity:50051 + SecretConnector: + endpoint: + v1: grpc://secret:50051 + RepositoryConnector: + endpoint: + v1: grpc://repository:50051 + PluginConnector: + endpoint: + v1: grpc://plugin:50051 + ConfigConnector: + endpoint: + v1: grpc://config:50051 + InventoryConnector: + endpoint: + v1: grpc://inventory:50051 + MonitoringConnector: + endpoint: + v1: grpc://monitoring:50051 + StatisticsConnector: + endpoint: + v1: grpc://statistics:50051 + NotificationConnector: + endpoint: + v1: grpc://notification:50051 + SpaceConnector: + endpoints: + identity: grpc://identity:50051 + inventory: grpc://inventory:50051 + repository: grpc://repository:50051 + secret: grpc://secret:50051 + monitoring: grpc://monitoring:50051 + config: grpc://config:50051 + statistics: grpc://statistics:50051 + notification: grpc://notification:50051 + cost_analysis: grpc://cost-analysis:50051 + board: grpc://board:50051 + file_manager: grpc://file-manager:50051 + CACHES: + default: + backend: spaceone.core.cache.redis_cache.RedisCache + host: redis + port: 6379 + db: 0 + encoding: utf-8 + socket_timeout: 10 + socket_connect_timeout: 10 + DATABASES: + default: + username: admin + password: password + host: mongodb + port: 27017 + TOKEN: ""