Skip to content

Commit

Permalink
add default root user for srl
Browse files Browse the repository at this point in the history
  • Loading branch information
hellt committed Jan 26, 2021
1 parent 77ad5ae commit 96531d7
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 96531d7

Please sign in to comment.