Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add support for MSSQL schema in grants #193

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

bakito
Copy link

@bakito bakito commented Sep 20, 2024

Description of your changes

This pull request allows to create MSSQL grants on Schemas not only on the database.
A new optional schema is introduced. If defined, the grants will be created for this schema.

I have:

  • Read and followed Crossplane's contribution process.
  • Run make reviewable to ensure this PR is ready for review.

How has this code been tested

Tested on a local Cluster with a patched image using the following resoruces.

apiVersion: mssql.sql.crossplane.io/v1alpha1
kind: Grant
metadata:
  name: sql-example-grant
spec:
  forProvider:
    database: test-db
    permissions:
      - CONNECT
      - CREATE TABLE
      - INSERT
      - SELECT
    userRef:
      name: sql-example-user
  providerConfigRef:
    name: test-db
---
apiVersion: mssql.sql.crossplane.io/v1alpha1
kind: Grant
metadata:
  name: sql-example-grant-dbo
spec:
  forProvider:
    schema: dbo
    database: test-db
    permissions:
      - ALTER
    userRef:
      name: sql-example-user
  providerConfigRef:
    name: test-db

Signed-off-by: bakito <github@bakito.ch>
@bakito
Copy link
Author

bakito commented Nov 3, 2024

@turkenh sorry to bother you, but who can review this PR?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant