mirror of
https://github.com/hasura/graphql-engine.git
synced 2024-12-15 01:12:56 +03:00
- do not quit on server-cli version mismatch, show warning - fix a bug in update-cli command which prevets updates to pre-release versions - if a console template for a particular version is not found, use the latest template
This commit is contained in:
parent
265cf7f12e
commit
f6a43fe3ba
@ -1,5 +1,6 @@
|
|||||||
// Code generated by go-bindata.
|
// Code generated by go-bindata.
|
||||||
// sources:
|
// sources:
|
||||||
|
// assets/latest/console.html
|
||||||
// assets/unversioned/console.html
|
// assets/unversioned/console.html
|
||||||
// assets/v1.0-alpha/console.html
|
// assets/v1.0-alpha/console.html
|
||||||
// assets/v1.0/console.html
|
// assets/v1.0/console.html
|
||||||
@ -70,6 +71,26 @@ func (fi bindataFileInfo) Sys() interface{} {
|
|||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
var _assetsLatestConsoleHtml = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xac\x56\xdf\x6f\xdb\xb6\x13\x7f\xcf\x5f\x71\xe0\x17\x5f\xf4\x65\x22\x9d\xae\xc0\x0a\xd9\x0a\x50\xac\x18\x36\x6c\x03\x02\xb4\xd9\x6b\xc0\x50\x27\xe9\x52\x8a\xd4\x78\xb4\x13\xd7\xf0\xff\x3e\xe8\xb7\xec\x64\x4d\x57\x14\x7e\x21\xef\xf7\xe7\x73\xc7\x93\x37\x55\xac\x2d\x58\xed\xca\x4c\xa0\x4b\xb6\x2c\xae\x2e\x00\x36\x15\xea\xbc\x3d\x00\x6c\x2c\xb9\x4f\x10\xd0\x66\x82\x8c\x77\x02\xe2\xbe\xc1\x4c\x50\xad\x4b\x54\x8d\x2b\x05\x54\x01\x8b\x4c\x54\x31\x36\x9c\x2a\x55\x06\xdd\x54\x7f\xdb\x04\x5d\x49\x0e\x13\x93\x3b\x59\x69\xde\x06\x2d\xc9\x2b\xe3\x1d\x7b\x8b\x4a\x33\x63\x64\x65\x7c\x5d\x7b\xa7\xa8\x2e\x55\xa1\x77\x6d\xf8\xdb\x32\x20\x3a\xd9\xc5\x55\x43\x01\x6c\x02\x35\xb1\xbf\x00\x3c\x90\xcb\xfd\x83\xbc\xbd\x45\xb7\x83\x0c\x0e\x83\x18\x40\x37\xf4\xab\xe7\x98\xc2\xe1\x20\x87\xf3\xf1\xf8\xc3\x52\x7d\xed\x43\x4c\x41\xf4\xfa\xf6\x72\x3c\x8a\xd9\xc0\x58\xfa\x0b\x03\x93\x77\x5d\x88\xf9\xba\x8c\x92\xeb\xa8\xdf\x35\x74\x13\x6c\x67\x34\x5f\x9f\x31\x5a\x46\x3b\x15\x2d\x8d\x0f\x87\x04\xa8\x80\x96\xa4\x77\xc6\x20\xf3\xef\xb8\x87\xe3\x71\xae\x7b\x14\xf6\xc0\xf2\x9a\xdc\x07\x34\x01\xe3\x69\x10\x40\xcb\x78\xe2\x37\x5b\xbe\xe4\xe9\x72\x48\x16\x9e\xdb\x60\xaf\x03\x16\xf4\x98\x82\x50\x4b\x82\xfa\xe6\xfd\xe9\x73\x4c\x41\x18\x4b\xa7\xe4\xdd\xdc\xfc\xf6\x7e\x64\xae\x3d\x2f\xb3\xa0\xd3\x77\x16\x3f\xa2\xc5\x1a\x63\xe8\xa1\x9c\xc9\x4e\x7a\xd5\x8d\xc7\xb5\x8e\x55\x0a\xdf\x32\x58\x8b\xc2\x18\xc3\x0e\xc3\xd4\x8a\xb6\xf9\x27\xa2\xc5\x08\x1c\xd7\xfd\xbc\xa9\x79\xe0\x36\x6a\x7c\x08\x9b\x3b\x9f\xef\xc7\x81\x8c\x7b\x8b\xfd\x59\xd6\x9a\xdc\xcf\xde\x45\x74\x71\x9a\xc5\x9c\xb8\xb1\x7a\x9f\xc2\x2b\xe7\x1d\xbe\x5a\x0f\x62\xdf\x68\x43\x71\x9f\xc2\x6a\x94\xc4\xa0\x1d\x53\xec\x2a\x1b\xb4\x20\x5f\xaf\x18\x2c\x39\xd4\xa1\x37\x3b\x3e\x49\x24\xb9\xf2\x0f\xcf\x64\xbb\xb3\xde\x7c\x7a\x9a\xee\xf2\x1b\xd2\x6d\xd4\x00\xb2\xbf\xe5\xb4\x03\xca\x33\x61\xbd\xce\xc9\x95\x62\x7c\x8c\x9d\xc2\x58\xcd\x9c\x89\x46\x97\x98\x8c\x06\xd0\xb9\x67\x62\xb0\xab\xc9\x25\x15\x52\x59\xc5\x14\x2e\x57\xab\x5d\xb5\x9e\x5e\x73\xde\x36\xf9\x72\xb5\xfa\xff\xfa\x1c\x4f\x61\xf1\x71\x14\x6a\x4b\xa5\x4b\x28\x62\xcd\x29\x18\x74\x11\xc3\xa8\x2a\xbc\x8b\x49\xa1\x6b\xb2\xfb\x14\x58\x3b\x4e\x18\x03\x15\xa3\xfa\x7e\xcb\x91\x8a\x7d\x62\x7a\xee\xce\xbd\x27\x28\x6d\x5f\x1b\xed\x46\x34\xe7\x08\x86\x3c\x4c\x9f\x31\x85\xd7\x58\xaf\x27\x79\xad\x43\x49\x2e\x89\xbe\x49\x21\xf9\x71\xa9\x31\xde\xfa\x90\xc2\xff\xde\xbe\x69\x7f\xb3\x7c\x91\xf3\x8f\x9e\x2f\x29\xe5\xc8\xa8\x6a\xab\x98\xf8\x55\x39\xed\x86\xa9\x5b\x1c\xc7\x76\x0c\x98\xc4\x58\xf4\x62\x46\xc4\xd5\xd2\x61\xde\xe1\x1d\x2a\xae\x10\xe3\xf9\xe2\x36\xb9\xbb\x67\x69\xac\xdf\xe6\x85\xd5\x01\xa5\xf1\xb5\xd2\xf7\xfa\x51\x59\xba\x63\xd5\xc1\xd7\x0f\xc8\xbe\x46\xf5\x46\xfe\x24\x57\xca\xf0\xa9\x58\xd6\xe4\xa4\x61\x16\x6a\x98\x9b\xc3\xa1\x5b\x6d\xc6\xd2\x87\xa8\x23\x99\xf7\x14\xda\x15\xf5\x72\x4d\x8a\x3b\x7b\xd5\x02\xea\x22\x82\xa9\x74\x60\x8c\x99\xb8\xf9\xf8\x4b\xf2\x56\x9c\x7e\x1b\x80\x83\x99\x9d\x76\xe8\x72\x1f\xe4\xfd\x53\xaf\xab\xe5\xdb\xfe\x17\xef\x2e\xe5\x97\x7d\x47\x6c\xe3\xca\xfd\x7a\x8e\xff\xcb\xc7\xb1\xdd\xd9\xdd\x69\xda\x54\x13\x1d\xb2\xfc\xfc\x55\x8c\x7c\xa7\xb4\x13\xa1\xcf\xe5\xfd\x12\xa7\xdf\x13\xf6\x8b\xd9\x2f\xe6\xaf\x59\xdf\x93\x8d\xea\x77\xf6\x46\xb5\xff\x71\xae\x2e\xfe\x09\x00\x00\xff\xff\xdd\xc2\x97\xba\xeb\x08\x00\x00")
|
||||||
|
|
||||||
|
func assetsLatestConsoleHtmlBytes() ([]byte, error) {
|
||||||
|
return bindataRead(
|
||||||
|
_assetsLatestConsoleHtml,
|
||||||
|
"assets/latest/console.html",
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
|
func assetsLatestConsoleHtml() (*asset, error) {
|
||||||
|
bytes, err := assetsLatestConsoleHtmlBytes()
|
||||||
|
if err != nil {
|
||||||
|
return nil, err
|
||||||
|
}
|
||||||
|
|
||||||
|
info := bindataFileInfo{name: "assets/latest/console.html", size: 2283, mode: os.FileMode(420), modTime: time.Unix(1579063085, 0)}
|
||||||
|
a := &asset{bytes: bytes, info: info}
|
||||||
|
return a, nil
|
||||||
|
}
|
||||||
|
|
||||||
var _assetsUnversionedConsoleHtml = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xac\x56\x4d\x8f\xdb\x36\x10\xbd\xef\xaf\x18\xb0\x28\x72\xa9\x48\x27\x0d\xd0\x40\xb6\x16\x08\x1a\x14\x2d\xda\x02\x01\x92\xed\x75\xc1\xa5\x46\xd2\x6c\x28\x52\xe5\xd0\xf6\x3a\x86\xff\x7b\xa1\x6f\xd9\xbb\xcd\xa6\x45\xe0\x0b\xf9\xe6\x8b\xef\x71\x38\xf2\xa6\x8a\xb5\x05\xab\x5d\x99\x09\x74\xc9\x96\xc5\xf5\x15\xc0\xa6\x42\x9d\xb7\x0b\x80\x8d\x25\xf7\x09\x02\xda\x4c\x90\xf1\x4e\x40\x3c\x34\x98\x09\xaa\x75\x89\xaa\x71\xa5\x80\x2a\x60\x91\x89\x2a\xc6\x86\x53\xa5\xca\xa0\x9b\xea\x6f\x9b\xa0\x2b\xc9\x61\x62\x72\x27\x2b\xcd\xdb\xa0\x25\x79\x65\xbc\x63\x6f\x51\x69\x66\x8c\xac\x8c\xaf\x6b\xef\x14\xd5\xa5\x2a\xf4\xae\x4d\x7f\x5b\x06\x44\x27\xbb\xbc\x6a\x38\x00\x9b\x40\x4d\xec\x37\x00\x7b\x72\xb9\xdf\xcb\xdb\x5b\x74\x3b\xc8\xe0\x38\xc0\x00\xba\xa1\x5f\x3d\xc7\x14\x8e\x47\x39\xac\x4f\xa7\x1f\x96\xe6\xf7\x3e\xc4\x14\x44\x6f\x6f\x37\xa7\x93\x98\x1d\x8c\xa5\xbf\x30\x30\x79\xd7\xa5\x98\xb7\xcb\x2c\xb9\x8e\xfa\x6d\x43\x37\xc1\x76\x4e\xf3\xf6\x09\xa7\x65\xb6\x73\x68\xe9\x7c\x3c\x26\x40\x05\xb4\x22\xbd\x35\x06\x99\x7f\xc7\x03\x9c\x4e\xf3\xb9\x47\xb0\x27\x96\xd7\xe4\x3e\xa0\x09\x18\xcf\x93\x00\x5a\xc6\xb3\xb8\xd9\xf3\xb9\x48\x97\x43\xb2\x88\xdc\x06\xfb\x3e\x60\x41\x0f\x29\x08\xb5\x14\xa8\xbf\xbc\x3f\x7d\x8e\x29\x08\x63\xe9\x5c\xbc\x9b\x9b\xdf\xde\x8d\xca\xb5\xeb\x65\x15\x74\xfa\xce\xe2\x47\xb4\x58\x63\x0c\x3d\x95\x0b\x6c\xe9\xce\x18\x76\x18\x26\xfd\xda\x1b\x3b\x83\x16\xf7\x76\x5a\xf7\x4d\xa2\xe6\x2e\xd9\xa8\xb1\x7b\x37\x77\x3e\x3f\x8c\x5d\x14\x0f\x16\xfb\xb5\xac\x35\xb9\x9f\xbd\x8b\xe8\xe2\xd4\x40\x39\x71\x63\xf5\x21\x85\x17\xce\x3b\x7c\xb1\x1e\x60\xdf\x68\x43\xf1\x90\xc2\x6a\x44\x62\xd0\x8e\x29\x76\x27\x1b\xac\x20\x5f\xad\x18\x2c\x39\xd4\xa1\x77\x3b\x3d\x2a\x24\xb9\xf2\xfb\x27\xaa\xdd\x59\x6f\x3e\x3d\x2e\xf7\xf2\x7f\x94\xdb\xa8\x81\x64\xbf\xcb\x69\x07\x94\x67\xc2\x7a\x9d\x93\x2b\xc5\xf8\x82\x3a\x83\xb1\x9a\x39\x13\x8d\x2e\x31\x19\x1d\xa0\x0b\xcf\xc4\xe0\x57\x93\x4b\x2a\xa4\xb2\x8a\x29\xbc\x5c\xad\x76\xd5\x7a\x7a\x82\x79\xac\x3a\xec\xfb\xf5\x25\x9f\xc2\xe2\xc3\x08\x6a\x4b\xa5\x4b\x28\x62\xcd\x29\x18\x74\x11\xc3\x68\x2a\xbc\x8b\x49\xa1\x6b\xb2\x87\x14\x58\x3b\x4e\x18\x03\x15\xa3\xf9\x7e\xcb\x91\x8a\x43\x62\x7a\xed\x2e\xa3\x27\x2a\xed\xbd\x36\xda\x8d\x6c\x2e\x19\x0c\x75\x98\x3e\x63\x0a\xaf\xb0\x5e\x4f\x78\xad\x43\x49\x2e\x89\xbe\x49\x21\xf9\x71\x69\x31\xde\xfa\x90\xc2\x77\x6f\x5e\xb7\xbf\x19\x5f\xd4\xfc\xa3\xd7\x4b\x4a\x39\x2a\xaa\xda\x53\x4c\xfa\xaa\x9c\x76\x43\xd7\x2d\x96\xe3\x75\x0c\x9c\xc4\x78\xe8\x45\x8f\x88\xeb\x65\xc0\x3c\x78\x3b\x56\x5c\x21\xc6\xcb\x69\x6b\x72\x77\xcf\xd2\x58\xbf\xcd\x0b\xab\x03\x4a\xe3\x6b\xa5\xef\xf5\x83\xb2\x74\xc7\xaa\xa3\xaf\xf7\xc8\xbe\x46\xf5\x5a\xfe\x24\x57\xca\xf0\x39\x2c\x6b\x72\xd2\x30\x0b\x35\xf4\xcd\xf1\xd8\xcd\x23\x63\xe9\x43\xd4\x91\xcc\x3b\x0a\xed\x5c\x79\xfe\x4c\x8a\x3b\x7f\xd5\x12\xea\x32\x82\xa9\x74\x60\x8c\x99\xb8\xf9\xf8\x4b\xf2\x46\x9c\x0f\x74\xe0\x60\xe6\xa0\x1d\xba\xdc\x07\x79\xff\x38\xea\x7a\xf9\xb6\xff\x25\xba\x2b\xf9\xe5\xd8\x91\xdb\x38\x27\xbf\x5e\xe3\xff\xf2\x45\x6b\x07\x6d\xb7\x9a\x26\xd5\x24\x87\x2c\x3f\x7f\x95\x22\xdf\xa8\xec\x24\xe8\x53\x75\xbf\xa4\xe9\xb7\xa4\xfd\x6c\xf5\xab\xf9\x13\xd4\xdf\xc9\x46\xf5\x33\x7b\xa3\xda\x3f\x26\xd7\x57\xff\x04\x00\x00\xff\xff\x7d\x6e\x65\x2c\xa0\x08\x00\x00")
|
var _assetsUnversionedConsoleHtml = []byte("\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xac\x56\x4d\x8f\xdb\x36\x10\xbd\xef\xaf\x18\xb0\x28\x72\xa9\x48\x27\x0d\xd0\x40\xb6\x16\x08\x1a\x14\x2d\xda\x02\x01\x92\xed\x75\xc1\xa5\x46\xd2\x6c\x28\x52\xe5\xd0\xf6\x3a\x86\xff\x7b\xa1\x6f\xd9\xbb\xcd\xa6\x45\xe0\x0b\xf9\xe6\x8b\xef\x71\x38\xf2\xa6\x8a\xb5\x05\xab\x5d\x99\x09\x74\xc9\x96\xc5\xf5\x15\xc0\xa6\x42\x9d\xb7\x0b\x80\x8d\x25\xf7\x09\x02\xda\x4c\x90\xf1\x4e\x40\x3c\x34\x98\x09\xaa\x75\x89\xaa\x71\xa5\x80\x2a\x60\x91\x89\x2a\xc6\x86\x53\xa5\xca\xa0\x9b\xea\x6f\x9b\xa0\x2b\xc9\x61\x62\x72\x27\x2b\xcd\xdb\xa0\x25\x79\x65\xbc\x63\x6f\x51\x69\x66\x8c\xac\x8c\xaf\x6b\xef\x14\xd5\xa5\x2a\xf4\xae\x4d\x7f\x5b\x06\x44\x27\xbb\xbc\x6a\x38\x00\x9b\x40\x4d\xec\x37\x00\x7b\x72\xb9\xdf\xcb\xdb\x5b\x74\x3b\xc8\xe0\x38\xc0\x00\xba\xa1\x5f\x3d\xc7\x14\x8e\x47\x39\xac\x4f\xa7\x1f\x96\xe6\xf7\x3e\xc4\x14\x44\x6f\x6f\x37\xa7\x93\x98\x1d\x8c\xa5\xbf\x30\x30\x79\xd7\xa5\x98\xb7\xcb\x2c\xb9\x8e\xfa\x6d\x43\x37\xc1\x76\x4e\xf3\xf6\x09\xa7\x65\xb6\x73\x68\xe9\x7c\x3c\x26\x40\x05\xb4\x22\xbd\x35\x06\x99\x7f\xc7\x03\x9c\x4e\xf3\xb9\x47\xb0\x27\x96\xd7\xe4\x3e\xa0\x09\x18\xcf\x93\x00\x5a\xc6\xb3\xb8\xd9\xf3\xb9\x48\x97\x43\xb2\x88\xdc\x06\xfb\x3e\x60\x41\x0f\x29\x08\xb5\x14\xa8\xbf\xbc\x3f\x7d\x8e\x29\x08\x63\xe9\x5c\xbc\x9b\x9b\xdf\xde\x8d\xca\xb5\xeb\x65\x15\x74\xfa\xce\xe2\x47\xb4\x58\x63\x0c\x3d\x95\x0b\x6c\xe9\xce\x18\x76\x18\x26\xfd\xda\x1b\x3b\x83\x16\xf7\x76\x5a\xf7\x4d\xa2\xe6\x2e\xd9\xa8\xb1\x7b\x37\x77\x3e\x3f\x8c\x5d\x14\x0f\x16\xfb\xb5\xac\x35\xb9\x9f\xbd\x8b\xe8\xe2\xd4\x40\x39\x71\x63\xf5\x21\x85\x17\xce\x3b\x7c\xb1\x1e\x60\xdf\x68\x43\xf1\x90\xc2\x6a\x44\x62\xd0\x8e\x29\x76\x27\x1b\xac\x20\x5f\xad\x18\x2c\x39\xd4\xa1\x77\x3b\x3d\x2a\x24\xb9\xf2\xfb\x27\xaa\xdd\x59\x6f\x3e\x3d\x2e\xf7\xf2\x7f\x94\xdb\xa8\x81\x64\xbf\xcb\x69\x07\x94\x67\xc2\x7a\x9d\x93\x2b\xc5\xf8\x82\x3a\x83\xb1\x9a\x39\x13\x8d\x2e\x31\x19\x1d\xa0\x0b\xcf\xc4\xe0\x57\x93\x4b\x2a\xa4\xb2\x8a\x29\xbc\x5c\xad\x76\xd5\x7a\x7a\x82\x79\xac\x3a\xec\xfb\xf5\x25\x9f\xc2\xe2\xc3\x08\x6a\x4b\xa5\x4b\x28\x62\xcd\x29\x18\x74\x11\xc3\x68\x2a\xbc\x8b\x49\xa1\x6b\xb2\x87\x14\x58\x3b\x4e\x18\x03\x15\xa3\xf9\x7e\xcb\x91\x8a\x43\x62\x7a\xed\x2e\xa3\x27\x2a\xed\xbd\x36\xda\x8d\x6c\x2e\x19\x0c\x75\x98\x3e\x63\x0a\xaf\xb0\x5e\x4f\x78\xad\x43\x49\x2e\x89\xbe\x49\x21\xf9\x71\x69\x31\xde\xfa\x90\xc2\x77\x6f\x5e\xb7\xbf\x19\x5f\xd4\xfc\xa3\xd7\x4b\x4a\x39\x2a\xaa\xda\x53\x4c\xfa\xaa\x9c\x76\x43\xd7\x2d\x96\xe3\x75\x0c\x9c\xc4\x78\xe8\x45\x8f\x88\xeb\x65\xc0\x3c\x78\x3b\x56\x5c\x21\xc6\xcb\x69\x6b\x72\x77\xcf\xd2\x58\xbf\xcd\x0b\xab\x03\x4a\xe3\x6b\xa5\xef\xf5\x83\xb2\x74\xc7\xaa\xa3\xaf\xf7\xc8\xbe\x46\xf5\x5a\xfe\x24\x57\xca\xf0\x39\x2c\x6b\x72\xd2\x30\x0b\x35\xf4\xcd\xf1\xd8\xcd\x23\x63\xe9\x43\xd4\x91\xcc\x3b\x0a\xed\x5c\x79\xfe\x4c\x8a\x3b\x7f\xd5\x12\xea\x32\x82\xa9\x74\x60\x8c\x99\xb8\xf9\xf8\x4b\xf2\x46\x9c\x0f\x74\xe0\x60\xe6\xa0\x1d\xba\xdc\x07\x79\xff\x38\xea\x7a\xf9\xb6\xff\x25\xba\x2b\xf9\xe5\xd8\x91\xdb\x38\x27\xbf\x5e\xe3\xff\xf2\x45\x6b\x07\x6d\xb7\x9a\x26\xd5\x24\x87\x2c\x3f\x7f\x95\x22\xdf\xa8\xec\x24\xe8\x53\x75\xbf\xa4\xe9\xb7\xa4\xfd\x6c\xf5\xab\xf9\x13\xd4\xdf\xc9\x46\xf5\x33\x7b\xa3\xda\x3f\x26\xd7\x57\xff\x04\x00\x00\xff\xff\x7d\x6e\x65\x2c\xa0\x08\x00\x00")
|
||||||
|
|
||||||
func assetsUnversionedConsoleHtmlBytes() ([]byte, error) {
|
func assetsUnversionedConsoleHtmlBytes() ([]byte, error) {
|
||||||
@ -85,7 +106,7 @@ func assetsUnversionedConsoleHtml() (*asset, error) {
|
|||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
|
||||||
info := bindataFileInfo{name: "assets/unversioned/console.html", size: 2208, mode: os.FileMode(420), modTime: time.Unix(1576470932, 0)}
|
info := bindataFileInfo{name: "assets/unversioned/console.html", size: 2208, mode: os.FileMode(420), modTime: time.Unix(1576481548, 0)}
|
||||||
a := &asset{bytes: bytes, info: info}
|
a := &asset{bytes: bytes, info: info}
|
||||||
return a, nil
|
return a, nil
|
||||||
}
|
}
|
||||||
@ -105,7 +126,7 @@ func assetsV10AlphaConsoleHtml() (*asset, error) {
|
|||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
|
||||||
info := bindataFileInfo{name: "assets/v1.0-alpha/console.html", size: 1928, mode: os.FileMode(420), modTime: time.Unix(1576470932, 0)}
|
info := bindataFileInfo{name: "assets/v1.0-alpha/console.html", size: 1928, mode: os.FileMode(420), modTime: time.Unix(1576481548, 0)}
|
||||||
a := &asset{bytes: bytes, info: info}
|
a := &asset{bytes: bytes, info: info}
|
||||||
return a, nil
|
return a, nil
|
||||||
}
|
}
|
||||||
@ -125,7 +146,7 @@ func assetsV10ConsoleHtml() (*asset, error) {
|
|||||||
return nil, err
|
return nil, err
|
||||||
}
|
}
|
||||||
|
|
||||||
info := bindataFileInfo{name: "assets/v1.0/console.html", size: 2283, mode: os.FileMode(420), modTime: time.Unix(1576812491, 0)}
|
info := bindataFileInfo{name: "assets/v1.0/console.html", size: 2283, mode: os.FileMode(420), modTime: time.Unix(1577362631, 0)}
|
||||||
a := &asset{bytes: bytes, info: info}
|
a := &asset{bytes: bytes, info: info}
|
||||||
return a, nil
|
return a, nil
|
||||||
}
|
}
|
||||||
@ -182,6 +203,7 @@ func AssetNames() []string {
|
|||||||
|
|
||||||
// _bindata is a table, holding each asset generator, mapped to its name.
|
// _bindata is a table, holding each asset generator, mapped to its name.
|
||||||
var _bindata = map[string]func() (*asset, error){
|
var _bindata = map[string]func() (*asset, error){
|
||||||
|
"assets/latest/console.html": assetsLatestConsoleHtml,
|
||||||
"assets/unversioned/console.html": assetsUnversionedConsoleHtml,
|
"assets/unversioned/console.html": assetsUnversionedConsoleHtml,
|
||||||
"assets/v1.0-alpha/console.html": assetsV10AlphaConsoleHtml,
|
"assets/v1.0-alpha/console.html": assetsV10AlphaConsoleHtml,
|
||||||
"assets/v1.0/console.html": assetsV10ConsoleHtml,
|
"assets/v1.0/console.html": assetsV10ConsoleHtml,
|
||||||
@ -228,6 +250,9 @@ type bintree struct {
|
|||||||
}
|
}
|
||||||
var _bintree = &bintree{nil, map[string]*bintree{
|
var _bintree = &bintree{nil, map[string]*bintree{
|
||||||
"assets": &bintree{nil, map[string]*bintree{
|
"assets": &bintree{nil, map[string]*bintree{
|
||||||
|
"latest": &bintree{nil, map[string]*bintree{
|
||||||
|
"console.html": &bintree{assetsLatestConsoleHtml, map[string]*bintree{}},
|
||||||
|
}},
|
||||||
"unversioned": &bintree{nil, map[string]*bintree{
|
"unversioned": &bintree{nil, map[string]*bintree{
|
||||||
"console.html": &bintree{assetsUnversionedConsoleHtml, map[string]*bintree{}},
|
"console.html": &bintree{assetsUnversionedConsoleHtml, map[string]*bintree{}},
|
||||||
}},
|
}},
|
||||||
|
75
cli/assets/latest/console.html
Normal file
75
cli/assets/latest/console.html
Normal file
@ -0,0 +1,75 @@
|
|||||||
|
<html lang="en-us">
|
||||||
|
<head>
|
||||||
|
<link rel="icon" type="image/png" href="https://graphql-engine-cdn.hasura.io/console/assets/common/img/favicon_green.png" />
|
||||||
|
<script>
|
||||||
|
window.__env = {
|
||||||
|
apiHost: {{.apiHost}},
|
||||||
|
apiPort: "{{.apiPort}}",
|
||||||
|
cliVersion: {{.cliVersion}},
|
||||||
|
dataApiUrl: {{.dataApiUrl}},
|
||||||
|
dataApiVersion: {{.dataApiVersion}},
|
||||||
|
{{- if .hasAccessKey }}
|
||||||
|
accessKey: {{.adminSecret}},
|
||||||
|
{{ else }}
|
||||||
|
adminSecret: {{.adminSecret}},
|
||||||
|
{{ end -}}
|
||||||
|
urlPrefix: "/",
|
||||||
|
consoleMode: "cli",
|
||||||
|
cliUUID: {{.cliUUID}},
|
||||||
|
enableTelemetry: {{.enableTelemetry}},
|
||||||
|
assetsPath: "https://graphql-engine-cdn.hasura.io/console/assets",
|
||||||
|
serverVersion: "{{.serverVersion}}",
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<style>
|
||||||
|
.mainContent {
|
||||||
|
display: 'none';
|
||||||
|
opacity: 0;
|
||||||
|
transition: opacity .20s linear;
|
||||||
|
}
|
||||||
|
.mainContent.show {
|
||||||
|
display: 'block';
|
||||||
|
opacity: 1;
|
||||||
|
transition: opacity .20s linear;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
||||||
|
<div id="loading">
|
||||||
|
<div class="page-loading" style="
|
||||||
|
min-height: 100vh;
|
||||||
|
width: 100%;
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
font-family: sans-serif;
|
||||||
|
justify-content: center;
|
||||||
|
">
|
||||||
|
<span class="" style="
|
||||||
|
font-size: 2em;
|
||||||
|
margin-top: -3em;
|
||||||
|
color: #848484;
|
||||||
|
">
|
||||||
|
Loading...
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div id="content" class="mainContent"></div>
|
||||||
|
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css"/>
|
||||||
|
|
||||||
|
{{ if .cliStaticDir }}
|
||||||
|
|
||||||
|
<link rel="stylesheet" href="/static/main.css" charset="UTF-8"/>
|
||||||
|
<script src="/static/vendor.js" charset="UTF-8"></script>
|
||||||
|
<script src="/static/main.js" charset="UTF-8"></script>
|
||||||
|
|
||||||
|
{{ else }}
|
||||||
|
|
||||||
|
<link rel="stylesheet" href="https://graphql-engine-cdn.hasura.io/console/assets/{{.assetsVersion}}/main.css.gz" charset="UTF-8"/>
|
||||||
|
<script src="https://graphql-engine-cdn.hasura.io/console/assets/{{.assetsVersion}}/vendor.js.gz" charset="UTF-8"></script>
|
||||||
|
<script src="https://graphql-engine-cdn.hasura.io/console/assets/{{.assetsVersion}}/main.js.gz" charset="UTF-8"></script>
|
||||||
|
|
||||||
|
{{ end }}
|
||||||
|
|
||||||
|
</body>
|
||||||
|
</html>
|
@ -298,7 +298,7 @@ func (ec *ExecutionContext) checkServerVersion() error {
|
|||||||
ec.Logger.Debugf("versions: cli: [%s] server: [%s]", ec.Version.GetCLIVersion(), ec.Version.GetServerVersion())
|
ec.Logger.Debugf("versions: cli: [%s] server: [%s]", ec.Version.GetCLIVersion(), ec.Version.GetServerVersion())
|
||||||
ec.Logger.Debugf("compatibility check: [%v] %v", isCompatible, reason)
|
ec.Logger.Debugf("compatibility check: [%v] %v", isCompatible, reason)
|
||||||
if !isCompatible {
|
if !isCompatible {
|
||||||
return errors.Errorf("[cli: %s] [server: %s] versions incompatible: %s", ec.Version.GetCLIVersion(), ec.Version.GetServerVersion(), reason)
|
ec.Logger.Warnf("[cli: %s] [server: %s] version mismatch: %s", ec.Version.GetCLIVersion(), ec.Version.GetServerVersion(), reason)
|
||||||
}
|
}
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
@ -275,6 +275,10 @@ func serveConsole(assetsVersion, staticDir string, opts gin.H) (*gin.Engine, err
|
|||||||
// An Engine instance with the Logger and Recovery middleware already attached.
|
// An Engine instance with the Logger and Recovery middleware already attached.
|
||||||
r := gin.New()
|
r := gin.New()
|
||||||
|
|
||||||
|
if !util.DoAssetExist("assets/" + assetsVersion + "/console.html") {
|
||||||
|
assetsVersion = "latest"
|
||||||
|
}
|
||||||
|
|
||||||
// Template console.html
|
// Template console.html
|
||||||
templateRender, err := util.LoadTemplates("assets/"+assetsVersion+"/", "console.html")
|
templateRender, err := util.LoadTemplates("assets/"+assetsVersion+"/", "console.html")
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
@ -59,6 +59,8 @@ func (o *updateOptions) run(showPrompt bool) error {
|
|||||||
return errors.Wrap(err, "command: check update")
|
return errors.Wrap(err, "command: check update")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ec.Logger.Debugln("hasUpdate: ", hasUpdate, "latestVersion: ", latestVersion, "currentVersion:", currentVersion)
|
||||||
|
|
||||||
if !hasUpdate {
|
if !hasUpdate {
|
||||||
o.EC.Logger.WithField("version", currentVersion).Info("hasura cli is up to date")
|
o.EC.Logger.WithField("version", currentVersion).Info("hasura cli is up to date")
|
||||||
return nil
|
return nil
|
||||||
|
@ -99,7 +99,7 @@ func HasUpdate(currentVersion *semver.Version, timeFile string) (bool, *semver.V
|
|||||||
return false, nil, errors.Wrap(err, "get latest version")
|
return false, nil, errors.Wrap(err, "get latest version")
|
||||||
}
|
}
|
||||||
|
|
||||||
c, err := semver.NewConstraint(fmt.Sprintf("> %s", currentVersion.String()))
|
c, err := semver.NewConstraint(fmt.Sprintf("> %s-0", currentVersion.String()))
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return false, nil, errors.Wrap(err, "semver constraint build")
|
return false, nil, errors.Wrap(err, "semver constraint build")
|
||||||
}
|
}
|
||||||
|
@ -29,6 +29,7 @@ func (b *binaryFileSystem) Exists(prefix string, filepath string) bool {
|
|||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// BinaryFileSystem creates a binary file system at root from the assets
|
||||||
func BinaryFileSystem(root string) *binaryFileSystem {
|
func BinaryFileSystem(root string) *binaryFileSystem {
|
||||||
fs := &assetfs.AssetFS{assets.Asset, assets.AssetDir, assets.AssetInfo, root}
|
fs := &assetfs.AssetFS{assets.Asset, assets.AssetDir, assets.AssetInfo, root}
|
||||||
return &binaryFileSystem{
|
return &binaryFileSystem{
|
||||||
@ -36,6 +37,7 @@ func BinaryFileSystem(root string) *binaryFileSystem {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// LoadTemplates loads templates from path for the given list
|
||||||
func LoadTemplates(path string, list ...string) (multitemplate.Render, error) {
|
func LoadTemplates(path string, list ...string) (multitemplate.Render, error) {
|
||||||
r := multitemplate.New()
|
r := multitemplate.New()
|
||||||
|
|
||||||
@ -55,3 +57,12 @@ func LoadTemplates(path string, list ...string) (multitemplate.Render, error) {
|
|||||||
|
|
||||||
return r, nil
|
return r, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// DoAssetExist returns true if an asset exists at pathk
|
||||||
|
func DoAssetExist(path string) bool {
|
||||||
|
_, err := assets.AssetInfo(path)
|
||||||
|
if err != nil {
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
return true
|
||||||
|
}
|
||||||
|
@ -1,12 +1,12 @@
|
|||||||
package version
|
package version
|
||||||
|
|
||||||
const (
|
const (
|
||||||
untaggedBuild = "for untagged builds, server and cli versions should match"
|
untaggedBuild = "untagged build, there could be inconsistencies"
|
||||||
taggedBuild = "cli version (major.minor) should be equal or ahead of server version, please update cli"
|
taggedBuild = "older cli version might not be compatible with latest server apis, please update cli"
|
||||||
noServerVersion = "server with no version treated as pre-release build"
|
noServerVersion = "server with no version treated as pre-release build"
|
||||||
noCLIVersion = "cli version is empty, indicates a broken build"
|
noCLIVersion = "cli version is empty, indicates a broken build"
|
||||||
untaggedCLI = "untagged cli build can work with tagged server build"
|
untaggedCLI = "untagged cli build can work with tagged server build"
|
||||||
devCLI = "dev version of cli, compatible with all servers"
|
devCLI = "dev version of cli, there could be inconsistencies"
|
||||||
)
|
)
|
||||||
|
|
||||||
// CheckCLIServerCompatibility compares server and cli for compatibility,
|
// CheckCLIServerCompatibility compares server and cli for compatibility,
|
||||||
|
Loading…
Reference in New Issue
Block a user