ReleaseHandling

Release Handling

Introducing reltool.config

Rebar produces the reltool.config configuration file in response to performing the create-node command. The reltool.config contains configuration information consumed by rebar, and Reltool (the release management tool introduced in the Erlang R13B distribution).

Create the application:

$ ./rebar create-app appid=exemplar

Notice: The commands 'create-app' and 'create-node' can be seen in rebar_templater.erl. Also, the variables that may be supplied to these commands can be seen in the respective templates, simpleapp.template and simplenode.template.

And to create the node:

Manually create the rel directory:

$ mkdir rel
$ cd rel

create the node:

$ ../rebar create-node nodeid=exemplar

$ ls -lR
total 8
drwxr-xr-x  5 iw  iw  170 13 Jan 13:33 overlay
-rw-r--r--  1 iw  iw  612 13 Jan 13:33 reltool.config

./overlay:
total 0
drwxr-xr-x  3 iw  iw  102 13 Jan 13:33 bin
drwxr-xr-x  3 iw  iw  102 13 Jan 13:33 erts-vsn
drwxr-xr-x  4 iw  iw  136 13 Jan 13:33 etc

./overlay/bin:
total 8
-rw-r--r--  1 iw  iw  3368 13 Jan 13:33 exemplar

./overlay/erts-vsn:
total 0
drwxr-xr-x  4 iw  iw  136 13 Jan 13:33 bin

./overlay/erts-vsn/bin:
total 16
-rw-r--r--  1 iw  iw  1118 13 Jan 13:33 erl
-rw-r--r--  1 iw  iw  2940 13 Jan 13:33 nodetool

./overlay/etc:
total 16
-rw-r--r--  1 iw  iw  334 13 Jan 13:33 app.config
-rw-r--r--  1 iw  iw  423 13 Jan 13:33 vm.args

To produce a release:

Add the following to rebar.config:

{sub_dirs, ["rel"]}.

and perform:

$ ./rebar generate
==> rel (generate)

This will produce the target system exemplar within the rel directory:

$ ls -l rel/exemplar/
total 0
drwxr-xr-x   3 iw  iw   102 13 Jan 13:52 bin
drwxr-xr-x   8 iw  iw   272 13 Jan 13:52 erts-5.7.4
drwxr-xr-x   3 iw  iw   102 13 Jan 13:52 erts-vsn
drwxr-xr-x   4 iw  iw   136 13 Jan 13:52 etc
drwxr-xr-x  33 iw  iw  1122 13 Jan 13:52 lib
drwxr-xr-x   3 iw  iw   102 13 Jan 13:52 log
drwxr-xr-x   4 iw  iw   136 13 Jan 13:52 releases

Updated

Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.