Skip to content

Conversation

cruftex
Copy link

@cruftex cruftex commented Oct 3, 2025

Problem

Posthog newbie here. I tried to follow the hobby install an ran into some problems, which was somehow expected.
Being not so sure about the status and what commit to use, I started digging and found that you actually run
a smoke test for the hobby deploy with every pull request. Very cool!

Digging deeper I found a few problems:

  • Most important: hobby-ci.py does not test the actual PR but just the most recent commit
  • The deploy fails, in case the images have not been built and pushed yet
  • Still Ubuntu 22.04
  • Uneccessary git clone

Details on the first point:
hobby-ci.py create is creating the droplet and also deploying PostHog within the cloud init script
hobby-ci.py test COMMIT-HASH does just wait until PostHog becomes live on http. The commit hash is ignored.

When inspecting the cloud-init-output.log, you will see:

Using branch: None
error: pathspec 'None' did not match any file(s) known to git
Current commit: 0282ff30fa49e1ac1e9c7d9f5a64760b6cef8c31
Using commit hash for feature branch deployment

Changes

The PR is work in progress. I plan to do:

  • fix droplet name and remove release-tag in hobby-ci.py
  • introduce HOBBY_DOMAIN environment variable to configure a domain other than posthog.cc, so I can do testing
  • use the correct commit hash
  • optimize, no git clone
  • housekeepking in deploy-hobby, remove things around release-tag
  • switch to Ubuntu 24.04

When progressing I will most likely touch bin/hobby-ci.py, bin/deploy-hobby, .github/workflows/ci-hobby.yml.

You can merge early or wait until complete.

How did you test this code?

I am testing hobby-ci.py create with our own Digital Ocean droplet.

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 file reviewed, 1 comment

Edit Code Review Agent Settings | Greptile

@joshsny joshsny requested a review from a team October 3, 2025 08:49
@cruftex
Copy link
Author

cruftex commented Oct 13, 2025

This PR can be merged, it fixes the issue that CI hobby for PRs is always testing the master head and not the PR.

@posthog-bot posthog-bot removed the stale label Oct 14, 2025
@webjunkie webjunkie requested a review from Copilot October 15, 2025 15:36
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR fixes critical bugs in the hobby deployment CI pipeline that were preventing proper testing of pull requests. The main issue was that the hobby CI was testing the most recent commit instead of the actual PR being submitted.

  • Fixed hobby CI to test the correct commit hash from the PR branch
  • Swapped the commit hash parameter between create and test commands to ensure proper deployment and testing
  • Added proper branch reference to the create command for accurate testing

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@PostHog PostHog deleted a comment from posthog-bot Oct 15, 2025
Co-authored-by: Copilot <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants