Skip to content

Commit

Permalink
Merge pull request #546 from sbt/docs/prepare-for-release
Browse files Browse the repository at this point in the history
Fixing docs with newest changes
  • Loading branch information
muuki88 committed Apr 6, 2015
2 parents f0c2540 + 1dd153c commit 80ef17d
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 2 deletions.
5 changes: 4 additions & 1 deletion src/sphinx/archetypes/java_server/customize.rst
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ You have three options. First, you can specify your options via the ``build.sbt`
For the ``-X`` settings you need to add a suffix ``-J`` so the start script will
recognize these as vm config parameters.

The second option is to create ``src/templates/application.ini`` with the following template
The second option is to create ``src/universal/conf/application.ini`` with the following template

.. code-block :: bash
Expand Down Expand Up @@ -81,6 +81,9 @@ The file will be installed to ``/etc/default/<normalizedName>``
# -----------------
JAVA_OPTS="-Dpidfile.path=/var/run/${{app_name}}/play.pid $JAVA_OPTS"
# For rpm/systemv you need to set the PIDFILE env variable as well
PIDFILE="/var/run/${{app_name}}/play.pid"
# export env vars for 3rd party libs
# ----------------------------------
COMPANY_API_KEY=123abc
Expand Down
21 changes: 20 additions & 1 deletion src/sphinx/topics/play.rst
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ In order to run your application in production you need to provide it with at le
* Location where it can store its pidfile
* Production configuration

One way to provide this information is create ``src/universal/application.ini`` with the following contents:
One way to provide this information is create ``src/universal/conf/application.ini`` with the following contents:

.. code-block:: bash
Expand All @@ -41,5 +41,24 @@ One way to provide this information is create ``src/universal/application.ini``
This way you should either store your production configuration under ``${{path_to_app_name}}/conf/production.conf``
or put it under ``/usr/share/${{app_name}}/conf/production.conf`` by hand or using some configuration management system.

RPM and SystemV
~~~~~~~~~~~~~~~

If you use a system with rpm as a packaging managing system (Fedora, CentOS, RedHat,...) make sure to provide
a `etc-default` in `src/templates` and set the `PIDFILE` environment variable.


.. code-block :: bash
# Setting JAVA_OPTS
# -----------------
# you can use this instead of the application.ini as well
# JAVA_OPTS="-Dpidfile.path=/var/run/${{app_name}}/play.pid $JAVA_OPTS"
# For rpm/systemv you need to set the PIDFILE env variable as well
PIDFILE="/var/run/${{app_name}}/play.pid"
See :doc:`customize java server application </archetypes/java_server/customize>` for more information on `application.ini`
and `etc-default` template.

0 comments on commit 80ef17d

Please sign in to comment.