This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "encoding/json" | |
| "fmt" | |
| "log" | |
| "time" | |
| ) | |
| // Fulldata - test |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @Grab( 'com.ecwid.consul:consul-api:1.2.4' ) | |
| import com.ecwid.consul.v1.* | |
| client = new ConsulClient("172.20.20.10:8500") | |
| setvalue("Abskey", "Absvalue") | |
| println getvalue("Abskey") | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "containers": [{ | |
| "path": "pathA", | |
| "components": [{ | |
| "image": "Image1", | |
| "name": "Name1" | |
| }] | |
| }, | |
| { | |
| "path": "pathB", |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| func removeDuplicates(elements []string) []string { // change string to int here if required | |
| // Use map to record duplicates as we find them. | |
| encountered := map[string]bool{} // change string to int here if required | |
| result := []string{} // change string to int here if required | |
| for v := range elements { | |
| if encountered[elements[v]] == true { | |
| // Do not add duplicate. | |
| } else { | |
| // Record this element as an encountered element. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "encoding/json" | |
| "fmt" | |
| "log" | |
| ) | |
| // Deployment - | |
| type Deployment struct { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "fmt" | |
| "strings" | |
| ) | |
| var ( | |
| word = "test" | |
| reversedstringarray []string |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Charts: | |
| name: foo | |
| repo: foo.com | |
| tags: realtag |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| APIKEYFILE=~/.minikube/apiserver.key | |
| APICERTFILE=~/.minikube/apiserver.crt | |
| CAFILE=~/.minikube/ca.crt | |
| curl https://192.168.99.100:8443/api/v1/namespaces \ | |
| --key $APIKEYFILE \ | |
| --cert $APICERTFILE \ | |
| --cacert $CAFILE |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "log" | |
| "gopkg.in/src-d/go-git.v4/plumbing" | |
| "gopkg.in/src-d/go-git.v4" | |
| ) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| package main | |
| import ( | |
| "fmt" | |
| "gopkg.in/yaml.v2" | |
| ) | |
| type T struct { | |
| Charts []struct { |