+1, it's friendly to use.


[email protected]
 
From: Ming Wen
Date: 2020-08-19 21:22
To: dev
Subject: Re: [DISCUSS]Need a way to support running APISIX in github actions
looks good to me
 
Thanks,
Ming Wen, Apache APISIX & Apache SkyWalking
Twitter: _WenMing
 
 
vincixu <[email protected]> 于2020年8月19日周三 下午7:56写道:
 
> We change to:
> ```
> etcd:
>   host:  ${ENV_ETCD_URLS}
> ```
> " ENV_ETCD_URLS " is a comma separated string.
> When users configured it, we can split and set it to host.
> If not existing the environment var, just keep original hosts in
> config.yaml.
>
> Ming Wen <[email protected]> 于2020年8月19日周三 下午6:20写道:
>
> > what about etcd cluster?
> >
> > vincixu <[email protected]> 于 2020年8月19日周三 下午12:39写道:
> >
> > >   Great, I like this way!
> > >
> > > YuanSheng Wang <[email protected]> 于2020年8月18日周二 下午8:29写道:
> > >
> > > > > 1. APISIX supports specifying etcd host through environment
> variables
> > > >
> > > > Support to use ENV variable as `etcd` address, I think it is a simple
> > > way.
> > > >
> > > > Here is an example:
> > > >
> > > > ```
> > > > etcd:
> > > >   host:
> > > >     - "http://${ENV_ETCD_HOST}:2379";
> > > > ```
> > > >
> > > >
> > > > On Tue, Aug 18, 2020 at 10:29 AM vincixu <[email protected]> wrote:
> > > >
> > > > > Docker image support reading variables  from environment( command
> > > > arguments
> > > > > or environment variables ) is a best practice in container
> world(e.g
> > > > > Prometheus,  Grafana, Jaeger, Envoy).
> > > > > I think we should support this in APISIX docker image, keep CI
> > > > > configurations as simple as possible.
> > > > >
> > > > > junxu chen <[email protected]> 于2020年8月17日周一 下午6:16写道:
> > > > >
> > > > > > > GitHub Actions is also contains shell script, why cannot mount
> > file
> > > > for
> > > > > > docker?
> > > > > >
> > > > > > Yes, we can mount files by running docker with shell.
> > > > > >
> > > > > > But this way has other problems. The github action uses a network
> > > with
> > > > a
> > > > > > random name.
> > > > > > It is not easy for us to get the name of this network to join
> this
> > > > > network.
> > > > > >
> > > > > > We also cannot use `host.docker.internal` to access the host.
> > > > > >
> > > > > > Therefore, in the APISIX docker container etcd is not accessible.
> > > > > >
> > > > > > Of course, it is possible to resolve the problem, but it is too
> > > > difficult
> > > > > > for users.
> > > > > >
> > > > > > On Mon, Aug 17, 2020 at 4:38 PM Ming Wen <[email protected]>
> > wrote:
> > > > > >
> > > > > > > Can you show a example?
> > > > > > > GitHub Actions is also contains shell script, why cannot mount
> > file
> > > > for
> > > > > > > docker?
> > > > > > >
> > > > > > > Thanks,
> > > > > > > Ming Wen, Apache APISIX & Apache SkyWalking
> > > > > > > Twitter: _WenMing
> > > > > > >
> > > > > > >
> > > > > > > junxu chen <[email protected]> 于2020年8月17日周一 下午4:30写道:
> > > > > > >
> > > > > > > > > Can config.yaml be used as an external file for Apache
> APISIX
> > > in
> > > > > > > docker?
> > > > > > > >
> > > > > > > > It is  ok under normal circumstances. But in the github
> action,
> > > > > > > `services`
> > > > > > > > or `container` is the earliest initialization, and then the
> > file
> > > > can
> > > > > be
> > > > > > > > cloned from the repo. So we couldn't mount the `config.yaml`.
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > > On Mon, Aug 17, 2020 at 4:15 PM Ming Wen <[email protected]
> >
> > > > wrote:
> > > > > > > >
> > > > > > > > > > 1. APISIX supports specifying etcd host through
> environment
> > > > > > variables
> > > > > > > > > Can config.yaml be used as an external file for Apache
> APISIX
> > > in
> > > > > > > docker?
> > > > > > > > >
> > > > > > > > > Thanks,
> > > > > > > > > Ming Wen, Apache APISIX & Apache SkyWalking
> > > > > > > > > Twitter: _WenMing
> > > > > > > > >
> > > > > > > > >
> > > > > > > > > Ming Wen <[email protected]> 于2020年8月17日周一 下午4:10写道:
> > > > > > > > >
> > > > > > > > > > > Then I found that the current APISIX docker image is
> not
> > > > > > convenient
> > > > > > > > to
> > > > > > > > > > use in github actions.
> > > > > > > > > > Why is it inconvenient? After understanding the reason,
> we
> > > can
> > > > > > > discuss
> > > > > > > > > how
> > > > > > > > > > to solve it.
> > > > > > > > > >
> > > > > > > > > > Thanks,
> > > > > > > > > > Ming Wen, Apache APISIX & Apache SkyWalking
> > > > > > > > > > Twitter: _WenMing
> > > > > > > > > >
> > > > > > > > > >
> > > > > > > > > > junxu chen <[email protected]> 于2020年8月17日周一
> 下午3:20写道:
> > > > > > > > > >
> > > > > > > > > >> Hi, all
> > > > > > > > > >>
> > > > > > > > > >> Recently I am working on a github action, this github
> > action
> > > > > > depends
> > > > > > > > on
> > > > > > > > > >> APISIX, I need to reference APISIX in my test cases.
> Then
> > I
> > > > > found
> > > > > > > that
> > > > > > > > > the
> > > > > > > > > >> current APISIX docker image is not convenient to use in
> > > github
> > > > > > > > actions.
> > > > > > > > > >>
> > > > > > > > > >> There are two ways to improve this problem:
> > > > > > > > > >> 1. APISIX supports specifying etcd host through
> > environment
> > > > > > > variables
> > > > > > > > > >> 2. Build a new docker image that integrates etcd and
> > APISIX
> > > > > > > > > >>
> > > > > > > > > >> I prefer the second way, which is more convenient for
> > users
> > > to
> > > > > > test
> > > > > > > > > APISIX
> > > > > > > > > >> using docker without installing docker-compose.
> > > > > > > > > >>
> > > > > > > > > >> What do you think?
> > > > > > > > > >>
> > > > > > > > > >> Or there is a way that use APISIX in github actions
> > directly
> > > > > > without
> > > > > > > > > >> changing, please tell me.
> > > > > > > > > >>
> > > > > > > > > >> Thank you!
> > > > > > > > > >>
> > > > > > > > > >
> > > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > >
> > > >
> > > > --
> > > >
> > > > *MembPhis*
> > > > My GitHub: https://github.com/membphis
> > > > Apache APISIX: https://github.com/apache/incubator-apisix
> > > >
> > >
> >
>

Reply via email to