Skip to content

licensing: fix setup for creating license keys locally and for testing features in a local instance

Administrator requested to merge mv/license-key into main

Created by: miveronese

This PR fixes the setup for generating license keys locally, so we can manually test, in a local instance, if a feature are available or not depending on the plan used.

Documentation on how to generate a license key locally and how to test a new feature will be added in the next PR.

Test plan

Manually tested that we can successfully generated a license key with the following steps

  1. go run ./enterprise/internal/license/generate-license.go -private-key ../dev-private/enterprise/dev/test-license-generation-key.pem -tags=plan:team-0 -users=10 -expires=8784h . (You can replace the team-0 with other plans)

  2. added the new license key to our dev-private site configuration; restarted SG.

  3. when the repo-updater called  licensing.Check(licensing.FeatureACLs) (in perms_syncer.go), the crypto/rsa: verification error wasn't displayed anymore and all worked as expected.

Merge request reports

Loading