You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@karaf.apache.org by "Niels Bertram (JIRA)" <ji...@apache.org> on 2016/04/10 12:43:25 UTC

[jira] [Created] (KARAF-4483) Wrapper adds wrong line to bin/karaf-service shell script

Niels Bertram created KARAF-4483:
------------------------------------

             Summary: Wrapper adds wrong line to bin/karaf-service shell script
                 Key: KARAF-4483
                 URL: https://issues.apache.org/jira/browse/KARAF-4483
             Project: Karaf
          Issue Type: Bug
          Components: karaf-core
    Affects Versions: 3.0.6
            Reporter: Niels Bertram
            Priority: Minor


Installing the wrapper on karat 3.0.6 on RHEL 6.7 generates a wrong init.d shell script.

1. unpack the apache-karaf-3.0.6.tar.gz distributable

2. modify {{bin/setenv}} and set {{JAVA_HOME}} to a valid JDK location

3. start karaf and install wrapper files
{code}
feature:install wrapper
wrapper:install
{code}

4. Inspect generated {{bin/karaf-service}} file

Pretty much at the top of the file a line as follows appears
{code}
set JAVA_HOME=/usr/java/jdk1.8.0_71
{code}

which causes the shell script to eat the provided args and fails with 
{code}
$ bin/karaf-service start
Usage: bin/karaf-service { console | start | stop | restart | status | dump }
{code}

Also if the JAVA_HOME is NOT set in the {{bin/setenv}} file, the following line is added to {{bin/karaf-service}}:

{code}
set JAVA_HOME=null
{code}





--
This message was sent by Atlassian JIRA
(v6.3.4#6332)