-
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
StartAutomating
authored and
StartAutomating
committed
Apr 20, 2024
1 parent
c8161cd
commit 98138d6
Showing
1 changed file
with
27 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
# Thank you Microsoft! This is a great way to get a PowerShell environment up and running quickly. | ||
FROM mcr.microsoft.com/powershell | ||
# Set the module name to the name of the module we are building | ||
ARG ModuleName=Posh | ||
# Copy the module into the container | ||
COPY . ./usr/local/share/powershell/Modules/$ModuleName | ||
|
||
# Create a profile that imports the module, so it is available when the container starts. | ||
RUN pwsh -c "New-Item -Path \$Profile -ItemType File -Force" | ||
RUN pwsh -c "Add-Content -Path \$Profile -Value 'Import-Module $ModuleName' -Force" | ||
|
||
# For This Module Only, we install all of the recommended modules. | ||
# and add them to the profile so they are available when the container starts. | ||
|
||
|
||
RUN pwsh -c "Install-Module -Name 'EZOut' -Force -AllowClobber -Scope CurrentUser -PassThru" | ||
RUN pwsh -c "Add-Content -Path \$Profile -Value 'Import-Module EZOut' -Force }" | ||
RUN pwsh -c "Install-Module -Name 'PipeScript' -Force -AllowClobber -Scope CurrentUser -PassThru" | ||
RUN pwsh -c "Add-Content -Path \$Profile -Value 'Import-Module PipeScript' -Force }" | ||
RUN pwsh -c "Install-Module -Name 'HelpOut' -Force -AllowClobber -Scope CurrentUser -PassThru" | ||
RUN pwsh -c "Add-Content -Path \$Profile -Value 'Import-Module HelpOut' -Force }" | ||
RUN pwsh -c "Install-Module -Name 'PSSVG' -Force -AllowClobber -Scope CurrentUser -PassThru" | ||
RUN pwsh -c "Add-Content -Path \$Profile -Value 'Import-Module PSSVG' -Force }" | ||
RUN pwsh -c "Install-Module -Name 'Splatter' -Force -AllowClobber -Scope CurrentUser -PassThru" | ||
RUN pwsh -c "Add-Content -Path \$Profile -Value 'Import-Module Splatter' -Force }" | ||
RUN pwsh -c "Install-Module -Name 'ShowDemo' -Force -AllowClobber -Scope CurrentUser -PassThru" | ||
RUN pwsh -c "Add-Content -Path \$Profile -Value 'Import-Module ShowDemo' -Force }" |