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
Add devcontainer.json
manager to Renovate
#12116
Comments
Hi there, You're requesting support for a new package manager. We need to know some basic information about this package manager first. Please copy/paste the new package manager questionnaire, and fill it out in full. Once the questionnaire is filled out we will evaluate if adding support for this manager is something we want to do. Good luck, The Renovate team |
Click me to see filled out questionnaireNew package manager questionnaireDid you read our documentation on adding a package manager?
BasicsName of package manager
What language does this support?
How popular is this package manager?GitHub Codespaces supports the Does this language have other (competing?) package managers?
Package File DetectionWhat type of package files and names does it use?
What fileMatch pattern(s) should be used?
Is it likely that many users would need to extend this pattern for custom file names?
I don't expect people will use different filenames/locations for their devcontainer file as that will not conform to the spec and likely not even work properly with Codespaces or VSCode... 😄 Is the fileMatch pattern likely to get many "false hits" for files that have nothing to do with package management?I don't think we'll get false hits. Parsing and ExtractionCan package files have "local" links to each other that need to be resolved?
You can link to a Dockerfile from within a {
"build": { "dockerfile": "Dockerfile" },
"extensions": ["dbaeumer.vscode-eslint"],
"forwardPorts": [3000]
} The idea is that your Devcontainer file gathers all requirements in a single place, like the Is there a reason why package files need to be parsed together (in serial) instead of independently?No clue what this means. What format/syntax is the package file in?
How do you suggest parsing the file?
I guess we can find the correct files by writing a bit of regex. Does the package file structure distinguish between different "types" of dependencies? e.g. production dependencies, dev dependencies, etc?
List all the sources/syntaxes of dependencies that can be extractedI think theses are the images, Dockerfiles or Docker Compose files that you can put in the devcontainer file:
Describe which types of dependencies above are supported and which will be implemented in futureI think these are all supported already by GitHub Codespaces:
VersioningWhat versioning scheme does the package file(s) use?It depends on what image, Dockerfile or Docker Compose file(s) you link to what versioning scheme is used. Does this versioning scheme support range constraints, e.g.
|
Property | Type | Description |
---|---|---|
Dockerfile or image | ||
image |
string | Required when using an image. The name of an image in a container registry (DockerHub, GitHub Container Registry, Azure Container Registry) that VS Code should use to create the dev container. |
Do the package files contain any "constraints" on the parent language (e.g. supports only v3.x of Python) or platform (Linux, Windows, etc) that should be used in the lookup procedure?
No idea.
Will users need the ability to configure language or other constraints using Renovate config?
No idea.
Artifacts
Are lock files or checksum files used? Are they mandatory?
No lock files or checksum files used.
If so, what tool and exact commands should be used if updating one or more package versions in a dependency file?
If applicable, describe how the tool maintains a cache and if it can be controlled via CLI or env? Do you recommend the cache be kept or disabled/ignored?
If applicable, what command should be used to generate a lock file from scratch if you already have a package file? This will be used for "lock file maintenance"
Other
Is there anything else to know about this package manager?
I found a full reference for the devcontainer.json
file. 3
Footnotes
In addition to the "features": {
"ghcr.io/user/repo/go": {},
"ghcr.io/user/repo1/go:1": {},
"ghcr.io/user/repo2/go:latest": {},
"https://github.com/user/repo/releases/devcontainer-feature-go.tgz": {
"optionA": "value"
},
"./myGoFeature": {
"optionA": true,
"optionB": "hello",
"version" : "1.0.0"
}
} |
The features are also versioned. vscode provides an extension which identifies outdated feature versions and provides the ability to populate the latest version. I've noticed that when editing the devcontainer.json file. |
following #25338 (reply in thread), we could probably leverage the regex manager to update the image within devcontainer files by tweaking its presets in https://github.com/renovatebot/renovate/blob/main/lib/config/presets/internal/regex-managers.ts maybe adding the following will due devcontainerVersions: {
customManagers: [
{
customType: 'regex',
fileMatch: [
'\^.devcontainer/devcontainer.json$',
'^.devcontainer.json$',
],
matchStrings: [
'\\s*"image":\\s"(?<registryUrls>.*?)\\/(?<depName>.*?):(?<currentValue>.*?)(@(?<currentDigest>sha256:[a-f0-9]+))?"',
],
},
],
description: 'Update image version in devcontainer files.',
}, sorry for posting rather than contributing directly by a pr. |
JFYI,
|
🎉 This issue has been resolved in version 37.322.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
What would you like Renovate to be able to do?
Opening a issue for this idea, so that it doesn't get lost in the discussion forum. 😉
Quote from @rarkins 1
If you have any ideas on how this should be implemented, please tell us here.
Nope, I'll let the code-wizards figure it out. 😉
Is this a feature you are interested in implementing yourself?
No
Footnotes
https://github.com/renovatebot/renovate/discussions/12114#discussioncomment-1458593 ↩
The text was updated successfully, but these errors were encountered: