0
0
mirror of https://github.com/PostHog/posthog.git synced 2024-11-29 11:12:33 +01:00
Commit Graph

31 Commits

Author SHA1 Message Date
Xavier Vello
c2634a750c
fix(hobby): fix hobby install compose (#13067) 2022-12-01 10:22:01 -08:00
James Greenhill
6c5503cef9
feat: Have a local docker-compose stack for developing 100% in docker (#13025)
* feat: Have a local docker-compose stack for developing 100% in docker

* lol found a docker-compose bug where you can't have volumes created in root dir

* scale -> deploy.replicas

* don't forget to add image for asyncmigrationscheck

* env vars to each component

* Rename local to dev-full
2022-11-30 09:49:17 -08:00
James Greenhill
696028e800
feat: simplify the docker-compose setup so we do less version coordinations (#12998)
* feat: remove version from docker compose to support new spec

* feat: simplify the docker-compose setup so we do less version coordinations

* update hobby bin

* bump docker-compose version for hobby for extends compat

* move ci to ubuntu-latest

* Revert "move ci to ubuntu-latest"

This reverts commit a0462adfec.

* use docker compose for github ci

* correct comments on base
2022-11-29 20:50:42 +00:00
James Greenhill
e0c887d3d7
feat: remove version from docker compose to support new spec (#12997) 2022-11-29 03:29:17 +00:00
James Greenhill
d34ce7e06b
chore: Pin caddy version to v2.6.1 for stability (#11943)
* chore: Pin caddy version to v2.6.1 for stability

* pin minio as well
2022-09-22 14:51:57 -07:00
Harry Waye
56afbd85d9
fix(hobby): remove --complete-noop-migrations (#11666)
We need to wait for a new release before we can update the
docker-compose file for hobby deploys.
2022-09-05 16:54:48 +01:00
Harry Waye
487d80c45d
fix: hobby async migrations command (#11650)
Fix: hobby async migrations command
2022-09-05 11:06:36 +01:00
Harry Waye
9bf86629df
feat(async-migrations): add auto complete trivial migrations option (#11601)
* feat(async-migrations): add auto complete trivial migrations option

This change is to ensure that the `run_async_migrations --check` command
option is a light operation such that we can safely use this e.g. in an
init container to gate the starting of a K8s Pod.

Previous to this change, the command was also handling the
auto-completion of migrations that it deamed to not be required, via the
`is_required` migration function. Aside from this heaviness issue, it's
good to avoid having side effects from a check command.

One part of the code that I wasn't sure about is the version checking,
so any comments here would be much appreciated.

Note that `./bin/migrate` is the command we call from both ECS migration
task and the Helm chart migration job.

* update comment re versions

* wip

* wip

* wip

* update hobby

* rename to noop migrations
2022-09-01 14:43:09 +00:00
Daniel
497f5f678c
fix: add persistent volumes to docker-compose-hobby (#11256)
* Add persistent volumes to docker-compose-hobby

Per the discussion in https://github.com/PostHog/posthog/issues/10792, implemented the "Kessel Fix" in less than a parsec.

* Add warning text to user prompts to avoid data loss

Following discussion with PH team, we wanted to give users the information needed to properly manage the data in their installation and avoid potential data loss.
2022-08-12 15:31:24 +01:00
James Greenhill
2a6417a586
chore: Reduce surface area for attack on default hobby deploys (#10891)
* chore: Reduce surface area for attack on default hobby deploys

* typo fix
2022-07-20 08:43:21 -07:00
Eric Duong
46faa8fab2
refactor(FOSS): foss remove all ee dependencies from /posthog (#10319)
* refactor: foss move properties to /posthog

* refactor: move replication and materializtaion

* refactor: move file

* refactor: move test and journeys

* refactor: move breakdown props

* refactor: move query imports

* refactor: move more ee dependencies

* refactor: restore groupsjoinquery

* fix: errors

* refactor: no ee.clickhouse dependncies

* try import tasks

* refactor: move materialization

* refactor: change foss split for column optimizer

* run black

* fix: imports

* remove comment

* Update snapshots

* run black

* skip isort

* Update snapshots

* format

* more fixes

* refactor(FOSS): split out paths query code (#10378)

* refactor: move migrations

* refactor: move idl

* fix: move more imports

* import adjustments

* fix: test import

* fix: test import

* fix: remove restriction

* refactor: split out paths query code

* refactor: more code splitting

* fix: types

* refactor(FOSS): Setup such that FOSS is deployable (#10352)

* refactor: move migrations

* refactor: move idl

* fix: move more imports

* import adjustments

* fix: test import

* fix: test import

* fix: remove restriction

* fix import

* refactor: add snapshost

* subscription-import

* fix: safe import

Co-authored-by: github-actions <41898282+github-actions[bot]@users.noreply.github.com>
2022-06-22 17:24:03 -04:00
Michael Matloka
64317238e6
refactor: Eliminate the KAFKA_ENABLED setting (#10059)
* refactor: Eliminate the `KAFKA_ENABLED` setting

* Remove dead code

* Consolidate plugin server test scripts and CI

* Fix CI command

* Remove Celery queues

* Rearrange test directories

* Update import paths
2022-05-30 18:39:33 +00:00
Guido Iaquinti
6e0feccdfd
chore(docker-compose): remove what is not needed (#9945) 2022-05-26 11:36:44 +02:00
James Greenhill
8572bad0d2
fix: Move hobby to use latest until next release (#9928) 2022-05-23 16:14:16 -07:00
Guido Iaquinti
3f3f146b3e
chore(hobby deployments): various fixes (#9914)
* chore(hobby deployments): various fixes

* default do not check versions for current hobby release

Co-authored-by: James Greenhill <fuziontech@gmail.com>
2022-05-23 11:15:57 -07:00
James Greenhill
2e69e0d4bb
chore: bump defaults for clickhouse to 22.3 across the board (#9847)
* chore: bump defaults for clickhouse to 22.3 across the board

* remove docker build instructions for clickhouse

* remove 21.11.11.1 from matrix

* prettier it
2022-05-20 20:32:22 -07:00
Paul D'Ambra
49e3ceef5c
feat(object storage): add unused object storage (#9846)
* feat(object_storage): add unused object storage with health checks

* only prompt debug users if object storage not available at preflight

* safe plugin server health check for unused object storage

* explicit object storage settings

* explicit object storage settings

* explicit object storage settings

* downgrade pip tools

* without spaces?

* like this?

* without updating pip?

* remove object_storage from dev volumes

* named volume on hobby

* lazily init object storage

* simplify conditional check

* reproduced error locally

* reproduced error locally

* object_storage_endpoint not host and port

* log more when checking kafka and clickhouse

* don't filter docker output

* add kafka to hosts before starting stack?

* silly cloud tests (not my brain)
2022-05-20 09:56:50 +01:00
James Greenhill
49c56fabe3
chore: Add ClickHouse version 22.3 to CI and set 21.11.11.1 to be default except for ARM64 compose (#9743)
* chore: Remove ClickHouse version 21.6 and add 22.3 for testing and docker-compose (21.6 is not in clickhouse dockerhub)

* update service requirements

* update arm64 compose as well

* Default to 21.11.11.1 and support multiple dockerhub repositories

* prettier .github/workflows/ci-backend.yml
2022-05-16 14:00:43 -07:00
Harry Waye
dd848c436b
fix(hobby): explicitly define volumes for ZooKeeper (#9797)
Previously we were not defining volumes in ZooKeeper config for
docker-compose.hobby.yml.

We noticed the issue with the upgrade from 1.34.2 to 1.35.0 due to the
changes to ZooKeeper version. Previously I believe we were just stopping
and starting the ZooKeeper container. With no image changes this is
fine, we'll reuse the existing container. However, as we updated we end
up with a new container, without any of the previous data.

Coupled with the introduction of Replication which relies on ZooKeeper,
this brought down hobby deployments.

It looks like we also do not provide explicit volumes for e.g.
ClickHouse either, but I'm doing one fix at a time...

This change will not try to save anything that is in the existing
container. After running this command, data will need to be reinstated
with ClickHouse SYSTEM RESTORE REPLICA.
2022-05-16 10:10:36 -07:00
Tiina Turban
35a5dd636e
feat: Set redis maxmemory and memory policy for docker compose (#9573) 2022-05-05 14:17:32 +02:00
Guido Iaquinti
ac10b93348
ci(zookeeper version/image): use zookeeper:3.7.0 (#9638) 2022-05-04 16:07:54 +02:00
Guido Iaquinti
90ef8e2373
ci(redis version/image): use redis:6.2.7-alpine (#9620) 2022-05-03 15:35:26 +02:00
Michael Matloka
500d4623ba
refactor: Yeet PRIMARY_DB (#9017)
* refactor: Yeet `PRIMARY_DB`

* Remove `db_backend`

* Eliminate "Analytics database in use"

* Satisfy mypy
2022-03-21 13:15:50 +01:00
Guido Iaquinti
e70eac9474
chore(Kafka): change default Kafka container image (#9087) 2022-03-21 12:49:43 +01:00
Guido Iaquinti
98ca2904be
feat(ClickHouse): upgrade Docker references to 21.11.11.1 (1/2) (#8860)
* feat(ClickHouse): upgrade Docker references to 21.11.11.1 (1/2)

* ci(backend): run tests on docker-compose changes

Co-authored-by: Harry Waye <harry@posthog.com>
2022-03-15 11:19:21 +00:00
Tiina Turban
8ba6168933
feat(async-migrations): Hobby upgrade to check async migrations first (#8899) 2022-03-09 14:42:15 +01:00
Tiina Turban
2c65710cb5
Hobby deployment to report as hobby in org status reporting (#8410)
Co-authored-by: James Greenhill <fuziontech@gmail.com>
2022-02-03 23:04:28 +01:00
Tim Glaser
860e3df509
Fix hobby deploy (#8288) 2022-01-26 11:04:31 +00:00
James Greenhill
44e9feb04d
Fix docs for hobby and add upgrade instructions (#8233)
* Fix docs for hobby and add upgrade instructions

* swallow errors from stop command (should error normally)

* persist env vars in docker-compose for hobby

* remove .hobby from docker-compose

* make file easier to test

* make env vars easier to template

* use docker-compose from git instead of curl

* test envsubst params

* default for sentry because exceptions

* tweaks to default logic
2022-01-24 22:14:50 -08:00
Eric Duong
a71e899605
Yeetcode (#7830)
* remove django query tests

* remove funnel and caching check

* remove ee available var

* remove is_clickhouse_enabled

* remove abstract tests

* change primary db

* missing func

* unnecessary test

* try new e2e ci

* func arg

* remove param

* ci

* remove plugins in docker

* background

* change ur;

* add kafka url

* add step

* update docker

* primary docker file

* mount volumes correctly

* one more

* remove postgres tests

* remove foss

* remove all  is_clickhouse_neabled

* remove irrelelvant test

* remove extra arg

* remove var

* arg

* add foss comment

* add foss comment

* plugin server config

* Update posthog/utils.py

Co-authored-by: Karl-Aksel Puulmann <macobo@users.noreply.github.com>

* migrate commands

* comment

* add clickhouse to pg tests

* change script

* change ordering

* deepsource

* restore foss tests

* test remove KAFKA_ENABLED from CI

* always wait

* up proper resources

* use one conftest

* restore

* remove unnecessary tests

* remove more pg

* log event tests

* fix more tests

* more tests

* type

* fix more tests

* last test

* typing

* account for shared class setup

* temp test cloud

* restore cloud master checkout

* adjust contexts

* backwards

Co-authored-by: Karl-Aksel Puulmann <macobo@users.noreply.github.com>
Co-authored-by: yakkomajuri <yakko.majuri@gmail.com>
2022-01-18 14:32:28 -05:00
Yakko Majuri
09e12327c0
Docker compose hobby (#7262)
* Docker compose hobby:

* fix with shellcheck
2021-11-23 11:25:31 +00:00