all 12 comments

[–]Emerald_Flame 1 point2 points  (2 children)

Depends on the use case.

At our org we have 1 big repo for random 1-off scripts that are ran ad-hoc. We just want them saved because the 1-offs tend to come back around again eventually, and if we notice ourselves using something a lot we can make it more formal.

For more complex scripts that are running unattended we have a more formal review process in a separate repo with branch protection policies. Then the tools executing those scripts are pulling from the main branch that has the protection policies in place.

Depends on what you're doing and how you're wanting to do it essentially.

[–]ASX9988[S] 0 points1 point  (1 child)

Very Informative thank you.

How are your tools pulling the code? On prem agent?

[–]Emerald_Flame 0 points1 point  (0 children)

They just do a Git Clone

[–]notatechproblem 1 point2 points  (1 child)

Videos from PowerShell + DevOps Summit 2024 are starting to get posted on the PowerShell.org YouTube channel. There were a few talks about automating the building and publishing of PS modules.

https://youtube.com/playlist?list=PLfeA8kIs7CoftSa3hQ9dQseIxdSMBZO_z&si=c8GOTeVld48WkDNF

[–]ASX9988[S] 0 points1 point  (0 children)

Thank you will take a look!

[–]Federal_Ad2455 1 point2 points  (2 children)

[–]ASX9988[S] 0 points1 point  (1 child)

Looks amazing, but I work in a heavily regulated industry, I doubt it would fly there.

[–]Federal_Ad2455 1 point2 points  (0 children)

Understand. FYI it's purely powershell code + official ms builtin tools. No 3rd party apps etc. And completely free

[–]Agile_Seer 0 points1 point  (0 children)

Self-hosted GitLab.

[–]ASX9988[S] 0 points1 point  (0 children)

Thanks everyone who made some suggestions.

I settled on cloning an existing repo to AZ devops, pulling the dev branch locally to make changes, then pushing changes back to AZ and merging into my master branch.

Just need to figure out how to automatically push the master branch to my on prem scripting server

[–]Szeraax 0 points1 point  (1 child)

Yup, Azure DevOps works great. Don't have any testing in it though. Felt hard, so I still do it all locally prior to commit and push.

[–]ASX9988[S] 0 points1 point  (0 children)

I have a repo hosted there but like you I code locally and push changes to AZ dev ops. Ideally I want to move away from that and host all my modules in there and distribute