Skip to content

Commit

Permalink
Merge pull request #247 from srl-wim/srl-root-user
Browse files Browse the repository at this point in the history
add default root user for srl
  • Loading branch information
hellt authored Jan 26, 2021
2 parents 876cf69 + 81eb24f commit 1206ead
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion clab/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -449,11 +449,15 @@ func (c *CLab) NewNode(nodeName string, nodeCfg NodeConfig, idx int) error {
}

// initialize specifc container information
node.Cmd = "sudo bash -c /opt/srlinux/bin/sr_linux"
node.Cmd = "sudo sr_linux"

kindEnv := map[string]string{"SRLINUX": "1"}
node.Env = mergeStringMaps(kindEnv, envs)

// if user was not initialized to a value, use root
if user == "" {
user = "0:0"
}
node.User = user

node.Sysctls = make(map[string]string)
Expand Down

0 comments on commit 1206ead

Please sign in to comment.