Reputation: 67
I have successfully deployed ESPv2 on CloudRun.
Since ESPv2 is based on Envoy, I was wondering if there a way to deploy ESPv2 locally on my machine.
Thanks
Upvotes: 1
Views: 462
Reputation: 4126
Yes you can. There's a documentation that tells you how to run ESP locally or on another platform such as AWS or on a Kubernetes cluster that's not running on Google Cloud. I highly recommend that you study it first but I will try summarize it.
The guide is also applicable for ESPv2.
Take note that Windows is not yet supported and there are a few prerequisites before you can run the ESPv2 container on your machine:
You also need to provide a service account JSON file with the following roles:
because ESPv2 uses the service account details to generate access tokens to call the services to manage your API.
Sample command to run using Docker on Linux:
sudo docker run \
--detach \
--name="esp" \
--net="host" \
--volume=$HOME/Downloads:/esp \
--publish=8082 \
gcr.io/endpoints-release/endpoints-runtime:1 \
--service=YOUR_SERVICE_NAME \
--rollout_strategy=managed \
--http_port=8082 \
--backend=localhost:8080 \
--service_account_key=/esp/service-account-creds.json
Upvotes: 1