~alpine/devel

This thread contains a patchset. You're looking at the original emails, but you may wish to use the patch review UI. Review patch
9 3

[alpine-devel] [PATCH] Updated freeswitch.initd to include missing path switches.

Tobie Booth <tbooth@hindbra.in>
Details
Message ID
<1397371981-3308-1-git-send-email-tbooth@hindbra.in>
Sender timestamp
1397371981
DKIM signature
missing
Download raw message
Patch: +5 -1
Changed the freeswitch package's freeswitch.initd to include the switches
for the grammar, recordings, storage, and sounds directories. Currently
without them it's trying to use the default /usr prefix making voicemail
and other things unusable out of the box.

The switches are set as follows:
Recordings - /var/lib/freeswitch/recordings (this directory already exists)
Grammar - /var/lib/freeswitch/grammar (this directory already exists)
Sounds - /usr/share/freeswitch/sounds (this directory already exists)
Storage - /var/lib/freeswitch/ (this will cause http_file_cache and
	voicemail directories to be created on first start)

Thanks.
---
 main/freeswitch/freeswitch.initd | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/main/freeswitch/freeswitch.initd b/main/freeswitch/freeswitch.initd
index cc9bac4..c56a49d 100755
--- a/main/freeswitch/freeswitch.initd
+++ b/main/freeswitch/freeswitch.initd
@@ -31,8 +31,12 @@ start() {
		-- \
		-nc -conf /etc/freeswitch -log /var/log/freeswitch \
		-run /var/run/freeswitch -db /var/lib/freeswitch/db \
		-recordings /var/lib/freeswitch/recordings \
		-grammar /var/lib/freeswitch/grammar \
		-sounds /usr/share/freeswitch/sounds \
		-htdocs /usr/share/freeswitch/htdocs \
		-scripts /etc/freeswitch/scripts ${OPTS}
		-scripts /etc/freeswitch/scripts \
		-storage /var/lib/freeswitch ${OPTS}
	eend $?
}

-- 
1.8.4.3



---
Unsubscribe:  alpine-devel+unsubscribe@lists.alpinelinux.org
Help:         alpine-devel+help@lists.alpinelinux.org
---
Tobie Booth <tbooth@hindbra.in>
Details
Message ID
<etPan.534a4cae.216231b.134@tobies-mac-pro.home.hindbra.in>
In-Reply-To
<20140413075957.497c6499@ncopa-desktop.alpinelinux.org> (view parent)
Sender timestamp
1397378221
DKIM signature
missing
Download raw message
I definitely think that would be the way to go. 

The problem is, in my mind (possibly spoiled by other distros) I expect to install freeswitch, freeswitch-sample-config, and freeswitch-sounds-* and have at least voicemail and other basic apps. However they fail and crash due to the incorrect file paths. Do you guys agree/disagree with this thought process? 

Unfortunately they can only be changed globally via the switches.

> On April 13, 2014 at 3:00:02 AM, Natanael Copa (ncopa@alpinelinux.org) wrote:
> On Sun, 13 Apr 2014 09:32:55 +0200  
> Der Tiger <der.tiger.alpine@arcor.de> wrote:  

>> Hi,  
>>  
>> In order to make those switches adjustable by the user, I suggest to set  
>> them in /etc/conf.d/freeswitch utilizing the ${OPTS} variable in the  
>> init.d script rather than make them hard-coded in /etc/init.d/freeswitch  
>> itself, because some folks my want to store recordings on a different  
>> drive or use their own set of grammar and voice files.  

> Yes, and it will break things for those who actually have things stored  
> other location.  

> Maybe we should introduce variables with sane values:  

> -recordings ${recordings_dir:-/var/lib/freeswitch/recordings} \  
> -grammar ${grammar_dir:-/var/lib/freeswitch/grammar} \  
> -sounds ${sounds_dir:-/usr/share/freeswitch/sounds} \  
> -storage ${storage_dir:-/var/lib/freeswitch} \ 
> ${OPTS}  
Natanael Copa <ncopa@alpinelinux.org>
Details
Message ID
<20140413075957.497c6499@ncopa-desktop.alpinelinux.org>
In-Reply-To
<534A3DA7.6090609@arcor.de> (view parent)
Sender timestamp
1397375997
DKIM signature
missing
Download raw message
On Sun, 13 Apr 2014 09:32:55 +0200
Der Tiger <der.tiger.alpine@arcor.de> wrote:

> Hi,
> 
> In order to make those switches adjustable by the user, I suggest to set
> them in /etc/conf.d/freeswitch utilizing the ${OPTS} variable in the
> init.d script rather than make them hard-coded in /etc/init.d/freeswitch
> itself, because some folks my want to store recordings on a different
> drive or use their own set of grammar and voice files.

Yes, and it will break things for those who actually have things stored
other location.

Maybe we should introduce variables with sane values:

 -recordings ${recordings_dir:-/var/lib/freeswitch/recordings} \
 -grammar ${grammar_dir:-/var/lib/freeswitch/grammar} \
 -sounds ${sounds_dir:-/usr/share/freeswitch/sounds} \
 -storage ${storage_dir:-/var/lib/freeswitch} \
 ${OPTS}



> 
> So Long, Tiger
> 
> On 2014-04-13 08:53, Tobie Booth wrote:
> >  main/freeswitch/freeswitch.initd | 6 +++++-
> >  1 file changed, 5 insertions(+), 1 deletion(-)
> >
> 
> 
> 
> ---
> Unsubscribe:  alpine-devel+unsubscribe@lists.alpinelinux.org
> Help:         alpine-devel+help@lists.alpinelinux.org
> ---
> 



---
Unsubscribe:  alpine-devel+unsubscribe@lists.alpinelinux.org
Help:         alpine-devel+help@lists.alpinelinux.org
---
Details
Message ID
<534A3DA7.6090609@arcor.de>
In-Reply-To
<1397371981-3308-1-git-send-email-tbooth@hindbra.in> (view parent)
Sender timestamp
1397374375
DKIM signature
missing
Download raw message
Hi,

In order to make those switches adjustable by the user, I suggest to set
them in /etc/conf.d/freeswitch utilizing the ${OPTS} variable in the
init.d script rather than make them hard-coded in /etc/init.d/freeswitch
itself, because some folks my want to store recordings on a different
drive or use their own set of grammar and voice files.

So Long, Tiger

On 2014-04-13 08:53, Tobie Booth wrote:
>  main/freeswitch/freeswitch.initd | 6 +++++-
>  1 file changed, 5 insertions(+), 1 deletion(-)
>



---
Unsubscribe:  alpine-devel+unsubscribe@lists.alpinelinux.org
Help:         alpine-devel+help@lists.alpinelinux.org
---
Details
Message ID
<534A6B89.7000503@arcor.de>
In-Reply-To
<20140413075957.497c6499@ncopa-desktop.alpinelinux.org> (view parent)
Sender timestamp
1397386121
DKIM signature
missing
Download raw message
Natanael,


On 2014-04-13 09:59, Natanael Copa wrote:
> On Sun, 13 Apr 2014 09:32:55 +0200
> Der Tiger <der.tiger.alpine@arcor.de> wrote:
>
>> In order to make those switches adjustable by the user, I suggest to set
>> them in /etc/conf.d/freeswitch utilizing the ${OPTS} variable in the
>> init.d script rather than make them hard-coded in /etc/init.d/freeswitch
>> itself, because some folks my want to store recordings on a different
>> drive or use their own set of grammar and voice files.
> Yes, and it will break things for those who actually have things stored
> other location.
I don't see why pre-setting ${OPTS} in /etc/conf.d/freeswitch would
break anything for anyone. Anyway, introducing separate variables for
each switch, as you suggested, is certainly the better way to go.

> Maybe we should introduce variables with sane values:
>
>  -recordings ${recordings_dir:-/var/lib/freeswitch/recordings} \
>  -grammar ${grammar_dir:-/var/lib/freeswitch/grammar} \
>  -sounds ${sounds_dir:-/usr/share/freeswitch/sounds} \
>  -storage ${storage_dir:-/var/lib/freeswitch} \
>  ${OPTS}
>
Regards, Tiger


---
Unsubscribe:  alpine-devel+unsubscribe@lists.alpinelinux.org
Help:         alpine-devel+help@lists.alpinelinux.org
---
Tobie Booth <tbooth@hindbra.in>
Details
Message ID
<etPan.534b8a73.1190cde7.134@tobies-mac-pro.home.hindbra.in>
In-Reply-To
<20140414063238.0ab5fcf7@ncopa-desktop.alpinelinux.org> (view parent)
Sender timestamp
1397459571
DKIM signature
missing
Download raw message
On April 14, 2014 at 1:32:42 AM, Natanael Copa (ncopa@alpinelinux.org) wrote:

> Could you please file a new issue for it on bugs.alpinelinux.org, so I  
> don't forget it. 

Done: https://bugs.alpinelinux.org/issues/2841

>> Unfortunately they can only be changed globally via the switches.  

> I did try fix the default locations to be configurable at build time  
> but I don't remember if I ever made it work. The intention was to store  
> data in /var/lib/freeswitch by default.  

> http://jira.freeswitch.org/browse/FS-302 

Hmm interesting. Might see if that still works in 1.4.0 if I find the time.


> Another unrelated issue is that it does not currently build with musl  
> libc and we need to fix that before 3.0 release.  

Yea, TL;DR we’re looking at using Alpine as the basis for one of our VoIP on-site PBX solutions. In the end we’ll have our own repo with our proprietary stuff in it but would love to use any of the packages we need that already exist. Regarding that would love to help out any way we can to get make sure the Freeswitch-* packages stay current/working. Unfortunately none of us are any good at C so I wouldn’t even know where to start on that lol.
Natanael Copa <ncopa@alpinelinux.org>
Details
Message ID
<20140414062647.6308262e@ncopa-desktop.alpinelinux.org>
In-Reply-To
<534A6B89.7000503@arcor.de> (view parent)
Sender timestamp
1397456807
DKIM signature
missing
Download raw message
On Sun, 13 Apr 2014 12:48:41 +0200
Der Tiger <der.tiger.alpine@arcor.de> wrote:

> Natanael,
> 
> 
> On 2014-04-13 09:59, Natanael Copa wrote:
> > On Sun, 13 Apr 2014 09:32:55 +0200
> > Der Tiger <der.tiger.alpine@arcor.de> wrote:
> >
> >> In order to make those switches adjustable by the user, I suggest to set
> >> them in /etc/conf.d/freeswitch utilizing the ${OPTS} variable in the
> >> init.d script rather than make them hard-coded in /etc/init.d/freeswitch
> >> itself, because some folks my want to store recordings on a different
> >> drive or use their own set of grammar and voice files.
> > Yes, and it will break things for those who actually have things stored
> > other location.

> I don't see why pre-setting ${OPTS} in /etc/conf.d/freeswitch would
> break anything for anyone. Anyway, introducing separate variables for
> each switch, as you suggested, is certainly the better way to go.

Sorry, I was unclear. What I meant was that hardcoding the paths in
init.d will not only prevent people to store things in other location
if they want. It will break things for those who already does it.

Relying on $OPTS only will not break that, but otoh it will not solve
the problem Tobie wants to solve either: a working default config.

-nc


---
Unsubscribe:  alpine-devel+unsubscribe@lists.alpinelinux.org
Help:         alpine-devel+help@lists.alpinelinux.org
---
Natanael Copa <ncopa@alpinelinux.org>
Details
Message ID
<20140414063238.0ab5fcf7@ncopa-desktop.alpinelinux.org>
In-Reply-To
<etPan.534a4cae.216231b.134@tobies-mac-pro.home.hindbra.in> (view parent)
Sender timestamp
1397457158
DKIM signature
missing
Download raw message
On Sun, 13 Apr 2014 03:37:01 -0500
Tobie Booth <tbooth@hindbra.in> wrote:

> I definitely think that would be the way to go. 
> 
> The problem is, in my mind (possibly spoiled by other distros) I expect to install freeswitch, freeswitch-sample-config, and freeswitch-sounds-* and have at least voicemail and other basic apps. However they fail and crash due to the incorrect file paths. Do you guys agree/disagree with this thought process? 

I definitively agree. We want default configs to just work if possible.
I was just not aware that it didn't.

Could you please file a new issue for it on bugs.alpinelinux.org, so I
don't forget it.

> Unfortunately they can only be changed globally via the switches.

I did try fix the default locations to be configurable at build time
but I don't remember if I ever made it work. The intention was to store
data in /var/lib/freeswitch by default.

http://jira.freeswitch.org/browse/FS-302


Another unrelated issue is that it does not currently build with musl
libc and we need to fix that before 3.0 release.


-nc


---
Unsubscribe:  alpine-devel+unsubscribe@lists.alpinelinux.org
Help:         alpine-devel+help@lists.alpinelinux.org
---
Natanael Copa <ncopa@alpinelinux.org>
Details
Message ID
<20140414102254.24d7542d@ncopa-desktop.alpinelinux.org>
In-Reply-To
<etPan.534b8a73.1190cde7.134@tobies-mac-pro.home.hindbra.in> (view parent)
Sender timestamp
1397463774
DKIM signature
missing
Download raw message
On Mon, 14 Apr 2014 02:12:51 -0500
Tobie Booth <tbooth@hindbra.in> wrote:

> On April 14, 2014 at 1:32:42 AM, Natanael Copa (ncopa@alpinelinux.org) wrote:
> 
> > Could you please file a new issue for it on bugs.alpinelinux.org, so I  
> > don't forget it. 
> 
> Done: https://bugs.alpinelinux.org/issues/2841
> 
> >> Unfortunately they can only be changed globally via the switches.  
> 
> > I did try fix the default locations to be configurable at build time  
> > but I don't remember if I ever made it work. The intention was to store  
> > data in /var/lib/freeswitch by default.  
> 
> > http://jira.freeswitch.org/browse/FS-302 
> 
> Hmm interesting. Might see if that still works in 1.4.0 if I find the time.
> 
> 
> > Another unrelated issue is that it does not currently build with musl  
> > libc and we need to fix that before 3.0 release.  
> 
> Yea, TL;DR we*re looking at using Alpine as the basis for one of our VoIP on-site PBX solutions. In the end we*ll have our own repo with our proprietary stuff in it but would love to use any of the packages we need that already exist. Regarding that would love to help out any way we can to get make sure the Freeswitch-* packages stay current/working. Unfortunately none of us are any good at C so I wouldn*t even know where to start on that lol.

Other thing I just realized is that the current stable freeswitch
branch seems to be v1.2. They did v1.2.23 in March 19, 2014, while latest
v1.4 was 12 July 2013. v1.4 seems to be a beta branch.

Oh, they actually do 'releases', at least they do release tags once in a while:
http://git.freeswitch.org/git/freeswitch/

v1.5.11 is tagged.

But they don't upload those to http://files.freeswitch.org/

I have always found the freeswitch release engineering very confusing.

If someonw has any good ideas what to do with freeswitch (eg which
version do we ship with alpine 3.0), please let me know.

 -nc


---
Unsubscribe:  alpine-devel+unsubscribe@lists.alpinelinux.org
Help:         alpine-devel+help@lists.alpinelinux.org
---
Tobie Booth <tbooth@hindbra.in>
Details
Message ID
<etPan.534c04c7.75a2a8d4.a3b5@tobies-mac-pro.dntmedia.net>
In-Reply-To
<20140414102254.24d7542d@ncopa-desktop.alpinelinux.org> (view parent)
Sender timestamp
1397490887
DKIM signature
missing
Download raw message
On April 14, 2014 at 3:23:00 AM, Natanael Copa (ncopa@alpinelinux.org) wrote:

Other thing I just realized is that the current stable freeswitch 
branch seems to be v1.2. They did v1.2.23 in March 19, 2014, while latest 
v1.4 was 12 July 2013. v1.4 seems to be a beta branch. 

Oh, they actually do 'releases', at least they do release tags once in a while: 
http://git.freeswitch.org/git/freeswitch/ 

v1.5.11 is tagged. 

But they don't upload those to http://files.freeswitch.org/ 

I have always found the freeswitch release engineering very confusing. 

If someonw has any good ideas what to do with freeswitch (eg which 
version do we ship with alpine 3.0), please let me know. 

-nc 


Yea I could understand how that could be confusing. I think a lot of it stems from the fact that master on the git used to be considered stable (tagged versions only existed to please other distros by having a tagged stable). They’ve recently changed that and started going back to 1.2.* = stable, 1.4.* = beta, master = dev. So technically I think the packaged version in main should be 1.2.*.
Reply to thread Export thread (mbox)