| Lorenz Brun | c607bf6 | 2025-07-22 20:25:26 +0200 | [diff] [blame] | 1 | // Copyright The Monogon Project Authors. |
| 2 | // SPDX-License-Identifier: Apache-2.0 |
| 3 | |
| 4 | package cni |
| 5 | |
| 6 | // Opt doesn't do anything as all configuration is ignored. |
| 7 | type Opt func() error |
| 8 | |
| 9 | func noopOpt() error { |
| 10 | return nil |
| 11 | } |
| 12 | |
| 13 | func WithConf(bytes []byte) Opt { |
| 14 | return noopOpt |
| 15 | } |
| 16 | |
| 17 | func WithConfFile(fileName string) Opt { |
| 18 | return noopOpt |
| 19 | } |
| 20 | |
| 21 | func WithConfIndex(bytes []byte, index int) Opt { |
| 22 | return noopOpt |
| 23 | } |
| 24 | |
| 25 | func WithConfListBytes(bytes []byte) Opt { |
| 26 | return noopOpt |
| 27 | } |
| 28 | |
| 29 | func WithConfListFile(fileName string) Opt { |
| 30 | return noopOpt |
| 31 | } |
| 32 | |
| 33 | func WithInterfacePrefix(prefix string) Opt { |
| 34 | return noopOpt |
| 35 | } |
| 36 | |
| 37 | func WithMinNetworkCount(count int) Opt { |
| 38 | return noopOpt |
| 39 | } |
| 40 | |
| 41 | func WithPluginConfDir(dir string) Opt { |
| 42 | return noopOpt |
| 43 | } |
| 44 | |
| 45 | func WithPluginDir(dirs []string) Opt { |
| 46 | return noopOpt |
| 47 | } |
| 48 | |
| 49 | func WithPluginMaxConfNum(max int) Opt { |
| 50 | return noopOpt |
| 51 | } |
| 52 | |
| 53 | func WithDefaultConf() error { |
| 54 | return nil |
| 55 | } |
| 56 | func WithLoNetwork() error { |
| 57 | return nil |
| 58 | } |