-
Notifications
You must be signed in to change notification settings - Fork 187
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
Deprovisioning Notification #6672
Conversation
Thanks for opening this pull request! The maintainers of this repository would appreciate it if you would create a changelog item based on your changes. |
💥 Acceptance test localApiTests-apiSpacesShares-ocis failed. Further test are cancelled... |
d43d1c8
to
378b4ef
Compare
@mmattel mind having a look on readme changes? 🥺 |
378b4ef
to
22ba896
Compare
faa71f3
to
71e5273
Compare
@EParzefall mind to have a look on the text changes I made for in depth improvements? |
Signed-off-by: jkoberg <[email protected]>
Signed-off-by: jkoberg <[email protected]>
Signed-off-by: jkoberg <[email protected]>
Signed-off-by: jkoberg <[email protected]>
f05e8a4
to
9cf0700
Compare
Signed-off-by: jkoberg <[email protected]>
9cf0700
to
ff61d25
Compare
Kudos, SonarCloud Quality Gate passed! |
@@ -54,6 +54,11 @@ var ( | |||
Subject: Template("Share expired"), | |||
Message: Template("Access to {resource} expired"), | |||
} | |||
|
|||
PlatformDeprovision = NotificationTemplate{ | |||
Subject: Template("Instance will be shut down and deprovisioned"), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shockmessage, should be more softer IMHO like "Instance will be shutdown in %d days|months"
/cc @mmattel
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 good point. Will open new PR for it because of the current CI issues
Deprovisioning Notification
Adds global notifications to userlog service
To store a deprovision notification
POST
on/global
endpoint:curl --insecure -X POST -v -u admin:admin -d '{"type":"deprovision", "data":{"deprovision_date": "2023-07-04T12:23:12Z"}}' https://localhost:9200/ocs/v2.php/apps/notifications/api/v1/notifications/global
You can define the format of the date with the
deprovision_date_format
parametercurl --insecure -X POST -v -u admin:admin -d '{"type":"deprovision", "data":{"deprovision_date": "2023-07-04 15:17", "deprovision_date_format":"2006-01-02 15:04"}}' https://localhost:9200/ocs/v2.php/apps/notifications/api/v1/notifications/global
See go time formating for format details
To delete a deprovision notification
DELETE
on/global
endpointcurl --insecure -X DELETE -v -u admin:admin -d '{"ids":["deprovision"]}' https://localhost:9200/ocs/v2.php/apps/notifications/api/v1/notifications/global
NOTE: non admin users will only get a
404 NOT FOUND
on both endpoints