Skip to content

containerd,nerdctl: preserve config files + add init script#29487

Open
dzavy wants to merge 2 commits into
openwrt:masterfrom
dzavy:containerd_nerdctl_sysconfig
Open

containerd,nerdctl: preserve config files + add init script#29487
dzavy wants to merge 2 commits into
openwrt:masterfrom
dzavy:containerd_nerdctl_sysconfig

Conversation

@dzavy
Copy link
Copy Markdown
Contributor

@dzavy dzavy commented May 19, 2026

📦 Package Details

Maintainer: @lu-zero

Description:
Preserve config files during sysupgrade + add init script for containerd


🧪 Run Testing Details

  • OpenWrt Version: 25.12.0
  • OpenWrt Target/Subtarget: mvebu/cortexa72
  • OpenWrt Device: Globalscale MOCHAbin

✅ Formalities

  • I have reviewed the CONTRIBUTING.md file for detailed contributing guidelines.

dzavy added 2 commits May 18, 2026 14:32
also add init script

Signed-off-by: Jan Havelka <dzavy@dzavy.net>
preserve config file during sysupgrade

Signed-off-by: Jan Havelka <dzavy@dzavy.net>
Comment thread utils/containerd/Makefile
Comment on lines +71 to +72
$(INSTALL_DIR) $(1)/etc/init.d
$(INSTALL_BIN) ./files/containerd.init $(1)/etc/init.d/containerd
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Could you please separate adding init file to its own commit, pleaase? It would be better for cherry-picking.

@BKPepe BKPepe requested a review from Copilot May 19, 2026 12:59
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Note

Copilot was unable to run its full agentic suite in this review.

Preserves user configuration files during sysupgrade for both containerd and nerdctl packages, and adds a procd init script for containerd.

Changes:

  • Add conffiles definition to containerd and nerdctl Makefiles to preserve config files
  • Add a new procd init script for containerd
  • Bump PKG_RELEASE for both packages

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.

File Description
utils/nerdctl/Makefile Bumps PKG_RELEASE and declares /etc/nerdctl/nerdctl.toml as conffile
utils/containerd/Makefile Bumps PKG_RELEASE, declares config.toml as conffile, installs new init script
utils/containerd/files/containerd.init New procd init script for containerd

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread utils/containerd/Makefile
@@ -64,6 +68,8 @@ Build/Compile=$(call Build/Compile/Default)
define Package/containerd/install
$(INSTALL_DIR) $(1)/usr/bin/
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/bin/{ctr,containerd,containerd-stress,containerd-shim-runc-v2} $(1)/usr/bin/
start_service() {
procd_open_instance
procd_set_param respawn
procd_set_param command $CONTAINERD_BIN
Comment thread utils/nerdctl/Makefile
Comment on lines +38 to +41
define Package/nerdctl/conffiles
/etc/nerdctl/nerdctl.toml
endef

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Yes this is intentional. nerdctl.toml is not required, nerdctl would use defaults, however if it's overriden by user (especially to set data_root to persistent storage) it should be preserved during sysupgrade.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants