1
0
mirror of https://github.com/rancher/rke.git synced 2025-06-19 12:13:07 +00:00
rke/data/bindata.go

247 lines
360 KiB
Go
Raw Normal View History

2020-02-13 22:55:19 +00:00
// Code generated for package data by go-bindata DO NOT EDIT. (@generated)
// sources:
// data/data.json
package data
import (
"bytes"
"compress/gzip"
"fmt"
"io"
"io/ioutil"
"os"
"path/filepath"
"strings"
"time"
)
func bindataRead(data []byte, name string) ([]byte, error) {
gz, err := gzip.NewReader(bytes.NewBuffer(data))
if err != nil {
return nil, fmt.Errorf("Read %q: %v", name, err)
}
var buf bytes.Buffer
_, err = io.Copy(&buf, gz)
clErr := gz.Close()
if err != nil {
return nil, fmt.Errorf("Read %q: %v", name, err)
}
if clErr != nil {
return nil, err
}
return buf.Bytes(), nil
}
type asset struct {
bytes []byte
info os.FileInfo
}
type bindataFileInfo struct {
name string
size int64
mode os.FileMode
modTime time.Time
}
// Name return file name
func (fi bindataFileInfo) Name() string {
return fi.name
}
// Size return file size
func (fi bindataFileInfo) Size() int64 {
return fi.size
}
// Mode return file mode
func (fi bindataFileInfo) Mode() os.FileMode {
return fi.mode
}
// Mode return file modify time
func (fi bindataFileInfo) ModTime() time.Time {
return fi.modTime
}
// IsDir return file whether a directory
func (fi bindataFileInfo) IsDir() bool {
return fi.mode&os.ModeDir != 0
}
// Sys return file is sys mode
func (fi bindataFileInfo) Sys() interface{} {
return nil
}
2020-12-03 23:20:44 +00:00
var _dataDataJson = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\xbd\xeb\x72\xe3\x38\x92\x2f\xfe\x7d\x9f\x02\xe1\xda\x88\x9e\x9d\xbf\x29\x5b\xbe\x95\xcb\x1b\xfb\xc1\x65\xbb\xaa\x14\xed\xb2\x75\x2c\x57\xf5\x4c\xac\xe7\x78\x20\x12\x92\x78\x4c\x01\x6c\x82\x92\xcb\xdd\xd3\x27\xe6\x35\x4e\xc4\x39\x2f\x37\x4f\xf2\x0f\x5c\x78\x07\x25\x52\x96\x64\x5d\xd2\x1b\xb1\x53\x2d\xe2\x9a\x48\x64\x26\x12\x99\x3f\xfc\xfe\x6f\x68\xe7\xe7\x53\xfe\x9d\x04\xdc\x65\xb4\x43\x82\xb1\x6b\x93\x5b\x3f\x74\x19\xe5\x3b\x67\xe8\xf7\x7f\x43\x68\x67\xdc\x6c\x34\xf7\xf5\x7f\xa0\x1d\x12\xda\xce\xce\x19\xa2\x23\xcf\xdb\x95\x3f\x3c\x8d\xba\x04\xfb\x6e\x54\x00\xed\x60\xcf\x63\xcf\x96\x1f\xb8\x63\xd7\x23\x7d\x22\x4a\xef\x84\xc1\x88\xec\xec\xea\xef\x94\xd1\x97\x21\x1b\x71\x0b\x8f\xc2\x81\xf8\xda\xc3\x1e\x8f\x3f\x77\x5d\xea\x58\xd8\x71\x02\xc2\xc5\x10\x76\xf6\x1b\xf2\xff\xa2\xcf\x84\xe2\xae\x47\x2c\xec\x0c\x5d\x2e\xc6\x6c\xf9\xde\xa8\xef\xca\xd1\xee\xdc\xe0\x21\xe1\x3e\xb6\xc9\xb5\xdb\x23\xf6\x8b\xed\x91\xdd\x6b\x77\xe8\x86\x77\x98\xf6\x49\xb0\xab\xa7\x77\x6e\xdb\x6c\x44\xc3\xdd\x4b\xd2\xc3\x23\x2f\xec\x84\x2c\xc0\x7d\x72\xe1\x61\xce\xa3\xdf\xee\x99\x47\x02\x1c\x4a\x92\xd8\x8c\x3a\x7c\xf7\xeb\x28\xc4\xa1\x4b\xfb\xe7\x51\xbf\xbf\x90\xee\x80\xb1\xa7\xdd\xef\xd8\x73\x1d\xf3\xa7\x3b\xc2\xd9\x28\xb0\xc9\xff\x18\xb1\x10\xef\xde\x30\x87\xdc\x11\x1e\x06\xae\x2d\x1a\x8e\xe6\xe3\x52\x4e\xec\x51\x40\x2c\x9f\x05\xa1\x9c\x6f\xf4\x45\x10\xd6\x23\xa1\xe5\x07\xa4\x47\x82\x80\xc4\x54\xb1\xc2\x17\x9f\xc8\x09\xb7\x68\x48\x02\x8a\xbd\x56\x7b\xf7\xea\x47\xfc\xcf\x2f\x8c\x87\x14\x0f\x63\x8a\xfa\x01\xeb\xb9\x9e\x4b\xfb\x05\x5a\x07\xe4\xd7\x11\xe1\xe1\x80\x60\x87\x04\x16\xf9\x11\x06\xd8\x52\xff\xc1\x65\xb7\xee\x0f\x51\xe5\x2f\xd6\x1d\x19\xb2\x90\x58\x57\xb2\x80\xb9\x72\x3f\x60\x23\x3f\xaa\x9c\xa9\xf5\x59\x7c\x31\x57\x1a\x71\x31\xe6\x21\x31\xd6\xfb\xc6\x49\x10\x57\x1b\xd1\xd0\x1d\x12\xcb\x66\xb4\xe7\xca\x79\x08\xde\x61\x81\xfb\x9b\x5c\xa5\xc6\xd3\x29\x6f\xb8\x6c\x6f\xdc\xec\x92\x10\x37\xff\x2b\xcd\x6e\x39\xf2\x9e\x1c\x1d\x1d\x26\x9f\x24\x43\x58\x58\x71\x84\xe5\x31\xf6\x34\xf2\xf3\xfc\xca\x15\x83\x58\x5d\x6c\x3f\x11\x2a\xd9\x59\x6c\x82\xb8\x95\xd0\xe3\x96\xed\xfa\x03\x12\x58\x7c\xe4\x86\x6a\x65\xee\xaf\x3b\x8f\x57\x17\x97\x5f\xae\xc4\xff\xef\x9c\x3f\xfe\xd2\xba\xff\xf2\x78\x7e\xd5\x79\x6c\x1e\x9c\x3e\x7e\xbe\xf8\xfa\xd8\xf9\x72\x7e\x70\x7c\xb2\x5b\x5a\xee\xe0\xf8\x24\x2a\x77\x78\x7a\x64\x2e\x77\xf1\xe5\xfc\xe2\xcb\xf9\xc1\xfe\x63\xfb\xf6\xfa\xaf\xcd\xc3\xfd\xe3\x54\xb1\xbb\x4a\x9d\xde\x55\xea\xf2\xae\xb4\xc3\x1d\x41\x82\x3f\x12\x41\xe0\x91\x30\x25\x08\x4a\x37\xf1\x2b\x45\x84\xf8\x91\xd0\xd0\xb5\xe5\xe2\x5b\x21\x7b\x22\xd4\x7a\x56\xbb\xae\xd0\x54\x9a\x4f\xac\x21\x73\x88\x28\xa1\xb7\x68\x54\xc8\x96\xdc\xcb\x2d\x9f\x04\xd6\xaf\x4c\x2d\x60\xaa\x0d\x9b\xba\x56\xd7\xa5\x96\xe3\x06\xe2\xd3\x1e\xf3\xc3\x3d\x9b\xba\x7b\x5d\x97\xa6\x8b\x08\xe6\x8c\xcb\x90\xd0\x96\x65\x28\x09\x1b\x4e\x22\xbc\x7a\x2c\xb0\x89\x45\x99\x43\x2c\x41\x04\x1b\x87\x42\x9c\x89\x1a\x71\x99\x31\xa1\xa1\xf5\xab\xcf\x33\xc2\x60\x88\x9f\x88\xe5\xfa\xb2\x34\xb7\x46\xa1\xeb\x59\xf6\x00\x6b\xb9\x97\x9e\x2f\x25\xe1\x33\x0b\x9e\xb4\x58\x14\x5f\x6d\xea\x26\xbb\x0f\x3b\x16\xa3\xde\x4b\x51\xda\x04\x84\x33\x6f\x2c\xe7\x10\x8f\x5f\xfd\xd6\x90\xbf\xc5\x9b\x21\x20\x78\xe8\xd2\xbe\x28\x49\x89\x14\x65\x96\xeb\x78\xc4\x12\xfb\x93\x8d\x64\xa3\x87\xfb\x43\xd8\x1c\xfb\xc7\x11\x0d\xc6\x62\xce\x07\xf1\x7f\x31\x6f\x34\x24\x7a\x7d\x62\x76\x19\xe3\x60\xcf\x73\xbb\x7b\x7a\x13\xed\xa9\x52\x91\x6e\xcb\xed\x32\x3f\x60\x3f\x5e\x92\x7d\x36\x20\xd8\x0b\x07\xbf\x59\x79\xcd\xd9\x3c\x78\x2f\xb7\x5d\x33\x37\x90\x5c\x6b\x17\x8c\x86\x01\xf3\x3c\x12\x54\xdd\xba\x36\x0e\x35\x0f\xdb\xae\x13\x14\x58\x50\xed\xee\x11\x0d\x71\xbf\x4f\x1c\xcb\xf6\xd8\xa8\xb0\xc3\x95\x20\x17\x82\x59\x7e\xb6\x02\x36\xd2\xcc\x91\xd9\xe9\x5a\xdb\x0f\x18\x0f\x7d\x1c\x0e\x2c\x3f\x60\x63\x57\xe8\x58\x39\xd8\x6c\x59\x4f\x6b\x31\x8f\xd8\x61\x61\x57\x88\xc1\x0e\x19\x75\x43\x26\x54\x15\xb6\x89\xd8\xeb\x2e\x93\xe3\x3a\xda\xe7\xb1\xaa\x64\x8e\x45\xc6\x4a\x43\xa7\x39\xfa\x78\x98\x2a\x53\xaa\x4e\x43\x12\x0c\x5d\x8a\x43\xe2\x58\xa2\xa1\xbe\x6d\x85\x83\x80\xf0\x01\xf3\x64\x3f\xcd\xfd\xfd\xfd\xf2\xa
2020-02-13 22:55:19 +00:00
func dataDataJsonBytes() ([]byte, error) {
return bindataRead(
_dataDataJson,
"data/data.json",
)
}
func dataDataJson() (*asset, error) {
bytes, err := dataDataJsonBytes()
if err != nil {
return nil, err
}
2020-12-03 23:20:44 +00:00
info := bindataFileInfo{name: "data/data.json", size: 1214614, mode: os.FileMode(420), modTime: time.Unix(1557785965, 0)}
2020-02-13 22:55:19 +00:00
a := &asset{bytes: bytes, info: info}
return a, nil
}
// Asset loads and returns the asset for the given name.
// It returns an error if the asset could not be found or
// could not be loaded.
func Asset(name string) ([]byte, error) {
cannonicalName := strings.Replace(name, "\\", "/", -1)
if f, ok := _bindata[cannonicalName]; ok {
a, err := f()
if err != nil {
return nil, fmt.Errorf("Asset %s can't read by error: %v", name, err)
}
return a.bytes, nil
}
return nil, fmt.Errorf("Asset %s not found", name)
}
// MustAsset is like Asset but panics when Asset would return an error.
// It simplifies safe initialization of global variables.
func MustAsset(name string) []byte {
a, err := Asset(name)
if err != nil {
panic("asset: Asset(" + name + "): " + err.Error())
}
return a
}
// AssetInfo loads and returns the asset info for the given name.
// It returns an error if the asset could not be found or
// could not be loaded.
func AssetInfo(name string) (os.FileInfo, error) {
cannonicalName := strings.Replace(name, "\\", "/", -1)
if f, ok := _bindata[cannonicalName]; ok {
a, err := f()
if err != nil {
return nil, fmt.Errorf("AssetInfo %s can't read by error: %v", name, err)
}
return a.info, nil
}
return nil, fmt.Errorf("AssetInfo %s not found", name)
}
// AssetNames returns the names of the assets.
func AssetNames() []string {
names := make([]string, 0, len(_bindata))
for name := range _bindata {
names = append(names, name)
}
return names
}
// _bindata is a table, holding each asset generator, mapped to its name.
var _bindata = map[string]func() (*asset, error){
"data/data.json": dataDataJson,
}
// AssetDir returns the file names below a certain
// directory embedded in the file by go-bindata.
// For example if you run go-bindata on data/... and data contains the
// following hierarchy:
// data/
// foo.txt
// img/
// a.png
// b.png
// then AssetDir("data") would return []string{"foo.txt", "img"}
// AssetDir("data/img") would return []string{"a.png", "b.png"}
// AssetDir("foo.txt") and AssetDir("notexist") would return an error
// AssetDir("") will return []string{"data"}.
func AssetDir(name string) ([]string, error) {
node := _bintree
if len(name) != 0 {
cannonicalName := strings.Replace(name, "\\", "/", -1)
pathList := strings.Split(cannonicalName, "/")
for _, p := range pathList {
node = node.Children[p]
if node == nil {
return nil, fmt.Errorf("Asset %s not found", name)
}
}
}
if node.Func != nil {
return nil, fmt.Errorf("Asset %s not found", name)
}
rv := make([]string, 0, len(node.Children))
for childName := range node.Children {
rv = append(rv, childName)
}
return rv, nil
}
type bintree struct {
Func func() (*asset, error)
Children map[string]*bintree
}
var _bintree = &bintree{nil, map[string]*bintree{
"data": &bintree{nil, map[string]*bintree{
"data.json": &bintree{dataDataJson, map[string]*bintree{}},
}},
}}
// RestoreAsset restores an asset under the given directory
func RestoreAsset(dir, name string) error {
data, err := Asset(name)
if err != nil {
return err
}
info, err := AssetInfo(name)
if err != nil {
return err
}
err = os.MkdirAll(_filePath(dir, filepath.Dir(name)), os.FileMode(0755))
if err != nil {
return err
}
err = ioutil.WriteFile(_filePath(dir, name), data, info.Mode())
if err != nil {
return err
}
err = os.Chtimes(_filePath(dir, name), info.ModTime(), info.ModTime())
if err != nil {
return err
}
return nil
}
// RestoreAssets restores an asset under the given directory recursively
func RestoreAssets(dir, name string) error {
children, err := AssetDir(name)
// File
if err != nil {
return RestoreAsset(dir, name)
}
// Dir
for _, child := range children {
err = RestoreAssets(dir, filepath.Join(name, child))
if err != nil {
return err
}
}
return nil
}
func _filePath(dir, name string) string {
cannonicalName := strings.Replace(name, "\\", "/", -1)
return filepath.Join(append([]string{dir}, strings.Split(cannonicalName, "/")...)...)
}