1
0
mirror of https://github.com/rancher/rke.git synced 2025-06-29 08:47:53 +00:00
rke/data/bindata.go

247 lines
3.4 MiB
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
}
2024-03-27 18:01:35 +00:00
var _dataDataJson = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xec\xbd\x5b\x73\xa4\xb8\x9a\xef\x7d\xbf\x3e\x05\xe1\x7d\xd1\xef\x3b\x51\xa4\xf3\xec\x43\xc4\x5c\x54\xdb\xd5\xd5\x8e\xae\x72\x79\xec\xea\x9e\xbd\x62\xbc\xc2\x81\x41\x99\x66\x99\x04\x1a\x48\x57\xb9\x6b\xfa\xbb\xef\x90\x38\x83\x20\x25\x20\xd3\x79\xf8\x7b\x22\x66\x75\x25\x3a\x21\xc4\x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\x5e\x5d\xc2\x6e\xf8\xca\x0e\x88\x67\x6b\xd6\xd5\xcd\xbb\x0f\xdf\x93\xff\xfc\xd5\xf1\x03\x5b\x5b\x24\x3d\xea\x7a\xce\xcc\xb4\x4c\x7b\x5e\xea\x6b\x8f\xfc\xb9\x24\x7e\xf0\x44\x34\x83\x78\x2a\xf9\x1e\x78\x9a\x1a\xfe\xc3\x67\xd5\x9a\xdf\x69\x96\xff\xab\xde\x92\x85\x13\x10\xf5\x03\x4b\xc0\xcf\x3c\xf7\x9c\xa5\x1b\x67\xce\xe5\xfa\x48\xaf\xf0\x33\x2d\x7d\xda\xe6\x05\xe1\xe6\xfb\xdd\x27\x5e\x92\x6d\x69\x07\xe6\x82\xa8\xba\x63\xcf\x4c\x76\x1f\x74\xec\x38\x9e\xf9\x17\x7b\x4a\xbd\xe7\x53\xbf\x67\x3a\xc7\x2f\x83\x47\x12\x68\x83\xff\xcc\x0e\xb7\x42\xf7\x4e\xc7\xe3\x51\x7a\x89\x0d\x08\x55\x0b\x47\x84\x6a\x39\xce\xf3\xd2\x2d\x8e\x57\x3f\x1c\x20\xea\xa3\xa6\x3f\x13\x9b\x0d\x67\xfa\x12\x24\xa5\x04\x96\xaf\xea\xa6\xfb\x44\x3c\xd5\x5f\x9a\x41\xf8\x64\xbe\x7e\xba\x7b\xf8\x70\x71\xf9\xeb\x07\xfa\xff\xef\xde\x3f\xfc\xf7\xd5\xd7\x5f\x1f\xde\x7f\xb8\x7b\x18\x0c\x4f\x1f\x3e\x5e\x7c\x7e\xb8\xfb\xf5\xfd\x70\x32\x7d\x57\x99\x6e\x38\x99\xc6\xe9\x46\xa7\x63\x7e\xba\x8b\x5f\xdf\x5f\xfc\xfa\x7e\xd8\x7f\xb8\xf9\xf2\xe9\x9f\x83\x51\x7f\x92\x49\x76\x2b\x54\xe9\xad\x50\x95\xb7\x95\x15\x1e\xd1\x2e\xf8\x3b\x35\x04\x16\x09\x32\x86\xa0\xf2\x25\x6e\x69\x22\xe8\x8f\xc4\x0e\x4c\x9d\x3d\x7c\x35\x70\x9e\x89\xad\x7e\x0b\xdf\xba\x52\x51\xd9\x71\xa2\x2e\x1c\x83\xd0\x14\xd1\x2b\x1a\x27\xd2\xd9\xe8\xf5\x55\x97\x78\xea\x9f\x4e\xf8\x00\x33\x65\xe8\xb6\xa9\x3e\x9a\xb6\x6a\x98\x1e\xbd\x74\xec\xb8\xc1\xb1\x6e\x9b\xc7\x8f\xa6\x9d\x4d\x42\x07\x67\x92\x86\x04\x3a\x4b\x63\x93\xa0\x67\xa4\xc6\x6b\xe6\x78\x3a\x51\x6d\xc7\x20\x2a\xed\x04\x5d\x0b\xa8\x39\xa3\x39\x92\x34\x2f\xc4\x0e\xd4\x3f\x5d\x3f\x67\x0c\x16\xda\x33\x51\x4d\x97\xa5\xf6\xd5\x65\x60\x5a\xaa\xfe\xa4\x45\x76\x2f\x7b\xbf\x36\x09\xbe\x39\xde\x73\x64\x16\xe9\x55\xdd\x36\xd3\xb7\x4f\x33\x54\xc7\xb6\x5e\xcb\xd6\xc6\x23\xbe\x63\xbd\xb0\x7b\x48\xda\x1f\xfe\xd6\x63\xbf\x25\x2f\x83\x47\xb4\x85\x69\xcf\x69\x4a\x9b\x30\x53\xa6\x9a\x86\x45\x54\xfa\x7e\x3a\x4b\x56\xe8\xa8\xbf\xc0\xcb\xd1\x9f\xc4\x7d\xf0\x42\xef\x79\x98\xfc\xcb\xb1\x96\x0b\x12\x3d\x9f\x64\xb8\xbc\x68\xde\xb1\x65\x3e\x1e\x47\x2f\xd1\x71\x98\x2a\xd6\xb6\xc2\x5b\xe6\x7a\xce\xf7\xd7\xf4\x3d\x7b\x22\x9a\x15\x3c\xfd\xa5\x16\x95\x73\x30\x3c\x61\xaf\xdd\xa0\xd0\x90\x42\x69\x17\x8e\x1d\x78\x8e\x65\x11\x4f\xf4\xd5\xd5\xb5\x20\x1a\xc3\xba\x69\x78\xa5\x21\x18\xbe\xdd\x4b\x3b\xd0\xe6\x73\x62\xa8\xba\xe5\x2c\x4b\x6f\x78\x68\xc8\xa9\x61\x66\x97\x55\xcf\x59\x46\x83\x23\xf7\xa6\x47\x6a\xff\xe4\xf8\x81\xab\x05\x4f\xaa\xeb\x39\x2f\x26\xd5\x58\xd6\xd8\x7c\x5a\x2b\x52\x31\x8b\xe8\x41\xe9\xad\xa0\x8d\x5d\x38\xb6\x19\x38\x54\xaa\x34\x9d\xd0\x77\xdd\x74\x58\xbb\xc6\x7d\x3f\x91\x4a\xc7\x50\xc9\x4b\xa8\xd0\xd9\x11\x3d\x59\x64\xd2\x54\xca\x69\x4
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
}
2024-03-27 18:01:35 +00:00
info := bindataFileInfo{name: "data/data.json", size: 8461833, 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, "/")...)...)
}