Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Project factory doesnt support Allow all for org constraint policies at project level #893

Closed
nagendrasidgs opened this issue Oct 17, 2022 · 3 comments · Fixed by #930
Closed

Comments

@nagendrasidgs
Copy link

We have a use case to Allow 'All' for a constraint(constraints/compute.restrictVpcPeering) at the Project level. At the same time, we deny that at the 'org' level.

Now the issue is in the Fast as it is using the project factory and the project factory does not provide an option to pass 'All' as 'true' or 'deny'. It only does 'values'. Are there options that we leverage to perform the above?

@nagendrasidgs
Copy link
Author

nagendrasidgs commented Oct 17, 2022

Was able to get through. Basically, we need to pass an empty value: that would auto-pick the all: true at the project level.

Maybe adding an example to restrict something at org and how to allow 'all' at the project level. Would help!

An example: the below will set Allow 'All'. This will come in handy when you do private service connect at the project level for private GKE; Apigee; private SQL.

constraints/compute.restrictVpcPeering:
  inherit_from_parent: null
  status: true
  suggested_value: null
  values:

@nagendrasidgs
Copy link
Author

Closing this Issue as its resolved

@ludoo
Copy link
Collaborator

ludoo commented Oct 17, 2022

Was able to get through. Basically, we need to pass an empty value: that would auto-pick the all: true at the project level.

Maybe adding an example to restrict something at org and how to allow 'all' at the project level. Would help!

Yes, I always struggle with org policies, and often reverse engineer what I apply in the console via plan to figure out the syntax. An example would be very useful, would you be ok with adding the one you found to the relevant README, in a PR?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants