chore: rename .faas.yaml to faas.yaml (#143)

Fixes: https://github.com/boson-project/faas/issues/142

Signed-off-by: Lance Ball <lball@redhat.com>
This commit is contained in:
Lance Ball 2020-09-29 10:27:04 -04:00 committed by GitHub
parent 05196a66b7
commit a698f39d1d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
9 changed files with 26 additions and 26 deletions

View File

@ -25,13 +25,13 @@ var buildCmd = &cobra.Command{
Long: `Build an existing Function project as an OCI image
Builds the Function project in the current directory or in the directory
specified by the --path flag. The .faas.yaml file is read to determine the
specified by the --path flag. The faas.yaml file is read to determine the
image name and repository. If both of these values are unset in the
configuration file the --repository or -r flag should be provided and an image
name will be derived from the project name.
Any value provided for --image or --repository will be persisted in the
.faas.yaml configuration file. On subsequent invocations of the "build" command
faas.yaml configuration file. On subsequent invocations of the "build" command
these values will be read from the configuration file.
`,
SuggestFor: []string{"biuld", "buidl", "built"},

View File

@ -52,7 +52,7 @@ values when an image is built or a Function is deployed. If the image name and
image repository are both unspecified, the user will be prompted for a
repository name, and the image name can be inferred from that plus the function
name. The function name, namespace, image name and repository name are all
persisted in the project configuration file .faas.yaml.
persisted in the project configuration file faas.yaml.
`,
SuggestFor: []string{"cerate", "new"},
PreRunE: bindEnv("image", "namespace", "repository", "runtime", "templates", "trigger", "confirm"),

View File

@ -23,13 +23,13 @@ var deleteCmd = &cobra.Command{
Removes a deployed function from the cluster. The user may specify a function
by name, path using the --path or -p flag, or if neither of those are provided,
the current directory will be searched for a .faas.yaml configuration file to
the current directory will be searched for a faas.yaml configuration file to
determine the function to be removed.
The namespace defaults to the value in .faas.yaml or the namespace currently
The namespace defaults to the value in faas.yaml or the namespace currently
active in the user's Kubernetes configuration. The namespace may be specified
on the command line using the --namespace or -n flag, and if so this will
overwrite the value in .faas.yaml.
overwrite the value in faas.yaml.
`,
SuggestFor: []string{"remove", "rm", "del"},
ValidArgsFunction: CompleteFunctionList,

View File

@ -29,10 +29,10 @@ directory may be provided using the --path or -p flag. The image to be deployed
must have already been created using the "build" command.
The namespace into which the project is deployed defaults to the value in the
.faas.yaml configuration file. If NAMESPACE is not set in the configuration,
faas.yaml configuration file. If NAMESPACE is not set in the configuration,
the namespace currently active in the Kubernetes configuration file will be
used. The namespace may be specified on the command line using the --namespace
or -n flag, and if so this will overwrite the value in the .faas.yaml file.
or -n flag, and if so this will overwrite the value in the faas.yaml file.
`,
SuggestFor: []string{"delpoy", "deplyo"},
PreRunE: bindEnv("namespace", "path", "confirm"),

View File

@ -36,9 +36,9 @@ Prints the name, route and any event subscriptions for a deployed Function in
the current directory. A path to a Function project directory may be supplied
using the --path or -p flag.
The namespace defaults to the value in .faas.yaml or the namespace currently
The namespace defaults to the value in faas.yaml or the namespace currently
active in the user's Kubernetes configuration. The namespace may be specified
using the --namespace or -n flag, and if so this will overwrite the value in .faas.yaml.
using the --namespace or -n flag, and if so this will overwrite the value in faas.yaml.
`,
SuggestFor: []string{"desc", "get"},
ValidArgsFunction: CompleteFunctionList,

View File

@ -31,10 +31,10 @@ var listCmd = &cobra.Command{
Short: "Lists deployed Functions",
Long: `Lists deployed Functions
Lists all deployed functions. The namespace defaults to the value in .faas.yaml
Lists all deployed functions. The namespace defaults to the value in faas.yaml
or the namespace currently active in the user's Kubernetes configuration. The
namespace may be specified on the command line using the --namespace or -n flag.
If specified this will overwrite the value in .faas.yaml.
If specified this will overwrite the value in faas.yaml.
`,
SuggestFor: []string{"ls", "lsit"},
PreRunE: bindEnv("namespace", "format"),

View File

@ -27,15 +27,15 @@ var updateCmd = &cobra.Command{
Long: `Update a deployed Function
Updates the deployed Function project in the current directory or in the
directory specified by the --path flag. Reads the .faas.yaml configuration file
directory specified by the --path flag. Reads the faas.yaml configuration file
to determine the image name.
The deployed Function is updated with a new container image that is pushed to a
container image repository, and the Knative Service is updated.
The namespace defaults to the value in .faas.yaml or the namespace currently
The namespace defaults to the value in faas.yaml or the namespace currently
active in the user Kubernetes configuration. The namespace may be specified on
the command line, and if so this will overwrite the value in .faas.yaml.
the command line, and if so this will overwrite the value in faas.yaml.
An image repository may be specified on the command line using the --repository
or -r flag.

View File

@ -9,7 +9,7 @@ import (
)
// ConfigFile is the name of the config's serialized form.
const ConfigFile = ".faas.yaml"
const ConfigFile = "faas.yaml"
// Config represents the serialized state of a Function's metadata.
// See the Function struct for attribute documentation.

View File

@ -18,9 +18,9 @@ kn faas init <path> [-l <runtime> -t <trigger>]
## `build`
Builds the Function project in the current directory. Reads the `.faas.yaml` file to determine image name and repository. If both of these values are unset in the configuration file, the user is prompted to provide a repository, from there an image name can be derived. The image name and repository may also be specified as flags, as can the path to the project.
Builds the Function project in the current directory. Reads the `faas.yaml` file to determine image name and repository. If both of these values are unset in the configuration file, the user is prompted to provide a repository, from there an image name can be derived. The image name and repository may also be specified as flags, as can the path to the project.
The value(s) provided for image and repository are persisted to the `.faas.yaml` file so that subsequent invocations do not require the user to specify these again.
The value(s) provided for image and repository are persisted to the `faas.yaml` file so that subsequent invocations do not require the user to specify these again.
Similar `kn` command: none.
@ -52,9 +52,9 @@ kn faas run
## `deploy`
Deploys the Function project in the current directory. The user may specify a path to the project directory as a flag. Reads the `.faas.yaml` configuration file to determine the image name. Derives the service name from the project name. There is no command line option to specify the image name, although this can be changed in `.faas.yaml`. There is no mechanism by which the user can specify the service name. The user must have already built an image for this function using `faas deploy` or they will encounter an error.
Deploys the Function project in the current directory. The user may specify a path to the project directory as a flag. Reads the `faas.yaml` configuration file to determine the image name. Derives the service name from the project name. There is no command line option to specify the image name, although this can be changed in `faas.yaml`. There is no mechanism by which the user can specify the service name. The user must have already built an image for this function using `faas deploy` or they will encounter an error.
The namespace defaults to the value in `.faas.yaml` or the namespace currently active in the user's Kubernetes configuration. The namespace may be specified on the command line, and if so this will overwrite the value in `.faas.yaml`.
The namespace defaults to the value in `faas.yaml` or the namespace currently active in the user's Kubernetes configuration. The namespace may be specified on the command line, and if so this will overwrite the value in `faas.yaml`.
Similar `kn` command: `kn service create NAME --image IMAGE [flags]`. This command allows a user to deploy a Knative Service by specifying an image, typically one hosted on a public container registry such as docker.io. The deployment options which the `kn` command affords the user are quite broad. The `kn` command in this case is quite effective for a power user. The `faas deploy` command has a similar end result, but is definitely easier for a user just getting started to be successful with.
@ -70,9 +70,9 @@ kn faas deploy [-n <namespace> -p <path>]
## `update`
Updates the deployed Function project in the current directory. The user may specify the path on the command line with a flag. Reads the `.faas.yaml` configuration file to determine the image name. Derives the service name from the project name. The deployed Function is updated with a new container image that is pushed to a user repository, and the Knative `Service` is then updated.
Updates the deployed Function project in the current directory. The user may specify the path on the command line with a flag. Reads the `faas.yaml` configuration file to determine the image name. Derives the service name from the project name. The deployed Function is updated with a new container image that is pushed to a user repository, and the Knative `Service` is then updated.
The namespace defaults to the value in `.faas.yaml` or the namespace currently active in the user's Kubernetes configuration. The namespace may be specified on the command line, and if so this will overwrite the value in `.faas.yaml`. The user may specify a repository on the command line.
The namespace defaults to the value in `faas.yaml` or the namespace currently active in the user's Kubernetes configuration. The namespace may be specified on the command line, and if so this will overwrite the value in `faas.yaml`. The user may specify a repository on the command line.
Note that the behavior of `update` is different than that of `deploy` and `run`. When `update` is run, a new container image is always built. However, for `deploy` and `run`, the user is required to run `faas build` first. The `update` command also differs from `deploy` in that it allows the user to specify a repository on the command line (but still not an image name). Consider normalizing all of this so that all of these commands behave similarly.
@ -90,7 +90,7 @@ kn faas update [-r <repository> -p <path>]
## `describe`
Prints the name, route and any event subscriptions for a deployed Function. The user may also specify the name of the function to describe. The namespace defaults to the value in `.faas.yaml` or the namespace currently active in the user's Kubernetes configuration. The namespace may be specified on the command line, and if so this will overwrite the value in `.faas.yaml`.
Prints the name, route and any event subscriptions for a deployed Function. The user may also specify the name of the function to describe. The namespace defaults to the value in `faas.yaml` or the namespace currently active in the user's Kubernetes configuration. The namespace may be specified on the command line, and if so this will overwrite the value in `faas.yaml`.
Similar `kn` command: `kn service describe NAME [flags]`. This flag provides a lot of nice information not available in `faas describe`, such as revisions, age, annotations and labels. This command should be renamed to make it distinct from `kn` - e.g. `faas status`.
@ -106,7 +106,7 @@ kn faas describe [-f <format> -n <namespace> -p <path>]
## `list`
Lists all deployed functions. The namespace defaults to the value in `.faas.yaml` or the namespace currently active in the user's Kubernetes configuration. The namespace defaults to the value in `.faas.yaml` or the namespace currently active in the user's Kubernetes configuration. The namespace may be specified on the command line, and if so this will overwrite the value in `.faas.yaml`.
Lists all deployed functions. The namespace defaults to the value in `faas.yaml` or the namespace currently active in the user's Kubernetes configuration. The namespace defaults to the value in `faas.yaml` or the namespace currently active in the user's Kubernetes configuration. The namespace may be specified on the command line, and if so this will overwrite the value in `faas.yaml`.
Similar `kn` command: `kn service list [name] [flags]`. This command lists all deployed Knative `Services`. As with other `kn` commands that have similar functionality, there is more information and flexibilty in the `kn` command. However, `kn` will return _all_ `Services`, while `faas list` will only display the boson Functions that have been deployed. Consider improving the output of the `faas list` command so that it is at least as informative as `kn service list`.
@ -124,7 +124,7 @@ kn faas list [-n <namespace> -p <path>]
Creates a new Function project at _`path`_. If _`path`_ does not exist, it is created. The function name is the name of the leaf directory at _`path`_. After creating the project, it builds a container image and deploys it. This command wraps `init`, `build` and `deploy` all up into one command.
The user may specify the runtime, trigger, image name, image repository, and namespace as flags on the command line. If the image name and image repository are both unspecified, the user will be prompted for a repository name, and the image name can be inferred from that plus the function name. The function name, namespace, image name and repository name are all persisted in the project configuration file `.faas.yaml`.
The user may specify the runtime, trigger, image name, image repository, and namespace as flags on the command line. If the image name and image repository are both unspecified, the user will be prompted for a repository name, and the image name can be inferred from that plus the function name. The function name, namespace, image name and repository name are all persisted in the project configuration file `faas.yaml`.
Similar `kn` command: none.
@ -140,7 +140,7 @@ kn faas create <path> -r <repository> -l <runtime> -t <trigger> -i <image> -n <n
## `delete`
Removes a deployed function from the cluster. The user may specify a function by name, path or if neither of those are provided, the current directory will be searched for a `.faas.yaml` configuration file to determine the function to be removed. The namespace defaults to the value in `.faas.yaml` or the namespace currently active in the user's Kubernetes configuration. The namespace may be specified on the command line, and if so this will overwrite the value in `.faas.yaml`.
Removes a deployed function from the cluster. The user may specify a function by name, path or if neither of those are provided, the current directory will be searched for a `faas.yaml` configuration file to determine the function to be removed. The namespace defaults to the value in `faas.yaml` or the namespace currently active in the user's Kubernetes configuration. The namespace may be specified on the command line, and if so this will overwrite the value in `faas.yaml`.
Similar `kn` command: `kn service delete NAME [flags]`.