forked from cloudfoundry/docs-bosh
-
Notifications
You must be signed in to change notification settings - Fork 0
/
uploading-releases.html.md.erb
86 lines (57 loc) · 2.9 KB
/
uploading-releases.html.md.erb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
---
title: Uploading Releases
---
(See [What is a Release?](release.html) for an introduction to releases.)
As described earlier, each deployment references one or many releases on the Director. Before the Director can form a deployment, all referenced releases must be uploaded to the Director.
## <a id='find'></a> Finding Releases
Releases are distributed in two ways: as a release tarball or through a source code repository. The [releases section of bosh.io](//bosh.io/releases) provides a good list of available releases and their tarballs.
Here are a few popular releases:
- [cf-release](//bosh.io/releases/github.com/cloudfoundry/cf-release) provides CloudFoundry
- [cf-mysql-release](//bosh.io/releases/github.com/cloudfoundry/cf-mysql-release) provides highly-available MySQL
- [cf-rabbitmq-release](//bosh.io/releases/github.com/pivotal-cf/cf-rabbitmq-release) provides RabbitMQ
---
## <a id='upload'></a> Uploading to the Director
Assuming that the CLI is already targeted at the Director, the CLI provides a single command to upload a release.
- If you have a URL to a release tarball (for example a URL provided by bosh.io):
<pre class="terminal">
$ bosh upload release https://bosh.io/d/github.com/cloudfoundry/cf-release
</pre>
Alternatively, if you have a release tarball on your local machine:
<pre class="terminal">
$ bosh upload release ~/Downloads/redis-12.tgz
</pre>
- If you cloned a Git repository:
Note that all release repositories have a `releases/` folder that contains release YAML files. These files have all the required information about how to assemble a specific version of a release (provided that the release maintainers produce and commit that version to the repository). You can use the YAML files to either directly upload a release, or to create a release tarball locally and then upload it.
<pre class="terminal">
$ cd ~/workspace/redis-boshrelease
$ bosh upload release releases/redis/redis-12.yml
</pre>
Alternatively, to build a release tarball locally from a release YAML file:
<pre class="terminal">
$ cd ~/workspace/redis-boshrelease
$ bosh create release releases/redis/redis-12.yml --with-tarball
$ bosh upload release releases/redis/redis-12.tgz
</pre>
Once the command succeeds, you can view all uploaded releases in the Director:
<pre class="terminal">
$ bosh releases
+--------+----------+-------------+
| Name | Versions | Commit Hash |
+--------+----------+-------------+
| redis | 12 | 3eb40ae4 |
| mesos | 1 | d07b570b |
+--------+----------+-------------+
(*) Currently deployed
(+) Uncommitted changes
Releases total: 5
</pre>
---
## <a id='using'></a> Deployment Manifest Usage
To use an uploaded release in your deployment, update the `releases` section in your deployment manifest:
```yaml
releases:
- {name: redis, version: 12}
```
---
Next: [Deploying](deploying.html)
Previous: [Uploading Stemcells](uploading-stemcells.html)