[ 
https://issues.apache.org/jira/browse/NIFIREG-145?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Kevin Doran resolved NIFIREG-145.
---------------------------------
       Resolution: Fixed
    Fix Version/s: 0.2.0

> nifi-registry.sh is not strictly sh compatible
> ----------------------------------------------
>
>                 Key: NIFIREG-145
>                 URL: https://issues.apache.org/jira/browse/NIFIREG-145
>             Project: NiFi Registry
>          Issue Type: Bug
>    Affects Versions: 0.1.0
>            Reporter: Kevin Doran
>            Priority: Minor
>             Fix For: 0.2.0
>
>
> {{nifi-registry.sh}} uses some the {{bash}}-specific commands/functions that 
> are not part of {{sh}}.
> For example, [the use of {{source}} on line 
> 88|https://github.com/apache/nifi-registry/blob/rel/nifi-registry-0.1.0/nifi-registry-resources/src/main/resources/bin/nifi-registry.sh#L88],
>  which [does not exist in 
> {{sh}}|https://stackoverflow.com/questions/13702425/source-command-not-found-in-sh-shell/13702462].
> On platforms where the system shell ({{sh}}) symlinks to something other than 
> {{bash}} (apparently it points to {{dash}} on some Debian/Ubuntu 
> distributions), this script can fail with the error message:
> {noformat}
> sh: source: not found
> {noformat}
> We should change the script to be strictly {{sh}}-compatible for portability 
> or change the specified shell on the shebang line to {{#!/bin/bash}}
> ----
> As a workaround for those encountering this issue in nifi-registry-0.1.0:
>  * change line 1 of nifi-registry.sh to {{#!/bin/bash}}; or
>  * change line 88 of nifi-registry.sh to useĀ {{.}} instead of {{source}}; or
>  * leave nifi-registry.sh unmodified, but execute it using bash, ie:
> {noformat}
> bash -e /path/to/nifi-registry/bin/nifi-registry.sh [run|start|stop|...]
> {noformat}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to