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

Zia create new pac version #239

Closed

Conversation

CyberPaschk
Copy link

This code can generate a new PAC Version eq. like an update. In the UI it is mentioned as "Create new Branch".

Description

I added a new method to the "pac_files" class which can generate a new PAC Version. This will make it possible to do the Change via CLI instead of going to the UI and edit the PAC in the UI and create a new Branch etc.

Additionally it gives the customer the possibilities to push the change to different PAC Files without editing each one in the UI.
If he has test policies like initial, extended and productive he could do a change in the PAC Content and push it via CLI to the UI and test it.

Also it would be possible to push the change directly to initial and extended tests for a bigger testing group.

closes #238

Has your change been tested?

I tested the code already in the Zscalerbeta cloud and pushed some changes to the Cloud:
image

I was adding a comment via CLI:
// This is a Test via Zscaler SDK number | Now with verify PAC
and requested the User input for Commit:
commit_message = input("Enter the commit message: ")

In the UI I'm able to see the Commit Message and the Comment:
image

But you can test the method by your own too.

I tested the code with our Zscalerbeta cloud and configured a PAC File locally with some changes in the Code and pushed it with this steps:
Reading the File as paccontent
request user Input for Commit
request user Input for PAC file to deploy the paccontent
validate PAC via method
activate change

After this I took the PAC URL and downloaded the file once and checked the file I created and the downloaded one.

There is no impact to the current deployed code since this is a new method in the pac_file class.

Types of changes

Modify

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • [X ] My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing tests passed.
  • This change is using publicly documented and stable APIs.

This code can generate a new PAC Version eq. like an update.
In the UI it is mentioned as "Create new Branch".
Corrected with "TAB"
@willguibr
Copy link
Member

Please refer to our README here.
At this moment we are not accepting contributions, but we welcome suggestions on how to improve this SDK or feature requests, which can then be added in future releases.
Finally, we have a major upcoming release slated for the next 2-3 weeks which will include such feature.

Zscaler DevRel

@willguibr willguibr closed this Jan 10, 2025
@willguibr willguibr self-assigned this Jan 10, 2025
@willguibr willguibr added enhancement New feature or request wontfix This will not be worked on labels Jan 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request wontfix This will not be worked on
Projects
Status: ⚙️ In development
Development

Successfully merging this pull request may close these issues.

[FEATURE] Create new Pac Version
2 participants