{"metadata":{"image":[],"title":"","description":""},"api":{"url":"","auth":"required","results":{"codes":[]},"settings":"","params":[]},"next":{"description":"","pages":[]},"title":"Spread Versioning","type":"basic","slug":"spread-versioning","excerpt":"","body":"Spread versions your software environment (i.e. a Kubernetes cluster) like Git versions source code. Because Spread is built on top of libgit2, it takes advantage of Git's interface and functionality. This means after you deploy a Kubernetes object to a cluster, you can version the object by staging, committing, and pushing it to a Spread repository. \n\nTo get started, initialize Spread and set up a local Spread repository:\n\n`spread init`\n\nHere is our suggested workflow for versioning with Spread:\n\n1. Create or edit your Kubernetes objects\n2. Deploy your objects to a local or remote Kubernetes cluster (make sure you've [set up your directory](https://github.com/redspread/spread/tree/versioning#faq) correctly): `spread deploy .`\n3. Stage an object: `spread add <objectType>/<objectName>`\n4. Repeat until all objects have been staged\n5. Commit your objects with a message: `spread commit -m \"commit message\"`\n6. Set up your remote repository: `spread remote (add <name> <url> | remove <name> | set-url <name> <url>)`\n7. Push your objects to your remote repository: `spread push <remote> <refSpec>`\n8. Go ahead and try out the [other commands](https://redspread.readme.io/docs/spread-commands) - anything not documented can be accessed using `spread git ...`\n\nIf you find any bugs or have any feature requests for Spread versioning, please file an issue!","updates":[],"order":3,"isReference":false,"hidden":false,"sync_unique":"","link_url":"","link_external":false,"_id":"57acceed71d2991900b9a630","category":{"sync":{"isSync":false,"url":""},"pages":[],"title":"Documentation","slug":"documentation","order":0,"from_sync":false,"reference":false,"_id":"57acceed71d2991900b9a62c","version":"57acceed71d2991900b9a62b","project":"570086efa565e20e001573b3","createdAt":"2016-04-03T02:58:55.770Z","__v":0},"project":"570086efa565e20e001573b3","version":{"version":"1.0.0","version_clean":"1.0.0","codename":"","is_stable":true,"is_beta":false,"is_hidden":false,"is_deprecated":false,"categories":["57acceed71d2991900b9a62c"],"_id":"57acceed71d2991900b9a62b","createdAt":"2016-08-11T19:15:57.383Z","project":"570086efa565e20e001573b3","releaseDate":"2016-08-11T19:15:57.383Z","__v":1},"user":"569d7767ec29360d00f667c7","githubsync":"","createdAt":"2016-06-18T21:43:13.315Z","__v":0}
Spread versions your software environment (i.e. a Kubernetes cluster) like Git versions source code. Because Spread is built on top of libgit2, it takes advantage of Git's interface and functionality. This means after you deploy a Kubernetes object to a cluster, you can version the object by staging, committing, and pushing it to a Spread repository. To get started, initialize Spread and set up a local Spread repository: `spread init` Here is our suggested workflow for versioning with Spread: 1. Create or edit your Kubernetes objects 2. Deploy your objects to a local or remote Kubernetes cluster (make sure you've [set up your directory](https://github.com/redspread/spread/tree/versioning#faq) correctly): `spread deploy .` 3. Stage an object: `spread add <objectType>/<objectName>` 4. Repeat until all objects have been staged 5. Commit your objects with a message: `spread commit -m "commit message"` 6. Set up your remote repository: `spread remote (add <name> <url> | remove <name> | set-url <name> <url>)` 7. Push your objects to your remote repository: `spread push <remote> <refSpec>` 8. Go ahead and try out the [other commands](https://redspread.readme.io/docs/spread-commands) - anything not documented can be accessed using `spread git ...` If you find any bugs or have any feature requests for Spread versioning, please file an issue!