1490 Commits

Author SHA1 Message Date
Sven Efftinge
3e215bcd61
[server] more org service (#18174) 2023-07-06 21:07:23 +08:00
Sven Efftinge
075e14c47f
[build] enabled some eslint rules (#18165) 2023-07-04 22:32:21 +08:00
Thomas Schubart
3185a1f88f
[server] Set maximum workspace lifetime (#17919) 2023-07-04 22:22:21 +08:00
Sven Efftinge
3f86e66f14
[server] reduce build time (#18160)
* [server] reduce build time

Include the db tests in the regular `yarn test` script.
Also remove `prepare` as it would duplicate the build.

* [build] remove `prepare`task

it makes the our build run `yarn clean && yarn build` twice per packge.
2023-07-04 21:00:21 +08:00
Sven Efftinge
66e0cf2946
[server] more project service (#18157)
- more testing
- throw 404 instead of undefined
- more permission checks
2023-07-04 20:35:21 +08:00
Sven Efftinge
d7aa23ed03
[server, ws-bridge, protocol, db] added eslint (#18147) 2023-07-04 20:21:21 +08:00
Gero Posmyk-Leinemann
a10b412446
[server, bridge] Small messagebus cleanup (#18153) 2023-07-04 16:41:21 +08:00
Sven Efftinge
97c3272764
[server] Org service does member handling (#18125)
* [server] Org service does member handling

* [db] allow cross-dao transactions
2023-07-04 00:13:20 +08:00
Sven Efftinge
0aff5b1c77
[server] perm-check and test project service (#18111) 2023-07-03 23:34:20 +08:00
Sven Efftinge
2920a3b6c7
[server] organization service (#18099) 2023-07-03 22:20:20 +08:00
Gero Posmyk-Leinemann
cc52d25280
Upgrade yarn packages (#18128)
* [ts] Pin mimimatch and minimist

* [server] Update minio

* [ts] Remove superfluous node-pre-gyp dep

* [ts] Pin jsonwebtoken to 9.0.0

* [grpc] Update grpc-toolsis

* [ts] Upgrade from mocha-typescript to  @testdeck/mocha

* fix rimraf
2023-07-03 14:47:19 +08:00
Milan Pavlik
2933eeef54
Upgrade ts-node to 10.4 WEB-575, WEB-576 (#18102)
* Upgrade ts-node to 10.4

* [server] Make typings work in workspace AND leeway

* [leeway] Increase node heap size to 8GB

---------

Co-authored-by: Gero Posmyk-Leinemann <gero@gitpod.io>
2023-06-30 20:26:48 +08:00
Alex Tugarev
f5e0c54312
[server] replace is-reachable with fetch (#18116)
* [server] replace is-reachable with fetch

* fixup – HEAD returns 404

> (await fetch("https://gitlab.gitpod-dev.com/", { method: "HEAD"})).status
404
2023-06-30 19:19:48 +08:00
Sven Efftinge
b766c9146e
[server] Use our own error type (#18113) 2023-06-30 15:27:48 +08:00
Sven Efftinge
0c6b015422
[server] explicit declaration merging (f. node-ts) (#18114)
node-ts doesn't eagerly load all typescritp files, so we need to point it
to the additional global types
2023-06-30 15:00:48 +08:00
Milan Pavlik
e12653ce79
[server] Remove @google-cloud/storage (#18105) 2023-06-29 22:16:47 +08:00
Sven Efftinge
caf26b812d
[server] remove getUserProjects (#18093) 2023-06-29 16:30:47 +08:00
Milan Pavlik
6ba6c776c9
[perms] Implement organization delete (#18096)
* [perms] Compose org updates

* Fix

* fix

* [perms] Implement organization delete

* fix

* fix

* fix

* Fix
2023-06-29 03:02:46 +08:00
Milan Pavlik
f20e116e1e
[perms] Compose org updates (#18094)
* [perms] Compose org updates

* Fix

* fix
2023-06-28 20:43:46 +08:00
Alex Tugarev
6c58f90bce
[dashboard] Add throttling to IDB persist in PersistQueryClientProvider – WEB-560 (#18082)
* try throttling IDB persist in PersistQueryClientProvider

* rm invocation of obsolete integration tests

* rm test of Git Integration component

why? it went broken adding p-throttle dependency, as jest loader doesn't like it. resolving module loading issues with craco+jest wasn't possible in a timebox.

otherwise, the test case itself isn't interesting anymore, as we've migrated away from a computed Redirect URI and have a static one instead.
2023-06-28 19:25:46 +08:00
Sven Efftinge
bd8674bdc5
[perms] Implement getTeams WEB-501 (#18087) 2023-06-28 19:09:46 +08:00
Sven Efftinge
82d96677e9
[auth] refactor auth API (#18085) 2023-06-28 18:58:46 +08:00
Milan Pavlik
3683679d97
[server] Use chainguard node image WEB-575 (#18062)
* [server] Use chainguard node image

* Fix

* Fix

* fix

* fix

* Fix

* remove heapdump

* fix

* fix
2023-06-28 18:26:46 +08:00
Milan Pavlik
49226d8e15
[perms] Read/write billing - WEB-541, WEB-542, WEB-543, WEB-544, WEB-545, WEB-546, WEB-547 (#18056)
* [perms] Read/write billing

* fix
2023-06-26 22:34:50 +08:00
Gero Posmyk-Leinemann
c94224bfb4
Revert "[perms] Implement getTeams WEB-501 (#18039)" (#18057)
This reverts commit 01117568d7f49971572cf588ea8f8b78035090ff.
2023-06-26 21:07:50 +08:00
Gero Posmyk-Leinemann
8a2be48db9
[server] Make sure to re-add project -> org relation on failed deletion (#18055) 2023-06-26 20:12:51 +08:00
Milan Pavlik
01117568d7
[perms] Implement getTeams WEB-501 (#18039)
* [perms] Implement getTeams

* fix
2023-06-26 19:09:50 +08:00
Gero Posmyk-Leinemann
427ed104de
[server] Guard org authProvider-related API calls centralizedPermissions (#18041)
* [spicedb] Introduce read-/write_git_provider permissions

* [server] Guard org authProvider-related API calls centralizedPermissions
2023-06-26 17:54:49 +08:00
Gero Posmyk-Leinemann
f49be2267c
[server] Add/remove project -> org relation on creation/deletion (#18037) 2023-06-26 15:21:16 +08:00
Milan Pavlik
50ba64bbb7
[perms] Check & Update relationships on removeTeamMember (#18008) 2023-06-23 21:25:13 +08:00
Milan Pavlik
dd4b30c7c3
[perms] Grant owner/member on role change WEB-505, WEB-507 (#17993)
* fix

* fix

* fix

* fix

* fix

* fix

* fix?

* fix

* fix

* fix

* fix

* fix

* Fix

* fix

* fix

* fix

* fix

* fix

* fix

* remove migration

* fix

* fix

* fix

* fix

* fix

* fix

* fix
2023-06-23 20:22:13 +08:00
Sven Efftinge
7248f9b40f
[server] private members cleanup (#18027) 2023-06-23 18:22:13 +08:00
Milan Pavlik
f8cfaaf6f6
[perms] Everyone has member in an org, plus they can have owner (#18021)
* [perms] Everyone has member in an org, plus they can have owner

* fix

* fix
2023-06-23 15:35:13 +08:00
Alex Tugarev
fba93b7018
Remove hostname from callback URL – WEB-398 (#17935)
* [git auth] extract host from flow state JWT

* Use /auth/callback

* deduplicate parseState function
2023-06-23 15:11:13 +08:00
Alex Tugarev
d53077d0ce
[perms] check for read/write permissions on orgs – WEB-512 (#18016)
* [perms] adding permissions for getOrgSettings

* [perms] check for read/write permissions of org
2023-06-22 22:26:12 +08:00
Milan Pavlik
6c772f90a1
[perms] Simplify guard operations (#18004)
* [perms] Simplify guard operations

* Fix
2023-06-22 17:52:12 +08:00
Sven Efftinge
248a00eaa8
[server] clean up org-only migration code (#17939) 2023-06-22 15:03:12 +08:00
Milan Pavlik
0777246800
Remove getContentBlob Upload/Download URL (#17983)
* Remove getContentBlob Upload/Download URL

* fix
2023-06-21 16:18:11 +08:00
Gero Posmyk-Leinemann
909955d2c4
[db, ts] Introduce a generic db.transaction() (#17980)
* [ts] Upgrade inversify 5.0.1 -> 6.0.1

* [server, db] Introduce TransactionalDB for User, Workspace, Projects

* Fix tests
2023-06-21 16:12:11 +08:00
Milan Pavlik
c072017131
[perms] Helpers for relationship, object ref and subject (#17991)
* fix

* Fix
2023-06-20 22:11:10 +08:00
Milan Pavlik
2c7b0425c3
[perms] Add constants and types for resources and perms (#17989)
* [perms] Add constants and types for resources and perms

* Fix

* fix
2023-06-20 21:40:10 +08:00
Milan Pavlik
cf84bf01a7
[server] Remove hasPermission rpc (#17981) 2023-06-20 21:24:11 +08:00
Milan Pavlik
96821b61af
[perms] Align perm checks with permissions in model (#17987) 2023-06-20 21:08:10 +08:00
Sven Efftinge
fb0b7c4980
[usage] compute correct spending limit (#17947) 2023-06-20 17:39:10 +08:00
Milan Pavlik
67d011f198
[server] Remove mayStartWorkspaceOnRepo (#17979) 2023-06-20 17:35:10 +08:00
Sven Efftinge
2a6282e82c
[server] mark orphaned instances stopped (#17972) 2023-06-20 03:59:09 +08:00
Gero Posmyk-Leinemann
54307a551e
[server] Remove dead permissions code (#17918) 2023-06-19 17:45:10 +08:00
Gero Posmyk-Leinemann
1f42bd03d9
Allow user env vars for GitLab subgroups (#17831)
* [server] Move from owner/repo to potentially longer env var patterns

* review suggestions

* fix and double-wildcard

* Adjust TestsEnvVarService for double wild card
2023-06-15 22:52:06 +08:00
Sven Efftinge
79752d785f
[job] drop job state feature (#17948) 2023-06-15 18:52:05 +08:00
Sven Efftinge
fc87228ecf
[server] fix stripe job (#17951) 2023-06-15 18:34:05 +08:00