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