Re: svn commit: r1308650 - /ofbiz/trunk/tools/rc.ofbiz.for.ubuntu

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r1308650 - /ofbiz/trunk/tools/rc.ofbiz.for.ubuntu

Malin Nicolas
Hi hans,

Just some suggests

> @@ -32,14 +32,18 @@ OFBIZDIR="ofbiz"
>
>   # Start OFBiz
>   start() {
> +    if [ "$USER" = "" ]; then
> +        echo "Mounting data disk at boottime here"
> +#        mount /dev/sdg /data
> +    fi
It's not a specific server configuration ?

>       running
>       if [ "$OFBIZ_PROCS" = "" ]; then
>           echo "Ofbiz is already running..."
>           return 0
>       fi
>       if [ "$USER" = "$OFBIZUSER" ]; then
> -        echo "starting standard ~/$OFBIZDIR/startofbiz.sh"
> -        cd ~/$OFBIZDIR
> +        echo "starting standard /home/$OFBIZUSER/$OFBIZDIR/startofbiz.sh"
> +        cd /home/$OFBIZUSER/$OFBIZDIR
I propose to replace "/home/$OFBIZUSER/$OFBIZDIR" by
OFBIZ_LOCATION = "/home/$OFBIZUSER/$OFBIZDIR"
and use like :
cd $OFBIZ_LOCATION

It's will be easier to change the ofbiz location especially if you have
various ofbiz on same server ;)

Nicolas

--
Nicolas MALIN
Consultant
Tél : 06.17.66.40.06
Site projet : http://www.neogia.org/
-------
Société LibrenBerry
Tél : 02.48.02.56.12
Site : http://www.librenberry.net/

Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r1308650 - /ofbiz/trunk/tools/rc.ofbiz.for.ubuntu

Jacopo Cappellato-4
Hans,

could you please already take care of using the files in the tools folder? I could do this but I would not be able to test and since it seems you are already on it it maybe easier for you.

Thanks

Jacopo

On Apr 3, 2012, at 9:12 AM, Nicolas Malin wrote:

> Hi hans,
>
> Just some suggests
>
>> @@ -32,14 +32,18 @@ OFBIZDIR="ofbiz"
>>
>>  # Start OFBiz
>>  start() {
>> +    if [ "$USER" = "" ]; then
>> +        echo "Mounting data disk at boottime here"
>> +#        mount /dev/sdg /data
>> +    fi
> It's not a specific server configuration ?
>
>>      running
>>      if [ "$OFBIZ_PROCS" = "" ]; then
>>          echo "Ofbiz is already running..."
>>          return 0
>>      fi
>>      if [ "$USER" = "$OFBIZUSER" ]; then
>> -        echo "starting standard ~/$OFBIZDIR/startofbiz.sh"
>> -        cd ~/$OFBIZDIR
>> +        echo "starting standard /home/$OFBIZUSER/$OFBIZDIR/startofbiz.sh"
>> +        cd /home/$OFBIZUSER/$OFBIZDIR
> I propose to replace "/home/$OFBIZUSER/$OFBIZDIR" by
> OFBIZ_LOCATION = "/home/$OFBIZUSER/$OFBIZDIR"
> and use like :
> cd $OFBIZ_LOCATION
>
> It's will be easier to change the ofbiz location especially if you have various ofbiz on same server ;)
>
> Nicolas
>
> --
> Nicolas MALIN
> Consultant
> Tél : 06.17.66.40.06
> Site projet : http://www.neogia.org/
> -------
> Société LibrenBerry
> Tél : 02.48.02.56.12
> Site : http://www.librenberry.net/
>

Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r1308650 - /ofbiz/trunk/tools/rc.ofbiz.for.ubuntu

hans_bakker
In reply to this post by Malin Nicolas
Hi Nicolas,

thanks you for your comments. see below

On 04/03/2012 02:12 PM, Nicolas Malin wrote:

> Hi hans,
>
> Just some suggests
>
>> @@ -32,14 +32,18 @@ OFBIZDIR="ofbiz"
>>
>>   # Start OFBiz
>>   start() {
>> +    if [ "$USER" = "" ]; then
>> +        echo "Mounting data disk at boottime here"
>> +#        mount /dev/sdg /data
>> +    fi
> It's not a specific server configuration ?
>
that is why the mount is commented out.
On amazon EC2 you have to mount your external disks before they can be used.

>>       running
>>       if [ "$OFBIZ_PROCS" = "" ]; then
>>           echo "Ofbiz is already running..."
>>           return 0
>>       fi
>>       if [ "$USER" = "$OFBIZUSER" ]; then
>> -        echo "starting standard ~/$OFBIZDIR/startofbiz.sh"
>> -        cd ~/$OFBIZDIR
>> +        echo "starting standard
>> /home/$OFBIZUSER/$OFBIZDIR/startofbiz.sh"
>> +        cd /home/$OFBIZUSER/$OFBIZDIR
> I propose to replace "/home/$OFBIZUSER/$OFBIZDIR" by
> OFBIZ_LOCATION = "/home/$OFBIZUSER/$OFBIZDIR"
> and use like :
> cd $OFBIZ_LOCATION
>
> It's will be easier to change the ofbiz location especially if you
> have various ofbiz on same server ;)
>
user and ofbiz drectoiry are both important:

1. OFBIZUSER is the user running the instance and should be tested if
the script is running as the user
2. OFBIZDIR is the directory of that specific user

if you run more than one instance, you should run them under different
users.

> Nicolas
>

Reply | Threaded
Open this post in threaded view
|

Re: svn commit: r1308650 - /ofbiz/trunk/tools/rc.ofbiz.for.ubuntu

Malin Nicolas
Le 03/04/2012 09:51, Hans Bakker a écrit :

> Hi Nicolas,
>
> thanks you for your comments. see below
>
> On 04/03/2012 02:12 PM, Nicolas Malin wrote:
>> Hi hans,
>>
>> Just some suggests
>>
>>> @@ -32,14 +32,18 @@ OFBIZDIR="ofbiz"
>>>
>>>   # Start OFBiz
>>>   start() {
>>> +    if [ "$USER" = "" ]; then
>>> +        echo "Mounting data disk at boottime here"
>>> +#        mount /dev/sdg /data
>>> +    fi
>> It's not a specific server configuration ?
>>
> that is why the mount is commented out.
> On amazon EC2 you have to mount your external disks before they can be
> used.
Ok I understand, I propose :
+#    # Uncomment for cloud configuration
+#    if [ "$USER" = "" ]; then
+#     echo "Mounting data disk at boottime here"
+#     mount /dev/sdg /data
+#   fi

>>>       running
>>>       if [ "$OFBIZ_PROCS" = "" ]; then
>>>           echo "Ofbiz is already running..."
>>>           return 0
>>>       fi
>>>       if [ "$USER" = "$OFBIZUSER" ]; then
>>> -        echo "starting standard ~/$OFBIZDIR/startofbiz.sh"
>>> -        cd ~/$OFBIZDIR
>>> +        echo "starting standard
>>> /home/$OFBIZUSER/$OFBIZDIR/startofbiz.sh"
>>> +        cd /home/$OFBIZUSER/$OFBIZDIR
>> I propose to replace "/home/$OFBIZUSER/$OFBIZDIR" by
>> OFBIZ_LOCATION = "/home/$OFBIZUSER/$OFBIZDIR"
>> and use like :
>> cd $OFBIZ_LOCATION
>>
>> It's will be easier to change the ofbiz location especially if you
>> have various ofbiz on same server ;)
>>
> user and ofbiz drectoiry are both important:
>
> 1. OFBIZUSER is the user running the instance and should be tested if
> the script is running as the user
> 2. OFBIZDIR is the directory of that specific user
Right, my suggest isn't to remove these variable but just concat  the
location.

> if you run more than one instance, you should run them under different
> users.
Why, it's a politic system architecture not a best practice. Some system
administrator prefer deploy on one user. If the script manage different
solution, it will be even more used :)

Nicolas
>
>> Nicolas
>>
>


--
Nicolas MALIN
Consultant
Tél : 06.17.66.40.06
Site projet : http://www.neogia.org/
-------
Société LibrenBerry
Tél : 02.48.02.56.12
Site : http://www.librenberry.net/