• Stars
    star
    3
  • Rank 3,963,521 (Top 79 %)
  • Language
    Go
  • License
    Apache License 2.0
  • Created over 3 years ago
  • Updated almost 3 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

open source for accessing and storing configuration

Go Report Card License test coverage badge Gitter


simple-config.png logo

go-simple-config

Go Simple config is an open source configuration lib for storing and accessing configuration data with minimal dependencies

Installation

go get github.com/chen-keinan/go-simple-config

Supported configuration files:

  • yaml
  • json
  • properties
  • environment variables
  • ini

Usage

json config example:

{
  "SERVER": {
    "host": "127.0.0.1",
    "port": "8080"
  }

yaml config example:

---
SERVER:
  host: 127.0.0.1
  port: '8080'

properties config example:

SERVER.host=127.0.0.1
SERVER.port=8080

env. variable config example:

export SERVER_HOST="127.0.0.1"
export SERVER_PORT="8080"

Full example :

package main

import (
	"fmt"
	"github.com/chen-keinan/go-simple-config/simple"
	"os"
)

func main() {
	c := simple.New()
	err := c.Load("config.json")

	if err != nil {
		fmt.Print(err.Error())
		os.Exit(1)
	}
	fmt.Print(c.GetStringValue("SERVER.host"))
}

More Repositories

1

kube-beacon

Open Source runtime scanner for k8s cluster and perform security audit checks based on CIS Kubernetes Benchmark specification
Go
62
star
2

kube-knark

Open Source runtime tool which help to detect malware code execution and run time mis-configuration change on a kubernetes cluster
Go
32
star
3

mesh-kridik

mesh-kridik is an open-source security checker that performs various security checks on a Kubernetes cluster with istio service mesh and is leveraged by OPA (Open Policy Agent) to enforce security rules.
Go
22
star
4

lxd-probe

Open Source runtime scanner for Linux containers (LXD / LXC), It performs security audit checks based on CIS Linux containers Benchmark specification
Go
16
star
5

go-opa-validate

go-opa-validate is an open-source lib that evaluates OPA (open policy agent) policy against JSON or YAML data.
Go
6
star
6

openshift-ordeal

Open Source runtime scanner for OpenShift cluster and perform security audit checks based on CIS RedHat OpenShift Benchmark specification
Go
5
star
7

npm-dep-tree

Go
4
star
8

go-archive-extractor

open source lib for extracting most common archives with diffrents compressions
Go
4
star
9

go-user-plugins

Go
3
star
10

go-command-eval

Go-command-eval is an open-source which helps to execute a shell command and evaluate it results in a flexible ways
Go
3
star
11

go-license-discovery

The license discovery is an open-source lib and set of tools that can analyze license text to determine what type of license it contains.
Go
3
star
12

oci-runtime

Go
1
star
13

ebpf-vagrantfile

Shell
1
star
14

k8s-outdated

Go
1
star
15

kubernetes-vagrantfile

Shell
1
star
16

go-Intenal-Queue

Go
1
star