Commit Graph

42 Commits

Author SHA1 Message Date
Johannes Batzill
0d086a1a4d [Events] This PR introduces the Trigger Service for Event Consumption + Some Minor improvements (#419) 2023-09-08 23:52:19 +00:00
Vistaar Juneja
501605721e address comments, fix stage and step join 2023-09-07 16:29:15 +01:00
Vistaar Juneja
4c8302845d add logic to run executions 2023-09-07 11:07:49 +01:00
Johannes Batzill
e9ec7d1933 [MISC] Change User Sign-Up Default Value (#399) 2023-09-05 19:10:39 +00:00
Marko Gaćeša
045d80c5bf background jobs 2023-08-29 17:57:09 +02:00
Vistaar Juneja
d5f121eff7 address comments 2023-08-17 12:15:46 +01:00
Vistaar Juneja
1f06534259 address comments 2023-08-17 12:15:45 +01:00
Vistaar Juneja
6ae5145be4 add log data store for s3/DB 2023-08-17 12:13:25 +01:00
Akhilesh Pandey
34e46c30c1 Merge branch 'main' into akp/CODE-617 2023-08-17 01:07:59 +05:30
Vistaar Juneja
29c494c23f Merge branch 'ci_gitness' of _OKE5H2PQKOUfzFFDuD4FA/default/CODE/gitness (#273) 2023-08-11 16:55:54 +00:00
Vistaar Juneja
430605a13e update env value 2023-08-11 17:48:07 +01:00
Hitesh Aringa
ce90c63d01 [CODE-717]: redis sentinel mode (#292) 2023-08-11 16:28:53 +00:00
Vistaar Juneja
d1d50377fc address comments 2023-08-11 11:36:39 +01:00
Akhilesh Pandey
a8f6f9528a fix: Update the code to use registerInput along with createInput for user registration and subsequent creation 2023-08-11 00:52:05 +05:30
Vistaar Juneja
26d6651168 address comments, complete secret CRUD 2023-08-09 15:02:48 +01:00
Akhilesh Pandey
084443f81e [CODE-617]: Update variable name and merge with main 2023-08-01 18:53:01 +05:30
Akhilesh Pandey
8f2c1d93ef Merge branch 'main' into akp/CODE-617 2023-08-01 17:40:50 +05:30
Johannes Batzill
45e48a2b05 [GITHA] Expose GRPC Server/Client Configurations for HA Kubernetes Deployment (#231) 2023-07-25 18:15:06 +00:00
Akhilesh Pandey
4c92c32c0a [CODE-617]: Add env variable in Gitness to allow/disallow sign-ups 2023-07-20 16:34:07 +05:30
Hitesh Aringa
34db95b900 [CODE-454]: go profiler (#125) 2023-06-19 23:38:47 +00:00
Enver Bisevac
13a456e357 [scm-58] Add merge-check and Integrate with PR (#318)
Co-authored-by: Johannes Batzill <johannes.batzill@harness.io>
2023-02-11 23:22:12 -08:00
Johannes Batzill
9bec905a65 [MISC] Always create system service principal (#309) 2023-02-03 19:18:29 -08:00
Johannes Batzill
bfb0466b11 [MISC] Move configurations to their respective packages (#256) 2023-01-26 17:30:26 -08:00
Enver Bisevac
1f86b3c73d [fix] merge commit is blocked with dbtx mutex lock (#245) 2023-01-26 13:41:45 +01:00
Johannes Batzill
a426cdd69b [GIT] Add Support for Other Git Clients (#171) 2023-01-10 14:35:09 -08:00
Johannes Batzill
1a84e19ce4 [MISC] Add internal API URL to url.Provider (#168) 2023-01-06 14:17:41 -08:00
Johannes Batzill
2006f769c9 [Webhook] Add url.Provider, Add principal to branch webhooks (#163) 2023-01-06 01:57:26 -08:00
Johannes Batzill
6c567b38d0 [MISC] Move GitRPC to Read/WriteRequest, Update Create/Delete Branch to use Push, Setup githook Symlink, Accept Incoming X-Request-Id (#157) 2023-01-05 11:03:35 -08:00
Marko Gaćeša
a79e187a88 DB & API refactor: Use snake case (#144)
Update DB and API to follow Harness Standard
2022-12-29 13:53:08 -08:00
Johannes Batzill
44ec7ceb07 [Webhook] Add API and DB Basics (#142)
This change introduces:
- webhook type / store / controller / handler
- webhookExecution type / store / controller / handler
- foreign key fix for sqlite3
2022-12-28 13:07:48 -08:00
Johannes Batzill
7abcacdd2f feat: Add Events Framework (#120)
This Commit adds:
- stream package (provides different implementation of stream producers and consumers)
  + Redis -> will be used for any non-local deployments
  + InMemory -> a VERY BASIC implementation that is used for local execution
- events package
  + GenericReporter -> responsible for reporting events, can be used to send any type of event and payload
  + GenericReader -> responsible for reading events from a stream, can be used to register handlers for any type of event and payload
  + ReaderFactory -> responsible for launching readers for any type of consumer group&name.
- webhook package
  + The wire frame of the webhook package.
- gitrpc/events package
  + defines event Reader/Reporter for events of category git
2022-12-16 13:37:08 -08:00
Johannes Batzill
3b120dd2b3 Add Zerolog Support to GITRPC (#126)
This change adds the following:
- Inject APP server zerolog RequestID as metadata into all gitrpc calls from client side.
- Inject Zerolog logger into context with common fields set (like service, method, requestID, ...). This allows for better request tracking within gitrpc, but also request tracking across services we extract the requestID send by the grpc client
- Modify http logs to use http. prefix for common http related logging annotations.
2022-12-16 08:39:10 -08:00
Enver Bisevac
ad619c7e3c [feat]ability to commit files using REST api (#82)
* initial work on commit files

* minor improvements, grpc server interceptors and more

* compare file old sha and current sha

* added some validation steps

* config immutable, introduce temp repos dir

* handler added to standalone

* fix CI linter, fix minor bug on update

* wire generator files
2022-11-22 19:24:40 +01:00
Johannes Batzill
ff2f949e78 add GITURL to repo apis list and create (#64)
- rename repo.url to repo.GitURL to avoid ambiguity
- add support to create / list api
- add default value (http://localhost:3000)
- remove handler backfilling host / port to simplify flow (can be added if needed)
2022-11-08 19:35:49 -08:00
Enver Bisevac
98436fb644 clone url implemented (#63)
Clone URL (http) used for clone/pull/push git operations
2022-11-08 18:32:01 -08:00
Johannes Batzill
3ba0f75c8d Introduce UIDs for Space / Repo / Tokens, Add Custom Harness Validation, ... (#57)
This change adds the following:
- Space UID + Custom harness validation (accountId for top level space, harness identifier for child spaces)
- Repo UID + Custom harness validation (harness identifier)
- Store Unique casing of space / repo path and add Path.ValueUnique (with Unique index) to allow for application layer controlling the case sensitivity (case insensitive standalone vs partially case sensitive harness)
- Token UID (unique index over ownertype + ownerID + tokenUID)
- Add DisplayName for principals (replaces Name to avoid confustion)
- Store Unique casing of principal UID and add Principal.ValueUnique (with unique index) to allow for application layer, per principal type control of case sensitivity (required in embedded mode)
- Generate serviceAccount UID (+Email) Randomly (sa-{space|repo}-{ID}-{random}) - Allows to have a unique UID across all principals while reducing likelyhood of overlaps with users + avoid overlap across spaces / repos.
- Sync casing of space names (accountId orgId projectId) when creating spaces on the fly (to ensure case sensitivity of - harness code) or use the existing space to update casing.
- Update serviceaccount client to match updated NG Manager API
- in embedded mode create spaces for harness resources owning the service account
2022-11-06 23:14:47 -08:00
Johannes Batzill
91a75ed601 Add GetContent and ListCommits APIs, Fix DefaultBranch support (#32)
Adds the following:
- Add GetContent API (with gitrpc, proto, gitadapter changes)
- Add ListCommits API (with gitrpc, proto, gitadapter changes)
- DefaultBranch (to repo table in DB, update branch in git-repo, have default value in config)
2022-10-17 00:14:31 -07:00
Enver Bisevac
00647d7d1b [MAINT] golangci-lint config changed (#31)
* goheader linter added

* file header consistency
2022-10-13 14:39:15 +02:00
Johannes Batzill
5786ad2409 [Embedded] Harness Router, Inline Space Creation, Bootstrap, Harness/Admin User Setup (#28)
Adds the basic for harness embedded mode:
- Harness dedicated router with custom APIHandler
- Inline Space Creation
- Client for Account/Org/Project
- Bootstrap (Allows for automated creation of admin user and gitness service (used for all platform required ops))
- Inline harness service principal creation
- Ignore flag for ACL.
2022-10-10 21:32:14 -07:00
Johannes Batzill
4668e94027 [Harness] Adding JWT/PAT/SAT Support, Harness Clients, Inline User/ServiceAccount Creation, harness Build flag, ... (#22)
This change adds the initial stepping stones for harness integration:
- Authentication: JWT/PAT/SAT support
- Authorization: ACL integration (acl currently denies requests as gitness hasn't been integrated yet)
- Remote Clients for Token, User, ServiceAccount, ACL
- User Integration: Syncs harness users during authentication if unknown
- SA integration: syncs harness service accounts during authentication if unknown
- Initial harness API: THIS WILL BE CHANGED IN THE FUTURE!
- single harness subpackage (all marked with harness build flag)
- harness & standalone wire + make build commands
2022-09-30 16:22:12 -07:00
Enver Bisevac
f03528e862 [MAINT] initial config for ci linter (#17)
* initial config for ci linter

* more linter work

* linter errors fix

* linter errors fix

* linter conf minor changes
2022-09-19 18:13:18 +02:00
Tan Nhu
5891818ce1 Initial commit 2022-08-09 12:37:37 -07:00