Return-Path: X-Original-To: apmail-karaf-issues-archive@minotaur.apache.org Delivered-To: apmail-karaf-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 8D38A11291 for ; Wed, 24 Sep 2014 12:16:34 +0000 (UTC) Received: (qmail 36934 invoked by uid 500); 24 Sep 2014 12:16:34 -0000 Delivered-To: apmail-karaf-issues-archive@karaf.apache.org Received: (qmail 36905 invoked by uid 500); 24 Sep 2014 12:16:34 -0000 Mailing-List: contact issues-help@karaf.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@karaf.apache.org Delivered-To: mailing list issues@karaf.apache.org Received: (qmail 36892 invoked by uid 99); 24 Sep 2014 12:16:34 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 24 Sep 2014 12:16:34 +0000 Date: Wed, 24 Sep 2014 12:16:34 +0000 (UTC) From: "Patrick Kranz (JIRA)" To: issues@karaf.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (KARAF-2890) The env variables can't be read while running karaf as a Linux service MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/KARAF-2890?page=3Dcom.atlassian= .jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=3D1414= 6260#comment-14146260 ]=20 Patrick Kranz commented on KARAF-2890: -------------------------------------- Thank you very much! > The env variables can't be read while running karaf as a Linux service > ---------------------------------------------------------------------- > > Key: KARAF-2890 > URL: https://issues.apache.org/jira/browse/KARAF-2890 > Project: Karaf > Issue Type: Bug > Affects Versions: 2.3.3 > Reporter: Xilai Dai > Assignee: Jean-Baptiste Onofr=C3=A9 > Fix For: 4.0.0, 3.0.2, 2.4.1, 2.3.9 > > > Install karaf as a Linux service following steps: > 1. features:install wrapper > 2. wrapper:install -s AUTO_START -n talend-runtime -d talend-runtime -D "= Talend Runtime Service" > $ ln -s /Talend/runtime/bin/talend-runtime-service /etc/init.d/talend-run= time > the fragment from generated script: > {code} > # Still want to change users, recurse. This means that the user will onl= y be > # prompted for a password once. > su -m $RUN_AS_USER -s /bin/sh -c "$REALPATH $1" > {code} > it should be: > {code} > # Still want to change users, recurse. This means that the user will on= ly be > # prompted for a password once. > su - -m $RUN_AS_USER -c "$REALPATH $1" > {code} > Because the user login script (.bash_profile) can't be executed without '= -' after 'su'; and '-s /bin/sh' is not standard, the default shell of the r= un_as user (e.g. bash) should be used. -- This message was sent by Atlassian JIRA (v6.3.4#6332)