-
Notifications
You must be signed in to change notification settings - Fork 309
devcontainer features
: Dependency Management
#16
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
Comments
features
: Dependency Management
As a start, I propose we implement a mechanism to define dependencies between features within the same 'feature set'. We would introduce a features : [
{
"id": "jupyter-labs",
"name": "Jupyter Labs",
"entrypoint": "/usr/local/share/labs-init.sh",
"dependsOn": [
"python"
]
// ...
},
{
"id": "python",
"name": "Python 3",
"dependsOn": [ ]
// ...
},
] To actually enforce the order, we may want to copy what vscode-dev-containers does, and actively write the file in such a way that we can enforce order. We then have a default
As @chrmarti pointed out, In the future, we could allow a feature to depend on a feature from another collection by the first collection including a versioned link to the second collection. That would again leave the first collection in control and might have security advantages (e.g., we could add a checksum to the link). |
Closing this out since I think this has been factored into the current dev container features proposal. |
How do we handle an inevitable dependency graph for features that depend on other features.
Currently we have no deterministic way to install dev container ‘features’, nor do we have any mechanism to indicate dependencies.
The Codespaces team has been looking to author more features and hope to swap over our primary definition to be a composition of ‘features’. Recently we’ve run into instances where it was a problem that feature installation order couldn’t be defined.
Example: Installing two features, where the installation of A depends on installation of B (JupyterLabs cannot be installed without a particular version of python present).
It is important to explore how such dependency relationships are handled moving forward. Since it’s a complicated problem, this may even lead us to wanted to investigate pivoting a bit, utilizing an existing package manager like
npm
to create the directed dependency graph for us?The concept of ‘remote features’ is quite different than the idea of packaging of a single set of features, so I want to discuss this further so we have some plan moving forward.
Perhaps someone tangential, but we'll also want this dependency graph to permit multiple "editions" of a feature to be installed:
Example: In the Codespaces base image, we'll want to install node 14 and node 16. How do we specify "installing a feature twice", which one ends up on the $PATH, etc...
The text was updated successfully, but these errors were encountered: