Is it possible to run ESP(Extensible Service Proxy) on localhost to simulate authentication locally?

189 views
Skip to first unread message

Fouad Almalki

unread,
Dec 6, 2016, 6:39:35 AM12/6/16
to Google Cloud Endpoints
I need to run ESP (Extensible Service Proxy) on localhost to simulate authentication locally. Is it supported yet? Maybe I can run a docker container? However, I need ESP app to deploy it on the container.

Wencheng Lu

unread,
Dec 6, 2016, 3:54:58 PM12/6/16
to Fouad Almalki, Wayne Zhang, Google Cloud Endpoints
Hi, Fouad,

Yes, you can run ESP on localhost to do auth check. 

+wayne who can provide you a drafted version of running ESP in localhost. We are polishing this doc and will make it public soon.

Wencheng

On Tue, Dec 6, 2016 at 3:39 AM, Fouad Almalki <engineer...@gmail.com> wrote:
I need to run ESP (Extensible Service Proxy) on localhost to simulate authentication locally. Is it supported yet? Maybe I can run a docker container? However, I need ESP app to deploy it on the container.

--
You received this message because you are subscribed to the Google Groups "Google Cloud Endpoints" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-endpoints+unsub...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-cloud-endpoints/a5533e2a-39c4-4817-9c48-0a86d84dffca%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Wayne Zhang

unread,
Dec 6, 2016, 4:37:55 PM12/6/16
to Wencheng Lu, Fouad Almalki, Google Cloud Endpoints

On Tue, Dec 6, 2016 at 12:54 PM, Wencheng Lu <w...@google.com> wrote:
Hi, Fouad,

Yes, you can run ESP on localhost to do auth check. 

+wayne who can provide you a drafted version of running ESP in localhost. We are polishing this doc and will make it public soon.

Wencheng
On Tue, Dec 6, 2016 at 3:39 AM, Fouad Almalki <engineer...@gmail.com> wrote:
I need to run ESP (Extensible Service Proxy) on localhost to simulate authentication locally. Is it supported yet? Maybe I can run a docker container? However, I need ESP app to deploy it on the container.

--
You received this message because you are subscribed to the Google Groups "Google Cloud Endpoints" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-endpoints+unsubscri...@googlegroups.com.

Fouad Almalki

unread,
Dec 7, 2016, 1:16:00 AM12/7/16
to Google Cloud Endpoints, w...@google.com, engineer...@gmail.com, qiwz...@google.com
I cannot access that link, it requires "@google.com" account.


On Wednesday, December 7, 2016 at 12:37:55 AM UTC+3, Wayne Zhang wrote:
On Tue, Dec 6, 2016 at 12:54 PM, Wencheng Lu <w...@google.com> wrote:
Hi, Fouad,

Yes, you can run ESP on localhost to do auth check. 

+wayne who can provide you a drafted version of running ESP in localhost. We are polishing this doc and will make it public soon.

Wencheng
On Tue, Dec 6, 2016 at 3:39 AM, Fouad Almalki <engineer...@gmail.com> wrote:
I need to run ESP (Extensible Service Proxy) on localhost to simulate authentication locally. Is it supported yet? Maybe I can run a docker container? However, I need ESP app to deploy it on the container.

--
You received this message because you are subscribed to the Google Groups "Google Cloud Endpoints" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-cloud-endpoints+unsub...@googlegroups.com.

Fouad Almalki

unread,
Dec 8, 2016, 3:31:25 AM12/8/16
to Google Cloud Endpoints
1- I used docker for Windows https://docs.docker.com/docker-for-windows/
2- I created a folder at root path of drive C (C:/esp), then I copied serviceaccount.json to it. serviceaccount.json holds the private key of a service account with the following roles:

- Project -> Viewer
- Cloud Trace -> Cloud Trace Agent
- Service Management -> Service Controller

"ps: you would need to scroll down the menu to find the second and third roles :)"

3- Closed Kaspersky, otherwise --volume C:/esp:/esp doesn't work.
4- Enabled C Drive sharing via Docker settings GUI.
5- Executed the command:

docker run --detach --name="esp" --publish 8082:8082 --volume C:/esp:/esp b.gcr.io/endpoints/endpoints-runtime:1 --service ****-backend-api.****-test.appspot.com --version 2016-12-06r1 --backend 10.0.75.1:8080 --service_account_key /esp/serviceaccount.json --http_port 8082

where 10.0.75.1 is IP of docker NIC, and 8080 is which backend local server is listening to.
Reply all
Reply to author
Forward
0 new messages