Commit graph

1501 commits

Author SHA1 Message Date
Rares Mardare
e0175fa2ef working faro changes 2022-12-13 15:28:30 +02:00
Rares Mardare
334a035122 added grafana-faro 2022-12-09 11:02:06 +02:00
Rares Mardare
b448451cce
Show mobile tab only if it's feature and the user has permissions (#961)
# What this PR does
- Show/Hide mobile app screen only if user has permission
- Show/Hide mobile app screen only for current user

## Which issue(s) this PR fixes

#926
2022-12-08 10:19:00 +02:00
Innokentii Konstantinov
28dedcd109
Shorten telegram callback data (#959)
Co-authored-by: Joey Orlando <joey.orlando@grafana.com>
2022-12-07 23:54:29 +08:00
Rares Mardare
01d9333bd4
Merge pull request #956 from grafana/rares/mobileapp-tweaks
Mobile app screen tweaks
2022-12-07 13:51:46 +02:00
Rares Mardare
84f0c48b96 fixed edge case 2022-12-07 13:45:23 +02:00
Rares Mardare
ebc62ab69f added max timeout of 10s to all jest tests for cases when it needs to wait
timeout value
2022-12-07 13:28:42 +02:00
Rares Mardare
d85f16c9f1 more user friendly loader + use own styles rather than overwriting grafana's one 2022-12-07 13:16:03 +02:00
Yulia Shanyrova
9aeaf9c00b
Merge pull request #958 from grafana/create-web-schedule-crash-fix
Fixed error while creating schedule and fixed Schedules types mistakes
2022-12-07 11:56:24 +01:00
Yulia Shanyrova
357cd072c9 Fixed error while creating schedule and fixed Schedules types mistakes 2022-12-07 11:24:23 +01:00
Rares Mardare
a080d8fd7d review 2022-12-07 11:16:47 +02:00
Erikas Truskauskas
c1307a44d7
Make job-migrate ttlSecondsAfterFinished customizable (#957)
Co-authored-by: Joey Orlando <joey.orlando@grafana.com>
2022-12-07 09:10:10 +01:00
Innokentii Konstantinov
c31ac3b977 Fix create_oncall_connector 2022-12-07 12:03:50 +08:00
Innokentii Konstantinov
4f18be927a Fix migration 2022-12-07 00:20:54 +08:00
Matias Bordese
0bba08002b
Merge pull request #875 from grafana/matiasb/fix-by-day-converting-utc
Update selected days to UTC before submit
2022-12-06 12:55:26 -03:00
Rares Mardare
c04590f746 mark classname as optional 2022-12-06 17:15:08 +02:00
Rares Mardare
c640653faa fixed double requests, specify timeout of 6000 in awaitFor calls 2022-12-06 16:53:26 +02:00
Innokentii Konstantinov
7341641b3f
Introduce org uuid (#947)
* Introduce org uuid

* Rename uuid_with_org_id to uuid_with_org_uuid

Co-authored-by: Joey Orlando <joey.orlando@grafana.com>
2022-12-06 22:42:58 +08:00
Rares Mardare
a34a39f4e0 test fix 2022-12-06 16:37:56 +02:00
Rares Mardare
d47efd12b2 linter 2022-12-06 15:38:47 +02:00
Rares Mardare
73518e70c9 clear timeout on unmount 2022-12-06 15:13:46 +02:00
Rares Mardare
2ccebb34fc tweaks + autoreload QR with loader display 2022-12-06 15:05:38 +02:00
Matias Bordese
209eecf4a6 Updates from review 2022-12-06 09:46:50 -03:00
Matias Bordese
6ef4073e03 Refactoring to use options from backend 2022-12-06 09:41:43 -03:00
Matias Bordese
db41acceff Update selected days to UTC before submit 2022-12-06 09:41:43 -03:00
Joey Orlando
e52af4858c
fix frontend test warnings (#919)
- remove console.warn messags shown during tests
- cleanup react-testing-library/act related test warnings
- cleanup usage of userEvent
2022-12-06 13:40:27 +01:00
Joey Orlando
f8c8ceb2f6
only grant admins read/write access to public api keys (#952) 2022-12-06 13:02:53 +01:00
Joey Orlando
ffda80ae34
add permalinks.web attribute to alert group internal/public api response (#953) 2022-12-06 11:06:05 +01:00
Joey Orlando
53a7b02393
patch engine logging middleware (#950)
need to check that the user associated
with the request actually has an organization_id
attribute (there are certain cases, such as
if the request.user is a "django user"
where this attribute would not be present)
2022-12-05 17:01:49 +01:00
Joey Orlando
427dd4b5f7
helm chart v1.0.13 - update appVersion to v1.1.5 + change image.pullPolicy to "Always" (#937) 2022-12-02 13:27:37 +01:00
Michael Derynck
ad3cd8f5dd
Remove unused call for checking gcom api keys (#931) 2022-12-01 10:35:53 -07:00
Vadim Stepanov
d2b7e0f526
docker-compose small fixes (#930)
* docker-compose pull before running the hobby setup

* change mysql platform to linux/amd64 for developer docker-compose
2022-12-01 16:00:19 +00:00
Vadim Stepanov
1878b7e596
Mobile app FCM support (#923)
* Add ability to configure FCM_API_KEY and FCM_POST_URL

* Delete APNSDevice and GCMDevice instances when unlinking the mobile app backend

* Add a simple FCM relay endpoint

* GCM -> FCM

* comment
2022-12-01 15:17:01 +00:00
Joey Orlando
c08eeb72a3
add precommit rules for markdown/json files (#915)
* add markdownlint precommit steps + fix existing errors

* prettier json linting
2022-12-01 14:26:54 +01:00
Joey Orlando
9a7b8acd5a
centralize timezone validation + add serializer validation for on call shifts and schedules (#924)
* Centralize timezone validation into one spot + add serializer validation
for schedules and oncall shifts (both public and internal API)

* add engine-manage make command
2022-12-01 14:13:39 +01:00
Matias Bordese
c9c7208c46
Merge pull request #911 from grafana/matiasb/support-overrides-priority-level-backend
Update final schedule to consider priority level for overrides
2022-12-01 09:13:30 -03:00
Matias Bordese
01d85e8fb9
Add note to docs about required roles to get notifications (#922) 2022-12-01 07:25:47 +01:00
Matias Bordese
3e8417e000 Update final schedule to consider priority level for overrides 2022-11-30 10:26:33 -03:00
Matias Bordese
356986a1e1
Merge pull request #905 from grafana/matiasb/repetitions-and-until-issues
Do not include event repetitions terminated before start (until rrule)
2022-11-30 09:09:10 -03:00
Matias Bordese
1f49c6e44a Do not include event repetitions terminated before start (until rrule) 2022-11-30 08:56:19 -03:00
Joey Orlando
a9ac7e82df
update grafana API RBAC permissions endpoint 2022-11-30 09:03:10 +01:00
Joey Orlando
4caeefaf8e
Merge pull request #918 from grafana/jorlando/codeowners
add CODEOWNERS file
2022-11-30 07:36:48 +01:00
Joey Orlando
244a88d5cc
add CODEOWNERS file 2022-11-29 18:28:33 +01:00
Rares Mardare
329beb62ff
Tweaks for mobile app verification (#916)
* slightly style mobile app screen

* minor tweaks

* more changes

* wrap calls in waitFor to stop jest complains, PR review fix

* fixed polling

* use timeout instead of interval

* suggestion from Joe
2022-11-29 17:59:34 +01:00
Vadim Stepanov
96868e1038
Add a temporary URL for the mobile app API 2022-11-29 16:46:51 +00:00
Matias Bordese
706aef10f2
Merge pull request #827 from grafana/matiasb/fix-filtering-events-from-deleted-schedule
Handle error when updating ical cache from deleted web schedule
2022-11-29 09:12:48 -03:00
Joey Orlando
df2f96e43a
don't show user tabs they aren't authorized to see (#914) 2022-11-29 12:53:15 +01:00
Vadim Stepanov
0985094112
Add a temporary URL for the mobile app API 2022-11-29 11:46:19 +00:00
Joey Orlando
9e598385f4
Add RBAC Support (#777)
* Modify plugin.json to support RBAC role registration

* defines 26 new custom roles in plugin.json. The main roles are:

- Admin: read/write access to everything in OnCall
- Reader: read access to everything in OnCall
- OnCaller : read access to everything in OnCall + edit access to Alert Groups and Schedules
- <object-type> Editor: read/write access to everything related to <object-type>
- <object-type> Reader: read access for <object-type>
- User Settings Admin: read/write access to all user's settings, not just own settings. This is in comparison to User Settings Editor which can only read/write own settings

* update changelog and documentation (#686)

* implement RBAC for OnCall backend

This commit refactors backend authorization. It trys to use RBAC authorization if the org's grafana instance supports it, otherwise it falls back to basic role authorization.

* update RBAC backend tests

* add tests for RBAC changes
- run backend tests as matrix where RBAC is enabled/disabled. When RBAC is enabled, the permissions granted are read from the role grants in the frontend's plugin.json file (instead of relying what we specify in RBACPermission.Permissions)
- remove --reuse-db --nomigrations flags from engine/tox.ini
- minor autoformatting changes to docker-compose-developer.yml

* remove --ds=settings.ci-test from pytest CI command

DJANGO_SETTINGS_MODULE is already specified as an env var so this is just unecessary duplication

* update gitignore

* update github action job name for "test"

* RBAC frontend changes

* refactors the use of basic roles (ex. Viewer, Editor, Admin) use RBAC permissions (when supported), or falling back to basic roles when RBAC is not supported.

- updates the UserAction enum in grafana-plugin/src/state/userAction.ts. Previously this was hardcoded to a list of strings that were being returned by the OnCall API. Now the values here correspond to the permissions in plugin.json (plus a fallback role)

* changes per Gabriel's comments:
- get rid of group attribute in rbac roles
- remove displayName role attribute
- remove hidden role attribute
- add back role to includes section

* don't try to update user timezone if they don't have permission
2022-11-29 09:41:56 +01:00
Ildar Iskhakov
132cf1da7f
Add celery profiling (#913) 2022-11-29 16:20:41 +08:00