This directory contains jsonnet helpers to configure envlinks instances.
Using jsonnet-bundler:
jb install github.com/maxhollmann/envlinks/envlinks-jsonnet@v0.3.1
local envlinks = import 'envlinks-jsonnet/helpers.libsonnet';
local env = envlinks.config(
title='My links',
links=[
envlinks.link('Google', 'https://google.com', icon='google'),
envlinks.link('Wikipedia', 'https://wikipedia.com', icon='wikipedia'),
],
);
env
now contains an object with environment variables that can be used with e.g. k8s-libsonnet's withEnvMap.
envlinks.config
automatically adds LINK_*_INDEX
variables to keep the order of the links as given in the links
array.