devcontainers / devcontainers/cli

Support updating lifecycle scripts on existing containers

未关闭
#821 2 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
feature-request
主要语言
TypeScript
星标
3k
派生
457
平均合并
13 小时 17 分钟
30 天内合并 PR
6

描述

Because the container configuration is cached in the container labels after creation, any changes to the local config file are ignored for future operations on the container.

In the case of the lifecycle scripts (`onCreateCommand`, `postCreateCommand`, ...) it would be useful in cases of pooling container if changes to the config would be honored so that the container doesn't need to be recreated.

For example, if a container is created with an empty configuration for a pool, then we should be able to later change the configuration to and re-apply the post-creation lifecycle logic against the existing container.

```json
{
"postCreateCommand": "touch foo"
}
```

It would also be useful if the cli could detect the case of a configuration collision and fail with a reasonable message. For example, if the container is created with a `postCreateCommand` already and then the value is changed, then this re-application logic should fail.

贡献指南

打开贡献指南

调研方向

首先跟踪 CLI 如何读取缓存的容器标签,并在对现有容器执行操作期间应用生命周期脚本。验证向现有容器添加脚本以及更改现有脚本时的行为;兼容的更改能够在不重新创建容器的情况下重新应用,并且冲突会以清晰的消息失败,即表示完成。

由索引模型根据 Issue 内容生成。

评估

技术栈
typescript
领域
cli, devops
Issue 类型
功能
难度
4/5
预计耗时
3-5 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
38/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。