Skip to content

Commit

Permalink
Merge pull request #93 from kilosonc/feat/v2.9.0
Browse files Browse the repository at this point in the history
add sql
  • Loading branch information
kilosonc authored Jan 19, 2024
2 parents 2ec88a7 + 686bce9 commit 074bea5
Show file tree
Hide file tree
Showing 3 changed files with 46 additions and 4 deletions.
2 changes: 1 addition & 1 deletion charts/horizon/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ description: A CICD DevOps Platform

type: application

version: 2.2.30
version: 2.2.31
appVersion: v2.9.0
dependencies:
- name: common
Expand Down
19 changes: 19 additions & 0 deletions charts/horizon/files/db-init.sql
Original file line number Diff line number Diff line change
@@ -1,3 +1,22 @@
create table if not exists `tb_badge`
(
id bigint(20) unsigned NOT NULL AUTO_INCREMENT
primary key,
event_id bigint(20) unsigned NOT NULL,
resource_type varchar(64) NOT NULL DEFAULT '' COMMENT 'resource type',
resource_id bigint(20) unsigned NOT NULL COMMENT 'resource id',
`name` varchar(64) NOT NULL DEFAULT '' COMMENT 'badge name',
svg_link varchar(256) NOT NULL DEFAULT '' COMMENT 'badge svg link',
redirect_link varchar(256) NOT NULL DEFAULT '' COMMENT 'badge redirect link',
created_at datetime NOT NULL DEFAULT CURRENT_TIMESTAMP,
updated_at datetime NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
deleted_ts bigint(20) DEFAULT '0' COMMENT 'deleted timestamp, 0 means not deleted',
created_by bigint(20) unsigned NOT NULL DEFAULT '0' COMMENT 'creator',
updated_by bigint(20) unsigned NOT NULL DEFAULT '0' COMMENT 'updater',
constraint uk_resource_name_deletedTs
unique (resource_id, resource_type, `name`, deleted_ts)
);

create table if not exists tb_collection
(
id bigint(20) unsigned NOT NULL AUTO_INCREMENT
Expand Down
29 changes: 26 additions & 3 deletions charts/horizon/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2110,7 +2110,7 @@ web:
replicas: 1
image:
repository: horizoncd/horizon-web
tag: v2.6.1
tag: v2.6.2
securityContext:
runAsUser: 10001
fsGroup: 10001
Expand All @@ -2130,7 +2130,7 @@ nameOverride: ""
fullnameOverride: ""

roles:
RolePriorityRankDesc: [pe, owner, maintainer, tagger, guest]
RolePriorityRankDesc: [pe,owner,maintainer,tagger,guest]
DefaultRole: guest
Roles:
- name: owner
Expand Down Expand Up @@ -2226,6 +2226,7 @@ roles:
- clusters/containers
- clusters/webhooks
- clusters/favorite
- clusters/badges
verbs:
- "*"
scopes:
Expand Down Expand Up @@ -2457,6 +2458,7 @@ roles:
- clusters/accesstokens
- personalaccesstokens
- accesstokens
- clusters/badges
verbs:
- "*"
scopes:
Expand Down Expand Up @@ -2629,6 +2631,7 @@ roles:
- clusters/accesstokens
- personalccesstokens
- accesstokens
- clusters/badges
verbs:
- "*"
scopes:
Expand Down Expand Up @@ -2699,6 +2702,7 @@ roles:
- applications/accesstokens
- clusters/accesstokens
- personalaccesstokens
- clusters/badges
verbs:
- get
scopes:
Expand Down Expand Up @@ -2755,6 +2759,21 @@ scopes:
- applications:read-write
- clusters:read-write
roles:
- name: metatags:read-only
desc: 预置标签的只读权限
rules:
- apiGroups:
- core
resources:
- metatags
- metatagkeys
verbs:
- get
- list
scopes:
- "*"
nonResourceURLs:
- "*"
- name: groups:read-only
desc: 分组(group)及其相关子资源的只读权限
rules:
Expand Down Expand Up @@ -2871,6 +2890,8 @@ scopes:
- clusters/buildstatus
- clusters/step
- clusters/resourcetree
- clusters/templateschematags
- clusters/badges
verbs:
- get
scopes:
Expand Down Expand Up @@ -2925,7 +2946,9 @@ scopes:
- clusters/buildstatus
- clusters/step
- clusters/resourcetree
- clusters/favorite
- clusters/action
- clusters/templateschematags
- clusters/badges
verbs:
- "*"
scopes:
Expand Down

0 comments on commit 074bea5

Please sign in to comment.