1
0
mirror of https://github.com/rancher/rke.git synced 2025-07-11 14:23:42 +00:00
rke/data/bindata.go

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