apisix-ingress-controller
apisix-ingress-controller copied to clipboard
Add new `make dev-env` entry in Makefile
We should add a new make dev-env
entry in Makefile, to start a dev environment.
It should do something:
- using kind create a new cluster
- Deploy APISIX + etcd
- Build apisix-ingress-controller’s image
- Deploy apisix-ingress-controller
Most of them are already contained in the current Makefile, we need to organize them
let me try
Hi, @Erhao , are you still working on this issue? I'm a new learner of apisix ingress controller. Maybe I can have a try on this.
thanks! Please!
Hi, @tao12345666333 , feel sorry to bother you, after I build ingress controller image and load it into kind cluster, I have no good way to deploy it, sincerely looking forward to your advice.
You can change manifests under sample/deploy
directory
Many thanks to you.
@CrazyCollin How is this work going ?
@tao12345666333 I tried this job and found something puzzle me.
First I tried the following script to create dev env,
dev-env: kind-up pack-image
kubectl create namespace ingress-apisix
helm repo add apisix https://charts.apiseven.com
helm repo update
helm install apisix apisix/apisix --namespace ingress-apisix
CA_BUNDLE=kubectl config view --raw --flatten -o json | jq -r '.clusters[] | select(.name == "'$(kubectl config current-context)'") | .cluster."certificate-authority-data"'
kubectl kustomize $(PWD)/samples/deploy | sed "s|\${CA_BUNDLE}|${CA_BUNDLE}|g" | kubectl apply -f -
kubectl set image deployment/ingress-controller ingress-controller=localhost:5001/apache/apisix-ingress-controller:dev
the step is:
running kind-up to strat cluster and k8s -> build image and deploy to local registry -> deploy apisix to k8s with helm -> deploy ingress controller with local directory samples/deployment
.
but this didn't work, ingress controller cannot visit apisix properly, there are 2 causes.
-
apisix did not allow admin visit from other endpoint excepting 127.0.0.1
-
proxy_stream is not configured
according to apisix helm chart, I need to set ingress-controller.enable=true
when helm install
, but if so, an ingress controller deployment will be deploy also, this is not expected.
And now I have another idea: deploying apisix and apisix-ingress-controller, and then replace the image with localhost:5001/apache/apisix-ingress-controller:dev
, the script may be
dev-env: kind-up pack-image
kubectl create namespace ingress-apisix
helm repo add apisix https://charts.apiseven.com
helm repo update
helm install apisix apisix/apisix \
--set gateway.type=NodePort \
--set ingress-controller.enabled=true \
--namespace ingress-apisix
kubectl set image deployment/apisix-ingress-controller apisix-ingress-controller=localhost:5001/apache/apisix-ingress-controller:dev
Could you please give me some advice?
Hi @zou8944 , sorry for my work and delayed response as I have a lot going on these days so. My initial idea was to use Helm to deploy apisix and etcd, then load the built ingress image into kind, after many attempts, the apisix instance still can't respond to ingress requests, it may be the same problem as yours. I think maybe my configuration file in samples/deployment is not set correctly. I will unassign myself right away, sorry again.
@zou8944 sorry for delay, I miss your message.
I think its SGTM.
Using Helm to deploy APISIX + APISIX Ingress controller, then replace apisix-ingress-controller's image.
OK, thanks. then this is PR https://github.com/apache/apisix-ingress-controller/pull/1460
I wish to work on this issue.
@tao12345666333 are you working on this?