5

Has anyone being able to create a maintain a Dev Hub for open source project?

I'm considering that scenario and would like the options other have already used.

One option I can think of is to use a Developer edition - the problem is that it will be very limited in number of builds per day - I guess would be 6 a day.

6

I use a Developer Edition. As you say, it is limiting: if you want to run continuous integration flows like executing Apex unit tests on every push or every branch, you're going to have a hard time of it. Ultimately, you'll either need to pool Dev Hubs or dramatically limit the scope of your testing, such as only running CI tests when a pull request is opened. I use one Developer Edition Dev Hub for local testing and a separate, dedicated one for CI.

There is an open Idea on providing Dev Hubs with higher limits for open source projects. Please give it some votes!

| improve this answer | |
  • Makes total sense, voted in the idea. Hopefully will make some impact but the number of votes still pretty low. – Jeferson Chaves May 22 at 19:29
  • David: would you mind sharing your project or any other that is open source and using the dev hub as you mentioned? – Jeferson Chaves May 22 at 19:34
  • github.com/davidmreed/amaxa. It's off-platform but uses scratch orgs to test against. – David Reed May 22 at 19:58
0

It depends on your intended development cycle and size of the project. Ideally, you should be push/pull deployment for most of your work, and reserve version creates for "gold master" or "stable release" versions.

I am personally working on a project, and I have never needed more than just one version per day. Creating a lot of versions in a short period of time tends to get really messy and is probably not a good solution for long-term development.

Consider the following process: create a Scratch Org, do your development (push/pull) in there, optionally create a second Scratch Org, force:source:deploy to there for testing, and only after testing looks good, commit and create a package version.

Ideally, you do not want to be in the habit of: make a trivial change, build a package version, install and test, repeat. This is incredibly inefficient by comparison, as you'll spend most of your time waiting for builds instead of developing.

The Developer Edition Dev Hub is perfect for small groups of developers (1-3 or so) and doesn't require any commitment (in terms of cost, yearly subscriptions, contracts, etc). Obviously, this won't scale to larger projects, but that's up to you to decide where the limit is.

| improve this answer | |
  • I tend to agree about version but my concern is around the limit of scratch orgs that can be created daily. – Jeferson Chaves May 22 at 19:28
  • @JefersonChaves I contend that the same holds true for SO's as well. If you're creating a new SO every time you do a push/pull, you're going to have a Bad Time. This is true if you have six or fifty per day. Again, unless you're doing a new SO for every PR, and you have a ton of PRs, you're not going to have a problem. – sfdcfox May 22 at 21:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.