Skip to content

fix: remove Docker container lifecycle management (dead code since 2016)#31

Merged
viniciusferrao merged 1 commit into
masterfrom
fix/remove-docker-lifecycle
May 4, 2026
Merged

fix: remove Docker container lifecycle management (dead code since 2016)#31
viniciusferrao merged 1 commit into
masterfrom
fix/remove-docker-lifecycle

Conversation

@viniciusferrao

Copy link
Copy Markdown
Member

Summary

Remove Docker container lifecycle management (mgt=docker, mkdocker, rmdocker, lsdocker) from xCAT.

This was added in 2015-2016 as an experiment targeting Docker API v1.22 on Ubuntu only. Documentation and man pages were deliberately removed in 2019 (PRs xcat2#6222 and xcat2#6324) with the original developer's approval. The plugin has had no functional code changes since April 2016, was never listed as a valid mgt value in Schema.pm, and no user has ever filed an issue about it.

Changes

  • Delete xCAT-server/lib/xcat/plugins/docker.pm (1,142 lines)
  • Delete xCAT/postscripts/setupdockerhost
  • Delete xCAT-server/share/xcat/scripts/setup-dockerhost-cert.sh
  • Delete Docker test cases and bundle entries
  • Remove Docker attribute definitions from Schema.pm
  • Remove Docker host cert generation from xcatconfig
  • Remove client symlinks (mkdocker, rmdocker, lsdocker) from RPM spec and debian links
  • Remove Docker usage entries from Usage.pm and AAAusage.pm
  • Remove Docker credential handling from credentials.pm
  • Remove Docker regression path from xCATreg
  • Clean Docker attributes from man7 generated docs

The "Running xCAT in Docker" documentation (dockerized_xcat/) is retained — it documents containerizing xCAT itself, not the removed mgt=docker feature.

Test plan

  • perl -c perl-xCAT/xCAT/Schema.pm passes
  • Zero remaining references to mkdocker/rmdocker/lsdocker/setupdockerhost/xcatdockerca/mgt=docker
  • No sensitive strings in diff
  • Adversarial review converged (4 passes)

Closes xcat2#7518

Docker container lifecycle management (mgt=docker, mkdocker, rmdocker,
lsdocker) was added in 2015-2016 as an experiment targeting Docker API
v1.22 on Ubuntu only. Documentation and man pages were deliberately
removed in 2019 (PRs xcat2#6222 and xcat2#6324) with the original developer's
approval, noting that "the interface of Docker has become very simple
right now, so there is no value for xCAT to offer such functions."

The plugin was still being shipped but has had no functional code changes
since April 2016, was never listed as a valid mgt value in Schema.pm,
and no user ever filed an issue about it.

Removed:
- xCAT-server/lib/xcat/plugins/docker.pm (1,142 lines)
- xCAT/postscripts/setupdockerhost
- xCAT-server/share/xcat/scripts/setup-dockerhost-cert.sh
- xCAT-test/autotest/testcase/dockercommand/ (test cases)
- Docker attribute definitions in Schema.pm
- Client symlinks (mkdocker, rmdocker, lsdocker)
- Usage entries and dockerhost cert handling in credentials.pm
- Docker attribute documentation in man7 pages

The "Running xCAT in Docker" documentation (dockerized_xcat/) is
retained as it documents containerizing xCAT itself, not the removed
mgt=docker feature.

Closes xcat2#7518
@viniciusferrao

Copy link
Copy Markdown
Member Author

Live Validation on cloyster (RHEL 8, xCAT 2.17.0)

Verified on the lab management node that removing Docker lifecycle code has no impact on existing functionality.

Environment

  • xCAT 2.17.0 on RHEL 8 (x86_64)
  • POWER9 AC922 managed via OpenBMC

Results

No Docker nodes exist in the cluster:

# tabdump vm
#node,mgr,host,... (empty - header only)

# lsdef -t node -w mgt==docker
No object definitions have been found

Docker attributes are already guarded — cannot be set without mgt=docker:

# chdef -t node power9bmc dockerhost=test
Error: Cannot set the attr='dockerhost' attribute unless mgt value is docker.

VM/BMC commands unaffected:

# rpower power9bmc stat
power9bmc: on

# rinv power9bmc firm
power9bmc: BMC Firmware Product: op940.90-4-0-gbebb0d890a (Active)*
power9bmc: HOST Firmware Product: IBM-witherspoon-ibm-OP9-v2.4.1-4.67-prod (Active)*

# lsdef power9bmc -i mgt,bmc,groups
Object name: power9bmc
    bmc=10.20.0.56
    groups=all
    mgt=openbmc

Existing Docker artifacts on 2.17.0 (to be removed on upgrade):

# ls /opt/xcat/lib/perl/xCAT_plugin/docker.pm     # exists (1142 lines, unused)
# ls /opt/xcat/share/xcat/scripts/setup-dockerhost-cert.sh  # exists (unused)
# ls /etc/xcatdockerca/cert/                        # exists (generated by xcatconfig, never used)

Patched xcatconfig diff confirmed: Docker cert generation block cleanly removed, adjacent setup-server-cert.sh logic untouched.

Conclusion

Zero Docker-managed nodes in production. Schema guard (only_if => 'mgt=docker') means removal of aliases is invisible to all existing node definitions. VM table is empty. All BMC/power/inventory commands work normally.

@viniciusferrao viniciusferrao merged commit 2bdb0d4 into master May 4, 2026
1 check passed
@viniciusferrao viniciusferrao deleted the fix/remove-docker-lifecycle branch May 7, 2026 03:20
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.

Remove Docker container lifecycle management (dead code since 2016)

1 participant