mirror of
https://github.com/openfaas/faasd.git
synced 2025-06-23 15:23:28 +00:00
Print version and reduce verbosity
* revendor k3sup to prevent arch / OS from being printed in the logs * print version on startup * bump minor CNI and containerd version for e2e tests * revendor faas-provider for latest log printing update Signed-off-by: Alex Ellis (OpenFaaS Ltd) <alexellis2@gmail.com>
This commit is contained in:
committed by
Alex Ellis
parent
50de0f34bb
commit
26debca616
@ -294,6 +294,7 @@ func LoadComposeFile(wd string, file string) (*compose.Config, error) {
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
config, err := loader.ParseYAML(b)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
@ -306,6 +307,7 @@ func LoadComposeFile(wd string, file string) (*compose.Config, error) {
|
||||
|
||||
var files []compose.ConfigFile
|
||||
files = append(files, compose.ConfigFile{Filename: file, Config: config})
|
||||
|
||||
return loader.Load(compose.ConfigDetails{
|
||||
WorkingDir: wd,
|
||||
ConfigFiles: files,
|
||||
@ -323,14 +325,19 @@ func sortedEnvKeys(env map[string]*string) (keys []string) {
|
||||
return keys
|
||||
}
|
||||
|
||||
// ArchGetter provides client CPU architecture and
|
||||
// client OS
|
||||
type ArchGetter func() (string, string)
|
||||
|
||||
// GetArchSuffix provides client CPU architecture and
|
||||
// client OS from ArchGetter
|
||||
func GetArchSuffix(getClientArch ArchGetter) (suffix string, err error) {
|
||||
clientArch, clientOS := getClientArch()
|
||||
|
||||
if clientOS != "Linux" {
|
||||
return "", fmt.Errorf("You can only use faasd on Linux")
|
||||
return "", fmt.Errorf("you can only use faasd with Linux")
|
||||
}
|
||||
|
||||
switch clientArch {
|
||||
case "x86_64":
|
||||
// no suffix needed
|
||||
|
Reference in New Issue
Block a user