Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found
Select Git revision

Target

Select target project
  • danet/gosdn
1 result
Select Git revision
Show changes
Commits on Source (7)
......@@ -41,6 +41,7 @@ Any device directly configured by `goSDN`
You can install the latest release of `goSDN` locally using the `go get` command. Since the repository and some dependencies are not publicly available you have to modify your git config first:
```sh
> git config --global url."git@code.fbi.h-da.de:".insteadOf "https://code.fbi.h-da.de"
> go env -w GOPRIVATE=code.fbi.h-da.de/cocsn/*
> go get code.fbi.h-da.de/cocsn/gosdn/cmd/gosdn
```
......@@ -48,6 +49,7 @@ To install the development version you need to clone the repo and use `go instal
```sh
# If you haven't cloned the repo yet
> git config --global url."git@code.fbi.h-da.de:".insteadOf "https://code.fbi.h-da.de"
> go env -w GOPRIVATE=code.fbi.h-da.de/cocsn/*
> cd $GOPATH/src
> git clone git@code.fbi.h-da.de:cocsn/gosdn.git
......
......@@ -117,7 +117,9 @@ func DialContext(ctx context.Context, cfg *Config) (pb.GNMIClient, error) {
}
if cfg.TLS || cfg.CAFile != "" || cfg.CertFile != "" || cfg.Token != "" {
tlsConfig := &tls.Config{}
tlsConfig := &tls.Config{
MinVersion: tls.VersionTLS12,
}
if cfg.CAFile != "" {
b, err := ioutil.ReadFile(cfg.CAFile)
if err != nil {
......
......@@ -17,7 +17,7 @@ func Write(message proto.Message, filename string) error {
return fmt.Errorf("cannot marshal proto message to binary: %w", err)
}
err = ioutil.WriteFile(filename, data, 0644)
err = ioutil.WriteFile(filename, data, 0600)
if err != nil {
return fmt.Errorf("cannot write binary data to file: %w", err)
}
......
......@@ -16,8 +16,8 @@ import (
const unreachable = "203.0.113.10:6030"
var testAddress = "141.100.70.171:6030"
var testAPIEndpoint = "http://141.100.70.171:8080/api"
var testAddress = "141.100.67.238:6030"
var testAPIEndpoint = "http://gosdn-latest.apps.ocp.fbi.h-da.de/api"
var testUsername = "admin"
var testPassword = "arista"
var defaultPath = []string{"/system/config/hostname"}
......@@ -42,17 +42,17 @@ func testSetupIntegration() {
api := os.Getenv("GOSDN_TEST_API_ENDPOINT")
if api != "" {
testAPIEndpoint = api
log.Infof("GOSDN_TEST_API_ENDPOINT set to %v", testAddress)
log.Infof("GOSDN_TEST_API_ENDPOINT set to %v", testAPIEndpoint)
}
u := os.Getenv("GOSDN_TEST_USER")
if u != "" {
testUsername = u
log.Infof("GOSDN_TEST_USER set to %v", testAddress)
log.Infof("GOSDN_TEST_USER set to %v", testUsername)
}
p := os.Getenv("GOSDN_TEST_PASSWORD")
if p != "" {
testPassword = p
log.Infof("GOSDN_TEST_PASSWORD set to %v", testAddress)
log.Infof("GOSDN_TEST_PASSWORD set to %v", testPassword)
}
gnmiMessages = map[string]pb.Message{
......@@ -78,8 +78,8 @@ func testSetupIntegration() {
opt = &nucleus.GnmiTransportOptions{
Config: gnmi.Config{
Addr: testAddress,
Username: "admin",
Password: "arista",
Username: testUsername,
Password: testPassword,
Encoding: gpb.Encoding_JSON_IETF,
},
RespChan: make(chan *gpb.SubscribeResponse),
......