Open xhoaluu opened 6 years ago
The reason behind is XMLStarlet
that changes all empty tags to single closing element
< apikey ></ apikey >
==> <apikey/>
which is technically ok
but as you said
SED is expecting something else i.e < apikey ></ apikey >
so we wont be able to change it after 1st run
letme think of a solution
I'm using xmlstarlet 1.6.1 For the first time run start-restcomm.sh: restcomm.xml will be updated exactly what we need. But for second roud, we cannot update restcomm.xml via restcomm.conf any more.
For example: 1/ VOICE_KEY = null Original restcomm.xml: < apikey ></ apikey > 1st restcomm.xml: </ apikey> 2/ VOICE_KEY = 'abcxyz' 2nd restcomm.xml: </ apikey>
As in sub sh file (config-restcomm.sh ... etc), the script is expecting < apikey>.*</ apikey>, But after 1 time update with null value, it's which is does not match with expectation of sed.