-
Notifications
You must be signed in to change notification settings - Fork 74
Add Docker update functionality with configuration preservation to install-docker-ce.ps1 #599
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
base: Main
Are you sure you want to change the base?
Conversation
Co-authored-by: ntrappe-msft <124631722+ntrappe-msft@users.noreply.github.com>
Co-authored-by: ntrappe-msft <124631722+ntrappe-msft@users.noreply.github.com>
|
This issue has been open for 30 days with no updates. |
4 similar comments
|
This issue has been open for 30 days with no updates. |
|
This issue has been open for 30 days with no updates. |
|
This issue has been open for 30 days with no updates. |
|
This issue has been open for 30 days with no updates. |
|
This issue has been open for 30 days with no updates. |
1 similar comment
|
This issue has been open for 30 days with no updates. |
This PR enhances the
install-docker-ce.ps1script to support updating existing Docker installations while preserving thedaemon.jsonconfiguration file, eliminating the need for manual backup/restore steps.Problem
Previously, updating Docker required a complex 7-step manual process:
C:\ProgramData\docker\config\daemon.jsonThe script would either skip installation entirely if Docker was already installed, or perform a clean install that overwrote existing configuration.
Solution
Added a new
-Updateswitch parameter that automates the entire update process:Key Features
Automated Update Process:
daemon.jsonconfigurationRobust Error Handling:
Backwards Compatibility:
Technical Implementation
Backup-DockerConfig()andRestore-DockerConfig()with validationInstall-ContainerHost()andInstall-Docker()to handle update scenariosTesting
The implementation includes comprehensive error handling for edge cases:
Fixes #595.
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.