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/apisix-docker.git
The following commit(s) were added to refs/heads/master by this push: new 6ac41f4 fix: mv config.yml to config-default.yml in the latest version of apisix (#72) 6ac41f4 is described below commit 6ac41f4c99df37cc31f6ee2ed99f1e973f6b24f6 Author: kv <gxt...@163.com> AuthorDate: Sat Aug 22 20:52:55 2020 +0800 fix: mv config.yml to config-default.yml in the latest version of apisix (#72) * fix: mv config.yml to config-default.yml in the latest version of apisix * fix: wget output config.yaml * fix: wget -O * fix: bad indentation --- example/gen-config-yaml.sh | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/example/gen-config-yaml.sh b/example/gen-config-yaml.sh index b2d9eeb..7a59529 100644 --- a/example/gen-config-yaml.sh +++ b/example/gen-config-yaml.sh @@ -2,10 +2,14 @@ export etcd_url='http://172.18.5.10:2379' -wget https://raw.githubusercontent.com/apache/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 - -sed -i -e "s%http://[0-9.]*:2379%`echo $etcd_url`%g" config.yaml +wget https://raw.githubusercontent.com/apache/apisix/master/conf/config-default.yaml -O 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 mv config.yaml ./apisix_conf/config.yaml \ No newline at end of file