Documentation
¶
Overview ¶
Copyright 2024 Michael Vittrup Larsen
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
Index ¶
- func CsvToList(in string) []string
- func LookupAuthSecret(secretName, namespace string, rl *fn.ResourceList) (username, password string, err error)
- func LookupAuthSecretWithKeys(secretName, namespace, usernameKey, passwordKey string, rl *fn.ResourceList) (username, password string, err error)
- func LookupSSHAuthSecret(secretName, namespace string, rl *fn.ResourceList) (username, password string, err error)
- func MergeMaps[M ~map[K]V, K comparable, V any](m1, m2 M) M
- func ResultPrintf(fnResults *fn.Results, sev fn.Severity, format string, a ...any)
- func UniqueStrings(list []string) []string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func LookupAuthSecret ¶
func LookupAuthSecret(secretName, namespace string, rl *fn.ResourceList) (username, password string, err error)
LookupAuthSecret will lookup a secret in a resourcelist and return username and password decoded from secret
func LookupAuthSecretWithKeys ¶
func LookupAuthSecretWithKeys(secretName, namespace, usernameKey, passwordKey string, rl *fn.ResourceList) (username, password string, err error)
LookupAuthSecretWithKeys will lookup a secret in a resourcelist and return username and password decoded from secret with the username and password being defined by supplied key names
func LookupSSHAuthSecret ¶
func LookupSSHAuthSecret(secretName, namespace string, rl *fn.ResourceList) (username, password string, err error)
LookupSSHAuthSecret will lookup an SSH secret in a resourcelist and return username and password decoded from secret
func MergeMaps ¶
func MergeMaps[M ~map[K]V, K comparable, V any](m1, m2 M) M
MergeMaps will merge m1 and m2 with precedence to m2
func ResultPrintf ¶
func UniqueStrings ¶
UniqueStrings removes duplicate strings from slice
Types ¶
This section is empty.