Rancher CLI: What does the up command do?


I can’t find documentation on what the rancher v2 CLI up command is used for. I’ve seen references to using Kubernetes yaml files but that doesn’t seem to do anything:

$ cat secret.yaml
apiVersion: v1
kind: Secret
  name: mysecret
type: Opaque
  username: oliver
  password: P@ssw0rd

$ rancher up -f secret.yaml
$ rancher inspect --type secret mysecret
FATA[0002] Not found: mysecret

The --help command doesn’t help much as it just tells me to pass in “a compose file” but it seems like docker-compose files aren’t supported:

$ rancher up --help
apply compose config

  rancher up [OPTIONS] [arg...]

   --file value, -f value  The location of compose config file
  • What type of file should I be using?
  • Can someone provide an example file?
  • Are there args expected for up? What would an arg be used for?
  • More generally, how can we improve the command line documentation so it’s clear what sort of file is expected?


I don’t know too much about it, but yes I have had the same question for quite some time.
The only thing I have found was in the 1.6 documentation for rancher up. Maybe that might help you have a better idea… though the command might be deprecated in 2.0. Hope that helps!


This previous comment is where I got the idea to use kubernetes manifests:

The 2.x and 1.x are basically entirely unrelated, including the CLI. 2.x supports kubernetes manifests, not docker-compose files.