This is an automated email from the ASF dual-hosted git repository. kvn pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/incubator-apisix-dashboard.git
The following commit(s) were added to refs/heads/master by this push: new 8e805f0 feature: support run in mac system (#349) 8e805f0 is described below commit 8e805f0c973a344b02f32a42e648b82b1a037ae0 Author: Lien <lil...@apache.org> AuthorDate: Thu Jul 30 13:07:02 2020 +0800 feature: support run in mac system (#349) --- compose/gen-config-yaml.sh | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/compose/gen-config-yaml.sh b/compose/gen-config-yaml.sh index 0b682c5..794b63b 100644 --- a/compose/gen-config-yaml.sh +++ b/compose/gen-config-yaml.sh @@ -2,10 +2,18 @@ export etcd_url='http://192.17.5.10:2379' +unamestr=`uname` + wget https://raw.githubusercontent.com/apache/incubator-apisix/master/conf/config.yaml -sed -i -e ':a' -e 'N' -e '$!ba' -e "s/allow_admin[a-z: #\/._]*\n\( *- [0-9a-zA-Z: #\/._',]*\n*\)*//g" config.yaml +if [[ "$unamestr" == 'Darwin' ]]; then + sed -i '' -e ':a' -e 'N' -e '$!ba' -e "s/allow_admin[a-z: #\/._]*\n\( *- [0-9a-zA-Z: #\/._',]*\n*\)*//g" config.yaml + sed -i '' -e "s%http://[0-9.]*:2379%`echo $etcd_url`%g" config.yaml +else + sed -i -e ':a' -e 'N' -e '$!ba' -e "s/allow_admin[a-z: #\/._]*\n\( *- [0-9a-zA-Z: #\/._',]*\n*\)*//g" config.yaml + sed -i -e "s%http://[0-9.]*:2379%`echo $etcd_url`%g" config.yaml +fi + -sed -i -e "s%http://[0-9.]*:2379%`echo $etcd_url`%g" config.yaml mv config.yaml ./apisix_conf/config.yaml