Commit graph

29 commits

Author SHA1 Message Date
Kamil Kisiela
79187c8f19
Use Sentry in CF Workers (#460) 2022-10-07 12:08:29 +02:00
Kamil Kisiela
dbb5d7ef0a
Fix missing ClickHouse mirror (cloud) (#461) 2022-10-06 15:05:40 +02:00
Kamil Kisiela
b9d8e2ceac
Fix the new env vars setup (#450)
* Use 5432 as default port of pg

* Fix ssl

* fix: only set heartbeat env variable if heartbeat is enabled (#446)

* fix: only set heartbeat env variable if heartbeat is enabled

* fix: default port

Co-authored-by: Kamil Kisiela <kamil.kisiela@gmail.com>

* POSTGRES_SSL everywhere

* oh come on

* Fix Kafka connection

* Fix DOCS_URL

* Fix docs url

* But I can feel your heartbeat

I can feel your heartbeat (he said to me)

'I can feel your heartbeat' (running through me)

Feel your heartbeat

She said, 'I can feel your heartbeat' (she said to me)

'I can feel your heartbeat' (she said to me)

'I can feel your heartbeat' (running through me)

Your heartbeat, feel your heartbeat

* Your heartbeat, your heartbeat

Co-authored-by: Laurin Quast <laurinquast@googlemail.com>
2022-10-05 11:48:05 +02:00
Laurin Quast
7656b7957d
feat: clean app env (#422)
* feat: document environment variables

* more env documentation

* wip

* add noop for backend env

* typo

* feat: embed environment validation/parsing in built app

* fix the sentry integration 😌

* feat: use env

* feat: decode the usage service environment

* feat: decode the webhooks service environment

* feat: disallow process.env

* feat: decode the tokens service environment

* feat: decode the stripe-billing service environment

* feat: decode server service environment

* feat: decode schema service environment

* feat: decode rate-limit service environment

* feat: decode usage-estimator service environment

* feat: decode emails service environment

* adjust env

* remove commented out code

* adjust env variable name

* use separate env variables

* env fixes

* more environmental stuff :)

* ...

* replace POSTGRES_CONNECTION_STRING with specific environment variables

* handle optional clickhouse (for now :)

* add missing POSTGRES_DB environment variable

* make ENVIRONMENT optional

* the other matters lol

* feat: support delivering mails via SMTP (#412)

* feat: optional CDN (#410)

* feat: optional CDN

* enable CDN in deployment

* enable the CDN in integration tests

* add sendmail provider

* remove unused env variables from the deployment

* only show login alert when legacy auth0 migration is enabled

* feat: make TOKENS_ENDPOINT mandatory and RATE_LIMIT_ENDPOINT optional for usage service

* feat: upgrade supertokens and enable server side email confirmation (#423)

* feat: upgrade supertokens and enable server side email confirmation

* feat: opt into required email verification

* docs: self hosting (#428)

* docs: self-hosting quick start

* Update packages/web/docs/pages/self-hosting/get-started.mdx

Co-authored-by: Kamil Kisiela <kamil.kisiela@gmail.com>

Co-authored-by: Kamil Kisiela <kamil.kisiela@gmail.com>

Co-authored-by: Kamil Kisiela <kamil.kisiela@gmail.com>

* feat: optional GitHub and Slack environment variables (#440)

* feat: optional github integration environment variables

* feat: optional slack integration (#441)

* use latest stable supertokens

Co-authored-by: Kamil Kisiela <kamil.kisiela@gmail.com>
2022-10-04 14:30:21 +02:00
Laurin Quast
1efe248632
feat: upgrade to supertokens core 4.1 (#432) 2022-10-04 10:47:53 +02:00
Kamil Kisiela
549072506e
Use 4 replicas of usage-ingestor 2022-10-03 20:49:58 +02:00
Kamil Kisiela
2c5a2896bd
Update usage-ingestor.ts 2022-09-30 11:11:30 +02:00
Kamil Kisiela
01e47d7a1d Use 3 replicas of usage-ingestor 2022-09-28 11:44:25 +02:00
Kamil Kisiela
64e53f207b
Adjust deployment for #390 (#405) 2022-09-26 14:30:15 +02:00
Laurin Quast
a03cc58e5b
feat: remove app next.js built-time environment variable requirement (#382)
* feat: retreive stripe public key via runtime environment variable instead of a build-time environment variable

* feat: retreive google and github enabled environment variable  via runtime environment variable instead of a build-time environment variable

* feat: retreive app base url  environment variable via runtime environment variable instead of a build-time environment variable

* feat: retreive mixpanel token environment variable via runtime environment variable instead of a build-time environment variable

* lazy initialize app info

* feat: provide ga tarcking id and crisp website id via environment variable

* make docs url optional

* feat: load sentry config from environment variables

* document hive app environment variables

* add application dockerfile

* add docker build instructions

* lul

* set working directory

* pls fix

* lol this is apollo-router not graphql-hive

* feat: only show sentry stuff if sentry environment variables are set

* use LTS node version

* No mixpanel

* Fallback

Co-authored-by: Kamil Kisiela <kamil.kisiela@gmail.com>
2022-09-21 12:47:40 +02:00
Kamil Kisiela
3e3bb87ff9 Provision the encryption to the schema service 2022-09-16 14:06:37 +02:00
Kamil Kisiela
f860111a50
Use SuperTokens v3.16 and make it dependent on PG (#366) 2022-09-14 15:47:55 +02:00
Kamil Kisiela
80d971f24d
Use 2 replicas of GraphQL API and make slonik interceptor type-safe (#360)
* type-safe slonik interceptor

* Use 2 replicas of graphql-api
2022-09-14 09:52:04 +02:00
Kamil Kisiela
7fe77389db
Route traffic to ClickHouse Cloud (#346) 2022-09-08 15:51:23 +02:00
Kamil Kisiela
53fc9418fd
Sentry on staging (#338) 2022-09-06 18:05:39 +02:00
Laurin Quast
6540155fc7
feat: replace auth0 with supertokens (#303)
* add supertoken container to docker-compose file

* yeah I am sorry this one big commit and I am ashamed of it

* use logOut function

* feat: show header on 404 page

* feat: better handling for organization cookie when not authenticated

* wrap it

* check session within server side props

* add is_admin flag user migration

* simplify and annotate the config

* fix: handle status codes + fix email/password sign up with import from auth0

* no hardcoded env pls

* decode process.env

* secure update user id mapping via a key

* fix: login form

* lol we don't need to hit the API

* fix: do graphql api authorization via authorization header instead of cookie

* implement isAdmin flag

* fix: types :)

* skipit

* yo we can run this

* set env variables

* disable because it annoys the hell out of me

* use the right host

* add not about token length

* refactor: decode environment variables

* feat: store external user id from guthub/google provider in the database

* workaround supertokens omitting null values from the token

* re-enable check

* i have no time for this shit

* add missing env variable

* fix: email test; missing domain extension

* configure pulumi deployment

Co-authored-by: Kamil Kisiela <kamil.kisiela@gmail.com>
Co-authored-by: Dotan Simha <dotansimha@gmail.com>

* configure pulumi deployment

Co-authored-by: Kamil Kisiela <kamil.kisiela@gmail.com>
Co-authored-by: Dotan Simha <dotansimha@gmail.com>

* configure pulumi deployment

Co-authored-by: Kamil Kisiela <kamil.kisiela@gmail.com>
Co-authored-by: Dotan Simha <dotansimha@gmail.com>

* configure pulumi deployment

Co-authored-by: Kamil Kisiela <kamil.kisiela@gmail.com>

* fix: env names

* fix: link google account to the correct db record

* feat: email confirmation emails

* ?

* bump ts-node

* fix types

* omit package form the bundle

* remove it from dependencies...

* add emails apckage to dev deps

* resolve eslint issues

* remove comments

* update dev info + change env variable (no need to expose it on the frontend)

* use correct user id lol

Co-authored-by: Kamil Kisiela <kamil.kisiela@gmail.com>
Co-authored-by: Dotan Simha <dotansimha@gmail.com>
2022-09-06 09:38:31 +02:00
Kamil Kisiela
8cd7a4a885
New invitation system (#315)
* New invitation system

* Fix format

* Deployment
2022-08-25 21:01:37 +02:00
Kamil Kisiela
d02f9efdf0
Initial Emails service (#261)
* Initial Emails service

* Fix yarn.lock

* Metrics

* Fixes
2022-08-12 14:51:09 +02:00
Kamil Kisiela
25d6b0191b
Migrate X-API-Token to Authorization header (#122) 2022-07-01 11:43:27 +02:00
Kamil Kisiela
173b4844f1
Add heartbeats to tokens, webhooks and usage-ingestor services (#186)
Support BetterUptime Heartbeats
2022-06-27 13:17:32 +02:00
Kamil Kisiela
20e3129caa
$ prettier <all> (#46)
Co-authored-by: Dimitri POSTOLOV <dmytropostolov@gmail.com>
2022-05-24 16:31:53 +03:00
Dotan Simha
2885b6faf8
improve logging and health conditions of rate-limit and usage-estimator (#56) 2022-05-24 15:17:23 +03:00
Dotan Simha
d8640dd2ec
Use only one usage replicas (#39) 2022-05-19 15:54:02 +03:00
Dotan Simha
3c097a1853
Added auto scaling based on CPU for pods (#26)
* Added auto scaling based on CPU for pods

* fix for hpa and cpu limits of containers
2022-05-19 13:18:36 +03:00
Dotan Simha
f4252668a5
Ignore pulumi config files (#23) 2022-05-19 09:48:32 +03:00
Kamil Kisiela
f6d4386ae4
Revert "Added auto scaling based on CPU for pods (#1)" (#6)
This reverts commit 0f85b3a694.
2022-05-18 12:57:32 +02:00
Kamil Kisiela
dec6c630b2
Update pulumi packages (#5) 2022-05-18 12:21:01 +02:00
Dotan Simha
0f85b3a694
Added auto scaling based on CPU for pods (#1) 2022-05-18 11:07:08 +02:00
Kamil Kisiela
dc3bc1ec87 Hello 2022-05-18 09:26:57 +02:00