Set an IP restriction on service account


Set an IP restriction on service account



At first, I'm using service account with delegated credentials executing Apps Script API to run a function on Google Apps Script from a Python script via Google's Python client library, and it just works fine.



I'd like to add some IP restriction for it, to make sure it can only execute by the specific IP.



I have tried to add a firewall rule in VPC, which deny all ingress from 0.0.0.0/0 and set the target to the service account. However, running the script after setting the vpc rule is no different than before it.
The firewall rule seems to only target the VM instance used by the service account.



Is there any better way to set IP restriction for service account?





I'm just trying to understand your question... Are you trying to execute a Google Apps script via the Google API client for python? Using this API? developers.google.com/apps-script/api/reference/rest
– ScottMcC
Jul 3 at 9:33






Sorry about my poor English.. Yes, I 'm trying to execute Google Apps script via Google API client for python an using Apps Script API "run". Like the complete example code at the bottom of this link. developers.google.com/api-client-library/python/auth/…
– rueyjye
Jul 3 at 9:58










By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Popular posts from this blog

api-platform.com Unable to generate an IRI for the item of type

How to set up datasource with Spring for HikariCP?

Display dokan vendor name on Woocommerce single product pages