-
Notifications
You must be signed in to change notification settings - Fork 22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add options for controlling version sort and constraints behaviour #15
Comments
I agree that the current state is not ideal/sufficient and also agree that we should add a
Totally agree with you here - I didn't even realize go-version has this side effect. AFAICT we only use metadata to identify enterprise products (via i.e. if someone needs to run tests against latest Consul Enterprise, then they'll want to ignore non-enterprise releases, similarly if someone runs tests against OSS releases they will want to ignore Enterprise. With that in mind I'd propose It may be worth double checking if anyone planned any other use cases for metadata and consider |
There are also multiple types of enterprise release (e.g., https://releases.hashicorp.com/vault/1.7.3+ent.hsm/). If we want automated parsing of fields within the metadata, maybe we should include that in ENGSRV-069, even if mainly as a placeholder, like "enterprise builds must have |
@shore Thank you for the note - that's a useful example. I agree that some standardization of the metadata field would be useful. I don't have too strong opinion on this, but I think we can still have |
For posterity: After discussing this with @mmcquillan and @kmoe we decided to drop support for downloading/installing all Enterprise releases initially, as a precaution related to licensing and some upcoming work in that area. We can however revisit that decision later - it's always easier to add than remove things! 😄 #16 implements that decision |
Just wanted to bump this and note that we are going to have a need in the Consul API Gateway project of downloading a Consul Enterprise binary to test against, and would love the see the scope of hc-install expanded to include this. |
Consider the case in which the versions available are (in go-version sort order):
Calling
releases.LatestVersion
with a constraint of>1.0.0
will lead tov2.0.0+ent
being installed.This is produced by the following go-version phenomena, each of which may be something the user might want to control:
x.y.z+meta
is greater thanx.y.z
.We might want to provide some boolean options such as
IncludePrereleases
,IgnoreReleasesWithMetadata
, etc. These could be a property of theSource
or of an extendedConstraints
type.Sensible defaults will be important here. I think the
v2.0.0+ent
result is a bit unexpected and that releases with metadata should be excluded by default, but more research is needed.The text was updated successfully, but these errors were encountered: