1
0
mirror of https://github.com/rancher/rke.git synced 2025-07-05 03:28:08 +00:00
rke/data/bindata.go

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