28 lines
616 B
Go
28 lines
616 B
Go
package executor
|
|
|
|
import "testing"
|
|
|
|
var agentOP = AgentOsOperator{
|
|
InstallCommandPrefix: []string{
|
|
"apt-get", "install", "-y",
|
|
},
|
|
RemoveCommandPrefix: []string{"apt", "remove", "-y"},
|
|
CanAccessInternet: true,
|
|
IsOsTypeUbuntu: true,
|
|
IsAgentInnerWall: true,
|
|
AgentArch: "amd64",
|
|
AgentOSReleaseCode: "focal",
|
|
}
|
|
|
|
func TestBaseFunc(t *testing.T) {
|
|
|
|
//agentOP.Exec("shutdownFirewall")
|
|
//agentOP.Exec("modifyHostname")
|
|
//agentOP.Exec("disableSwap")
|
|
//agentOP.Exec("enableSwap")
|
|
//agentOP.Exec("removeDocker")
|
|
//agentOP.Exec("installDocker", "20")
|
|
agentOP.Exec("installDockerCompose")
|
|
|
|
}
|