Where should I keep profile script to be accessed by other admins

Welcome Forums General PowerShell Q&A Where should I keep profile script to be accessed by other admins

Viewing 4 reply threads
  • Author
    Posts
    • #255599
      Participant
      Topics: 41
      Replies: 94
      Points: 560
      Rank: Major Contributor

      Hi ALl,
      I’ve been reading that we have 6 different profile possibilities
      Current user current host console
      Current user all hosts
      all users Current host console
      all users all hosts
      current user current host  ISE
      All users current host ISE

      I’ve a AD mgmt server where multiple admins login to work on user accounts ect.
      I’m owner of a powershell script that takes care of the offboarding part of a given user.
      how can I use an powershell profile so that all different admins work with the same profile that I’m using?
      or do I simply initiate at the start of the script to load the profile that I’ve created for this specific purpose? and which one of the above profile possibilities do I use to accomplish that.
      I think at least that the profile should be saved somewhere in the public folder so that it’s accessible for everyone?
      thanks for your ideas on this matter

       

      Paul

      • This topic was modified 2 weeks, 1 day ago by kvprasoon. Reason: change title
    • #255794
      Participant
      Topics: 41
      Replies: 94
      Points: 560
      Rank: Major Contributor

      all users current host does this mean that this profile is being used by either the console or ISE or is that going to be that all users on that machine work with the same profile?

      • This reply was modified 2 weeks, 1 day ago by acer460527.
    • #255956
      Senior Moderator
      Topics: 9
      Replies: 1311
      Points: 4,794
      Helping Hand
      Rank: Community Hero

      Having profile script in a remote location effects performance and is error prone. Why would you want all admins to use same profile and what is in your profile script, if you can share it will be good for folks to understand the use case a lil bit more.

    • #256052
      Participant
      Topics: 41
      Replies: 94
      Points: 560
      Rank: Major Contributor

      kvprasoon,
      at this moment it’s just exploring to see if this would be a solution.
      currently I have a powershell script that is taking care of the complete offboarding procedure, in order to make it work for every admin they need to install for example the azureAd module, but if there are 5 admins assigned to this region I currently would need to install it seperately for each admin which is time consuming to get it all setup.
      My goal is to install everything  in such a way on the mgmt-server that it’s being accessible for each admin on their user profile.
      that’s also the reason that I store my powershell and csv files  in the public document folder so the script will copy the required files from there to the given location under the users profile.

      Paul

       

    • #256409
      Participant
      Topics: 25
      Replies: 186
      Points: 664
      Helping Hand
      Rank: Major Contributor

      If its only modules you’re worried about, just logon to your host server and install the azuread module as a local admin, it should then be available for all users that subsequently login to the machine.

      Secondly I would just do a simple check for the required modules at the beginning of the script. Something like:

      • This reply was modified 1 week, 5 days ago by David Schmidtberger.
      • This reply was modified 1 week, 5 days ago by grokkit. Reason: code formatting
Viewing 4 reply threads
  • You must be logged in to reply to this topic.