Skip to content

Recreate lockfile with upgrade command - #645

Merged
joshspicer merged 4 commits into
mainfrom
joshspicer/regenerate-lockfile
Sep 29, 2023
Merged

joshspicer merged 4 commits into
mainfrom
joshspicer/regenerate-lockfile

Conversation

@joshspicer

@joshspicer joshspicer commented Sep 25, 2023 •

Copy link
Copy Markdown
Contributor

Provides a way to programmatically regenerate the dev container lockfile without building the dev container or deleting the lockfile. This may be useful in CI scenarios where you'd like to programmatically upgrade a lockfile, and then build an image based on it.

Usage

$ devcontainer upgrade \
       --workspace-folder /workspaces/project
[4 ms] @devcontainers/cli 0.51.3. Node.js v16.20.0. linux 5.15.0-1041-azure x64.
Upgrading lockfile...

$ cat /workspaces/project/.devcontainer-lock.json
{
  "features": {
    "ghcr.io/codspace/features/color:1.0.4": {
      "version": "1.0.4",
      "resolved": "ghcr.io/codspace/features/color@sha256:6e9d07c7f488fabc981e7508d8c25eea4b102ebe4b87f9fc6f233efa1d325908",
      "integrity": "sha256:6e9d07c7f488fabc981e7508d8c25eea4b102ebe4b87f9fc6f233efa1d325908"
    },
...
}
@joshspicer
joshspicer requested a review from a team as a code owner September 25, 2023 21:49
@joshspicer joshspicer changed the title Recreate features entry of lockfile with features upgrade command Sep 25, 2023
Comment thread src/spec-node/devContainersSpecCLI.ts Resolved
Comment thread src/spec-node/featuresCLI/upgrade.ts Resolved
@joshspicer joshspicer changed the title Recreate lockfile with features upgrade command Sep 26, 2023

@chrmarti Christof Marti (chrmarti) left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants