Skip to content

armgit / Pulse

Public Imported from GitHub
0

Real-time monitoring dashboard for Proxmox VE, PBS, Docker, Kubernetes, TrueNAS and vSphere. Self-hosted, with alerts for failed backups, full disks, unhealthy containers and offline nodes.

407 B
Raw Blame
package licensing

import (
	"crypto/ed25519"
	"encoding/base64"
	"testing"
)

func installHostedEntitlementPublicKeyForTest(t *testing.T, pub ed25519.PublicKey) {
	t.Helper()

	encoded := base64.StdEncoding.EncodeToString(pub)
	embeddedBefore := EmbeddedPublicKey
	EmbeddedPublicKey = encoded
	t.Cleanup(func() { EmbeddedPublicKey = embeddedBefore })
	t.Setenv(HostedEntitlementPublicKeyEnvVar, encoded)
}