From 14c49290c641b02acbac68ba11b833e0a0415850 Mon Sep 17 00:00:00 2001 From: Ryan Nowak Date: Thu, 7 May 2020 12:50:03 -0700 Subject: [PATCH] Update command docs Fixes: #387 --- docs/reference/commandline/README.md | 3 ++ docs/reference/commandline/tye-build.md | 50 +++++++++++++++++ docs/reference/commandline/tye-deploy.md | 8 ++- docs/reference/commandline/tye-push.md | 63 ++++++++++++++++++++++ docs/reference/commandline/tye-undeploy.md | 4 +- 5 files changed, 126 insertions(+), 2 deletions(-) create mode 100644 docs/reference/commandline/tye-build.md create mode 100644 docs/reference/commandline/tye-push.md diff --git a/docs/reference/commandline/README.md b/docs/reference/commandline/README.md index 6a904971..4c1d5b6c 100644 --- a/docs/reference/commandline/README.md +++ b/docs/reference/commandline/README.md @@ -4,5 +4,8 @@ |-------|-------------| |**[tye init](tye-init.md)** | Create a `tye.yaml`. |**[tye run](tye-run.md)** | Run an application locally. +|**[tye build](tye-build.md)** | Build an application's containers. +|**[tye push](tye-push.md)** | Push an application's containers. |**[tye deploy](tye-deploy.md)** | Deploy an application. +|**[tye undeploy](tye-deploy.md)** | Remove a deployed application. |**[tye](tye.md)** | Base command. \ No newline at end of file diff --git a/docs/reference/commandline/tye-build.md b/docs/reference/commandline/tye-build.md new file mode 100644 index 00000000..bd2dfafb --- /dev/null +++ b/docs/reference/commandline/tye-build.md @@ -0,0 +1,50 @@ +# tye build + +## Name + +`tye build` - Builds the application's containers. + +## Synopsis + +```text +tye build [-?|-h|--help] [-v|--verbosity ] [] +``` + +## Description + +The `tye build` command will build all of an application's project services into containers without deploying or pushing the containers remotely. + +This command is useful for testing that all projects successfully build. + +## Arguments + +`PATH` + +The path to either a file or directory to execute `tye build` on. + +If a directory path is specified, `tye build` will default to using these files, in the following order: + +- `tye.yaml` +- `*.sln` +- `*.csproj/*.fsproj` + +## Options + +- `-v|--verbosity ` + + The verbosity of logs emitted by `tye build`. Defaults to Info. + + +## Examples + +- Build an application from the current directory: + + ```text + tye build + ``` + +- Build an application, increasing log verbosity to Debug. + + ```text + tye build --verbosity Debug + ``` diff --git a/docs/reference/commandline/tye-deploy.md b/docs/reference/commandline/tye-deploy.md index 90042681..75725055 100644 --- a/docs/reference/commandline/tye-deploy.md +++ b/docs/reference/commandline/tye-deploy.md @@ -27,6 +27,12 @@ The `tye deploy` command will deploy an application to Kubernetes. `tye deploy` > :bulb: Use `kubectl config view --minify --output 'jsonpath={..namespace}'` to view the current namespace. +> :warning: The `tye deploy` command requires access to a remote container registry. Images will be tagged using the registry configured in `tye.yaml` (if present), or using a registry supplied interactively at the command line. + +> :bulb: The `tye deploy` command uses Docker's credentials for pushing to the remote container registry. Make sure Docker is configured to push to your registry before running `tye deploy`. + +> :bulb: The `tye deploy` command uses your local Kubernetes context to access the Kubernetes cluster. Make sure `kubectl` is configured to manage your cluster before running `tye deploy`. + ## Arguments `PATH` @@ -68,7 +74,7 @@ If a directory path is specified, `tye deploy` will default to using these files - Deploy an application with interactive input: ```text - tye run --interactive + tye deploy --interactive ``` - Deploy an application, increasing log verbosity to Debug. diff --git a/docs/reference/commandline/tye-push.md b/docs/reference/commandline/tye-push.md new file mode 100644 index 00000000..73a5c1ee --- /dev/null +++ b/docs/reference/commandline/tye-push.md @@ -0,0 +1,63 @@ +# tye deploy + +## Name + +`tye push` - Builds the application's containers and pushes them to the container registry. + +## Synopsis + +```text +tye push [-?|-h|--help] [-i|--interactive] [-v|--verbosity ] [] +``` + +## Description + +The `tye push` command will build all of an application's project services into containers and push the containers to a remote registry without deploying to Kubernetes. + +This command is useful if you want to use Tye to containerize .NET projects and manage deployment separately. + +> :warning: The `tye push` command requires access to a remote container registry. Images will be tagged using the registry configured in `tye.yaml` (if present), or using a registry supplied interactively at the command line. + +> :bulb: The `tye push` command uses Docker's credentials for pushing to the remote container registry. Make sure Docker is configured to push to your registry before running `tye push`. + +## Arguments + +`PATH` + +The path to either a file or directory to execute `tye push` on. Can either be a yaml, sln, or project file, however it is recommend to have a tye.yaml file for `tye push`. + +If a directory path is specified, `tye push` will default to using these files, in the following order: + +- `tye.yaml` +- `*.sln` +- `*.csproj/*.fsproj` + +## Options + +- `-i|--interactive` + + Does an interactive deployment that will accept input for values that are required by default. + +- `-v|--verbosity ` + + The verbosity of logs emitted by `tye deploy`. Defaults to Info. + +## Examples + +- Push an application from the current directory: + + ```text + tye push + ``` + +- Push an application with interactive input: + + ```text + tye push --interactive + ``` + +- Push an application, increasing log verbosity to Debug. + + ```text + tye deploy --verbosity Debug + ``` diff --git a/docs/reference/commandline/tye-undeploy.md b/docs/reference/commandline/tye-undeploy.md index 097cc409..6281cccb 100644 --- a/docs/reference/commandline/tye-undeploy.md +++ b/docs/reference/commandline/tye-undeploy.md @@ -27,7 +27,9 @@ The `tye undeploy` command will delete a deployed application from Kubernetes. ` > :bulb: Use `kubectl config view --minify --output 'jsonpath={..namespace}'` to view the current namespace. -Undeploy decides which resources to delete based on the `app.kubernetes.io/part-of=...` label. This label will be set to the application name for all resources created by Tye. `tye undeploy` does not rely on the list of services in `tye.yaml` or a solution file. +Undeploy decides which resources to delete based on the `app.kubernetes.io/part-of=...` label. This label will be set to the application name for all resources created by Tye. `tye undeploy` does not rely on the list of services in `tye.yaml` or a solution file. + +> :bulb: The `tye undeploy` command uses your local Kubernetes context to access the Kubernetes cluster. Make sure `kubectl` is configured to manage your cluster before running `tye undeploy`. ## Arguments