f-14: bin: remove netns bin #14
Signed-off-by: GnomeZworc <nicolas.boufidjeline@g3e.fr>
This commit is contained in:
parent
d050568638
commit
0b797d1c0c
2 changed files with 0 additions and 41 deletions
|
|
@ -37,7 +37,6 @@ jobs:
|
||||||
- metadata
|
- metadata
|
||||||
- metacli
|
- metacli
|
||||||
- agent
|
- agent
|
||||||
- netns
|
|
||||||
uses: ./.forgejo/workflows/build.yml
|
uses: ./.forgejo/workflows/build.yml
|
||||||
with:
|
with:
|
||||||
tag: ${{ needs.set-release-target.outputs.release_cible }}
|
tag: ${{ needs.set-release-target.outputs.release_cible }}
|
||||||
|
|
|
||||||
|
|
@ -1,40 +0,0 @@
|
||||||
package main
|
|
||||||
|
|
||||||
import (
|
|
||||||
"flag"
|
|
||||||
"fmt"
|
|
||||||
"os"
|
|
||||||
|
|
||||||
"git.g3e.fr/syonad/two/internal/netns"
|
|
||||||
)
|
|
||||||
|
|
||||||
var (
|
|
||||||
netns_name = flag.String("netns", "", "Network namespace à faire")
|
|
||||||
action = flag.String("action", "", "Action a faire")
|
|
||||||
)
|
|
||||||
|
|
||||||
func main() {
|
|
||||||
flag.Parse()
|
|
||||||
|
|
||||||
switch *action {
|
|
||||||
case "create":
|
|
||||||
err := netns.Create(*netns_name)
|
|
||||||
if err != nil {
|
|
||||||
fmt.Println(err)
|
|
||||||
}
|
|
||||||
case "delete":
|
|
||||||
err := netns.Delete(*netns_name)
|
|
||||||
if err != nil {
|
|
||||||
fmt.Println(err)
|
|
||||||
}
|
|
||||||
case "check":
|
|
||||||
if netns.Exist(*netns_name) {
|
|
||||||
fmt.Printf("netns %s exist\n", *netns_name)
|
|
||||||
} else {
|
|
||||||
fmt.Printf("netns %s do not exist\n", *netns_name)
|
|
||||||
}
|
|
||||||
default:
|
|
||||||
fmt.Printf("Available commande:\n - create\n - delete\n - check\n")
|
|
||||||
os.Exit(1)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue