Skip to content

Commit

Permalink
Merge pull request #482 from appuio/uro-update
Browse files Browse the repository at this point in the history
Add missing templates for the new URO 2.0
  • Loading branch information
psy-q authored Jun 21, 2023
2 parents 12ff7d5 + b6f69a0 commit 9970786
Show file tree
Hide file tree
Showing 10 changed files with 264 additions and 166 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ helm repo add appuio https://charts.appuio.ch
| [![chart downloads](https://img.shields.io/github/downloads/appuio/charts/signalilo-0.12.0/total)](https://github.com/appuio/charts/releases/tag/signalilo-0.12.0) | [signalilo](appuio/signalilo/README.md) |
| [![chart downloads](https://img.shields.io/github/downloads/appuio/charts/snappass-1.0.0/total)](https://github.com/appuio/charts/releases/tag/snappass-1.0.0) | [snappass](appuio/snappass/README.md) |
| [![chart downloads](https://img.shields.io/github/downloads/appuio/charts/stardog-0.18.1/total)](https://github.com/appuio/charts/releases/tag/stardog-0.18.1) | [stardog](appuio/stardog/README.md) |
| [![chart downloads](https://img.shields.io/github/downloads/appuio/charts/stardog-userrole-operator-0.2.1/total)](https://github.com/appuio/charts/releases/tag/stardog-userrole-operator-0.2.1) | [stardog-userrole-operator](appuio/stardog-userrole-operator/README.md) |
| [![chart downloads](https://img.shields.io/github/downloads/appuio/charts/stardog-userrole-operator-0.2.2/total)](https://github.com/appuio/charts/releases/tag/stardog-userrole-operator-0.2.2) | [stardog-userrole-operator](appuio/stardog-userrole-operator/README.md) |
| [![chart downloads](https://img.shields.io/github/downloads/appuio/charts/trifid-2.0.1/total)](https://github.com/appuio/charts/releases/tag/trifid-2.0.1) | [trifid](appuio/trifid/README.md) |

## Add / Update Charts
Expand Down
4 changes: 2 additions & 2 deletions appuio/stardog-userrole-operator/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
apiVersion: v1
name: stardog-userrole-operator
version: 0.2.1
appVersion: 0.2.1
version: 0.2.2
appVersion: 0.2.2
description: Stardog User and Role Operator
sources:
- https://github.com/vshn/stardog-userrole-operator
Expand Down
4 changes: 2 additions & 2 deletions appuio/stardog-userrole-operator/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# stardog-userrole-operator

![Version: 0.2.1](https://img.shields.io/badge/Version-0.2.1-informational?style=flat-square) ![AppVersion: 0.2.1](https://img.shields.io/badge/AppVersion-0.2.1-informational?style=flat-square)
![Version: 0.2.2](https://img.shields.io/badge/Version-0.2.2-informational?style=flat-square) ![AppVersion: 0.2.2](https://img.shields.io/badge/AppVersion-0.2.2-informational?style=flat-square)

Stardog User and Role Operator

Expand All @@ -27,7 +27,7 @@ Edit the README.gotmpl.md template instead.
| image.pullPolicy | string | `"Always"` | |
| image.registry | string | `"ghcr.io"` | |
| image.repository | string | `"vshn/stardog-userrole-operator"` | |
| image.tag | string | `"v0.2.1"` | |
| image.tag | string | `"v0.2.2"` | |
| imagePullSecrets | list | `[]` | |
| leaderElection.enabled | bool | `false` | Enable leader election for multiple replicas |
| metrics.proxy.enabled | bool | `false` | Enable metrics via service behind a authenticated proxy |
Expand Down
109 changes: 109 additions & 0 deletions appuio/stardog-userrole-operator/crd/databases.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,109 @@
---
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.9.0
creationTimestamp: null
name: databases.stardog.vshn.ch
spec:
group: stardog.vshn.ch
names:
kind: Database
listKind: DatabaseList
plural: databases
singular: database
scope: Cluster
versions:
- name: v1beta1
schema:
openAPIV3Schema:
description: Database is the Schema for the databases API
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation
of an object. Servers should convert recognized schemas to the latest
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
type: string
kind:
description: 'Kind is a string value representing the REST resource this
object represents. Servers may infer this from the endpoint the client
submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
type: string
metadata:
type: object
spec:
description: DatabaseSpec defines the desired state of the Database
properties:
databaseName:
description: DatabaseName the database name that has to be created
in the Stardog server
type: string
namedGraphPrefix:
description: NamedGraphPrefix a prefix for a Stardog Named Graph.
type: string
options:
description: Options is the Stardog configuration options for this
database. Only json input is valid.
type: string
stardogInstanceRefs:
description: StardogInstanceRefs contains the reference to the Stardog
instance the database should exist in
items:
description: StardogInstanceRef contains name and namespace for
a stardog instance
properties:
name:
type: string
namespace:
type: string
type: object
type: array
type: object
status:
description: DatabaseStatus defines the observed state of the Database
properties:
conditions:
items:
description: StardogCondition describes a status condition of a
StardogRole
properties:
lastTransitionTime:
format: date-time
type: string
message:
type: string
reason:
type: string
status:
type: string
type:
type: string
required:
- status
- type
type: object
type: array
databaseName:
type: string
namedGraphPrefix:
type: string
options:
type: string
stardogInstanceRef:
items:
description: StardogInstanceRef contains name and namespace for
a stardog instance
properties:
name:
type: string
namespace:
type: string
type: object
type: array
type: object
type: object
served: true
storage: true
subresources:
status: {}
106 changes: 106 additions & 0 deletions appuio/stardog-userrole-operator/crd/organizations.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,106 @@
---
apiVersion: apiextensions.k8s.io/v1
kind: CustomResourceDefinition
metadata:
annotations:
controller-gen.kubebuilder.io/version: v0.9.0
creationTimestamp: null
name: organizations.stardog.vshn.ch
spec:
group: stardog.vshn.ch
names:
kind: Organization
listKind: OrganizationList
plural: organizations
singular: organization
scope: Cluster
versions:
- name: v1beta1
schema:
openAPIV3Schema:
description: Organization is the Schema for the organizations API
properties:
apiVersion:
description: 'APIVersion defines the versioned schema of this representation
of an object. Servers should convert recognized schemas to the latest
internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources'
type: string
kind:
description: 'Kind is a string value representing the REST resource this
object represents. Servers may infer this from the endpoint the client
submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds'
type: string
metadata:
type: object
spec:
description: OrganizationSpec defines the desired state of an Organization
properties:
databaseRef:
description: DatabaseRef is the name of the Database this Organization
is assigned to
type: string
displayName:
description: DisplayName is the long name of an organization
type: string
name:
description: Name is the short name of an organization
type: string
namedGraphs:
description: NamedGraphs are the suffix graph names for this organization.
The prefix can be found in the Database resource. The final graphs
is defined as prefix + "/" + orgName + "/" suffix
items:
type: string
type: array
type: object
status:
description: OrganizationStatus defines the observed state of the Organization
properties:
conditions:
items:
description: StardogCondition describes a status condition of a
StardogRole
properties:
lastTransitionTime:
format: date-time
type: string
message:
type: string
reason:
type: string
status:
type: string
type:
type: string
required:
- status
- type
type: object
type: array
databaseRef:
type: string
displayName:
type: string
name:
type: string
namedGraphs:
items:
type: string
type: array
stardogInstanceRefs:
items:
description: StardogInstanceRef contains name and namespace for
a stardog instance
properties:
name:
type: string
namespace:
type: string
type: object
type: array
type: object
type: object
served: true
storage: true
subresources:
status: {}
40 changes: 40 additions & 0 deletions appuio/stardog-userrole-operator/templates/clusterrole.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,46 @@ metadata:
labels:
{{ include "stardog-userrole-operator.labels" . | indent 4 }}
rules:
- apiGroups:
- stardog.vshn.ch
resources:
- databases
verbs:
- create
- delete
- get
- list
- patch
- update
- watch
- apiGroups:
- stardog.vshn.ch
resources:
- databases/status
verbs:
- get
- patch
- update
- apiGroups:
- stardog.vshn.ch
resources:
- organizations
verbs:
- create
- delete
- get
- list
- patch
- update
- watch
- apiGroups:
- stardog.vshn.ch
resources:
- organizations/status
verbs:
- get
- patch
- update
- apiGroups:
- stardog.vshn.ch
resources:
Expand Down
4 changes: 2 additions & 2 deletions appuio/stardog-userrole-operator/test/deployment_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ func Test_Deployment_ShouldRender_ImagePullSecrets(t *testing.T) {
}

func Test_Deployment_ShouldRender_CorrectImage(t *testing.T) {
expectedImage := "ghcr.io/vshn/stardog-userrole-operator:v0.2.1"
expectedImage := "ghcr.io/vshn/stardog-userrole-operator:v0.2.2"
options := &helm.Options{}

got := renderDeployment(t, options, false)
Expand All @@ -83,7 +83,7 @@ func Test_Deployment_ShouldRender_CorrectImage(t *testing.T) {
}

func Test_Deployment_WhenProxyEnabled_ThenEnableRBACContainer(t *testing.T) {
expectedBaseImage := "ghcr.io/vshn/stardog-userrole-operator:v0.2.1"
expectedBaseImage := "ghcr.io/vshn/stardog-userrole-operator:v0.2.2"
expectedProxyImage := "gcr.io/kubebuilder/kube-rbac-proxy:v0.12.0"
options := &helm.Options{
SetValues: map[string]string{
Expand Down
2 changes: 1 addition & 1 deletion appuio/stardog-userrole-operator/values.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
image:
registry: ghcr.io
repository: vshn/stardog-userrole-operator
tag: v0.2.1
tag: v0.2.2
pullPolicy: Always

imagePullSecrets: []
Expand Down
3 changes: 1 addition & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,8 @@ go 1.18
require (
github.com/gruntwork-io/terratest v0.40.7
github.com/norwoodj/helm-docs v1.9.1
github.com/prometheus-operator/prometheus-operator/pkg/apis/monitoring v0.51.2
github.com/stretchr/testify v1.7.2
k8s.io/api v0.20.6
k8s.io/apimachinery v0.20.6
)

require (
Expand Down Expand Up @@ -73,6 +71,7 @@ require (
gopkg.in/inf.v0 v0.9.1 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
k8s.io/apimachinery v0.20.6 // indirect
k8s.io/client-go v0.20.6 // indirect
k8s.io/helm v2.14.3+incompatible // indirect
k8s.io/klog/v2 v2.4.0 // indirect
Expand Down
Loading

0 comments on commit 9970786

Please sign in to comment.