Skip to content

Commit cd41353

Browse files
authored
Merge pull request #3559 from dtrudg/drop-conmon
deps: drop conmon submodule
2 parents cd4e2b3 + 2ba2dfc commit cd41353

17 files changed

+52
-341
lines changed

.circleci/config.yml

+5-1
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,6 @@ commands:
9797
fuse-overlayfs \
9898
git \
9999
libfuse-dev \
100-
libglib2.0-dev \
101100
libseccomp-dev \
102101
libsubid-dev \
103102
libtool \
@@ -116,6 +115,11 @@ commands:
116115
command: |-
117116
<<# parameters.sudo >>sudo <</ parameters.sudo >>curl -L -o /usr/local/bin/crun https://github.com/containers/crun/releases/download/1.14.4/crun-1.14.4-linux-amd64
118117
<<# parameters.sudo >>sudo <</ parameters.sudo >>chmod +x /usr/local/bin/crun
118+
- run:
119+
name: Install conmon
120+
command: |-
121+
<<# parameters.sudo >>sudo <</ parameters.sudo >>curl -L -o /usr/local/bin/conmon https://github.com/containers/conmon/releases/download/v2.1.13/conmon.amd64
122+
<<# parameters.sudo >>sudo <</ parameters.sudo >>chmod +x /usr/local/bin/conmon
119123
120124
cgroups-delegation:
121125
steps:

.gitmodules

-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
[submodule "third_party/conmon"]
2-
path = third_party/conmon
3-
url = https://github.com/containers/conmon
41
[submodule "third_party/squashfuse"]
52
path = third_party/squashfuse
63
url = https://github.com/vasi/squashfuse

CHANGELOG.md

+5
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,11 @@
6666
which have been untested / unsupported for some time.
6767
- Make binary builds more reproducible by deriving the GNU build ID
6868
from the Go build ID instead of using a randomly generated one.
69+
- Conmon sources are no longer bundled and built with SingularityCE. Install the
70+
`conmon` package from your distribution, or [upstream
71+
binary](https://github.com/containers/conmon/releases), if you need to use the
72+
`singularity oci` commands. Note that `conmon` is not required for `--oci`
73+
mode.
6974

7075
### Removed Features
7176

INSTALL.md

+35-3
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ sudo apt-get install -y \
2424
git \
2525
fuse \
2626
libfuse-dev \
27-
libglib2.0-dev \
2827
libseccomp-dev \
2928
libtool \
3029
pkg-config \
@@ -67,7 +66,6 @@ sudo dnf --enablerepo=devel install -y \
6766
fuse3 \
6867
fuse3-devel \
6968
git \
70-
glib2-devel \
7169
libseccomp-devel \
7270
libtool \
7371
shadow-utils-subid-devel \
@@ -76,7 +74,7 @@ sudo dnf --enablerepo=devel install -y \
7674
zlib-devel
7775
```
7876

79-
## Install sqfstar / tar2sqfs for OCI-mode
77+
## Recommended: Install sqfstar / tar2sqfs for OCI-mode
8078

8179
If you intend to use the `--oci` execution mode of SingularityCE, your system
8280
must provide either:
@@ -117,6 +115,40 @@ for you distribution to enable the EPEL repository. Install `squashfs-tools-ng`
117115
sudo dnf install squashfs-tools-ng
118116
```
119117

118+
## Optional: Install conmon for `singularity oci` commands
119+
120+
If you intend to use the `singularity oci` commands, to run Singularity
121+
containers in an OCI lifecycle then `conmon` is required.
122+
123+
* `squashfs-tools / squashfs` >= 4.5, which provides the `sqfstar` utility.
124+
Older versions packaged by many distributions do not include `sqfstar`.
125+
* `squashfs-tools-ng`, which provides the `tar2sqfs` utility. This is not
126+
packaged by all distributions.
127+
128+
### Debian / Ubuntu
129+
130+
`conmon` is available as a package for Ubuntu 24.10+ and Debian 12+
131+
132+
```sh
133+
sudo apt get install conmon
134+
```
135+
136+
On older versions, use the latest binary from the [conmon GitHub
137+
releases](https://github.com/containers/conmon/releases) page. E.g.
138+
139+
```sh
140+
sudo curl -L -o /usr/local/bin/conmon https://github.com/containers/conmon/releases/download/v2.1.13/conmon.amd64
141+
sudo chmod +x /usr/local/bin/conmon
142+
```
143+
144+
### EL / Fedora
145+
146+
Install the distribution `conmon` package.
147+
148+
```sh
149+
sudo dnf install conmon
150+
```
151+
120152
## Install Go
121153

122154
Singularity is written in Go, and may require a newer version of Go than is

LICENSE_THIRD_PARTY.md

-212
Original file line numberDiff line numberDiff line change
@@ -300,218 +300,6 @@ The source file:
300300

301301
Contains code from the podman project, under the Apache License, Version 2.0.
302302

303-
## github.com/containers/conmon
304-
305-
The source files:
306-
307-
* `third_party/conmon/*`
308-
309-
Are code from the conmon project, under the Apache License, Version 2.0.
310-
311-
```text
312-
Apache License
313-
Version 2.0, January 2004
314-
https://www.apache.org/licenses/
315-
316-
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
317-
318-
1. Definitions.
319-
320-
"License" shall mean the terms and conditions for use, reproduction,
321-
and distribution as defined by Sections 1 through 9 of this document.
322-
323-
"Licensor" shall mean the copyright owner or entity authorized by
324-
the copyright owner that is granting the License.
325-
326-
"Legal Entity" shall mean the union of the acting entity and all
327-
other entities that control, are controlled by, or are under common
328-
control with that entity. For the purposes of this definition,
329-
"control" means (i) the power, direct or indirect, to cause the
330-
direction or management of such entity, whether by contract or
331-
otherwise, or (ii) ownership of fifty percent (50%) or more of the
332-
outstanding shares, or (iii) beneficial ownership of such entity.
333-
334-
"You" (or "Your") shall mean an individual or Legal Entity
335-
exercising permissions granted by this License.
336-
337-
"Source" form shall mean the preferred form for making modifications,
338-
including but not limited to software source code, documentation
339-
source, and configuration files.
340-
341-
"Object" form shall mean any form resulting from mechanical
342-
transformation or translation of a Source form, including but
343-
not limited to compiled object code, generated documentation,
344-
and conversions to other media types.
345-
346-
"Work" shall mean the work of authorship, whether in Source or
347-
Object form, made available under the License, as indicated by a
348-
copyright notice that is included in or attached to the work
349-
(an example is provided in the Appendix below).
350-
351-
"Derivative Works" shall mean any work, whether in Source or Object
352-
form, that is based on (or derived from) the Work and for which the
353-
editorial revisions, annotations, elaborations, or other modifications
354-
represent, as a whole, an original work of authorship. For the purposes
355-
of this License, Derivative Works shall not include works that remain
356-
separable from, or merely link (or bind by name) to the interfaces of,
357-
the Work and Derivative Works thereof.
358-
359-
"Contribution" shall mean any work of authorship, including
360-
the original version of the Work and any modifications or additions
361-
to that Work or Derivative Works thereof, that is intentionally
362-
submitted to Licensor for inclusion in the Work by the copyright owner
363-
or by an individual or Legal Entity authorized to submit on behalf of
364-
the copyright owner. For the purposes of this definition, "submitted"
365-
means any form of electronic, verbal, or written communication sent
366-
to the Licensor or its representatives, including but not limited to
367-
communication on electronic mailing lists, source code control systems,
368-
and issue tracking systems that are managed by, or on behalf of, the
369-
Licensor for the purpose of discussing and improving the Work, but
370-
excluding communication that is conspicuously marked or otherwise
371-
designated in writing by the copyright owner as "Not a Contribution."
372-
373-
"Contributor" shall mean Licensor and any individual or Legal Entity
374-
on behalf of whom a Contribution has been received by Licensor and
375-
subsequently incorporated within the Work.
376-
377-
2. Grant of Copyright License. Subject to the terms and conditions of
378-
this License, each Contributor hereby grants to You a perpetual,
379-
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
380-
copyright license to reproduce, prepare Derivative Works of,
381-
publicly display, publicly perform, sublicense, and distribute the
382-
Work and such Derivative Works in Source or Object form.
383-
384-
3. Grant of Patent License. Subject to the terms and conditions of
385-
this License, each Contributor hereby grants to You a perpetual,
386-
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
387-
(except as stated in this section) patent license to make, have made,
388-
use, offer to sell, sell, import, and otherwise transfer the Work,
389-
where such license applies only to those patent claims licensable
390-
by such Contributor that are necessarily infringed by their
391-
Contribution(s) alone or by combination of their Contribution(s)
392-
with the Work to which such Contribution(s) was submitted. If You
393-
institute patent litigation against any entity (including a
394-
cross-claim or counterclaim in a lawsuit) alleging that the Work
395-
or a Contribution incorporated within the Work constitutes direct
396-
or contributory patent infringement, then any patent licenses
397-
granted to You under this License for that Work shall terminate
398-
as of the date such litigation is filed.
399-
400-
4. Redistribution. You may reproduce and distribute copies of the
401-
Work or Derivative Works thereof in any medium, with or without
402-
modifications, and in Source or Object form, provided that You
403-
meet the following conditions:
404-
405-
(a) You must give any other recipients of the Work or
406-
Derivative Works a copy of this License; and
407-
408-
(b) You must cause any modified files to carry prominent notices
409-
stating that You changed the files; and
410-
411-
(c) You must retain, in the Source form of any Derivative Works
412-
that You distribute, all copyright, patent, trademark, and
413-
attribution notices from the Source form of the Work,
414-
excluding those notices that do not pertain to any part of
415-
the Derivative Works; and
416-
417-
(d) If the Work includes a "NOTICE" text file as part of its
418-
distribution, then any Derivative Works that You distribute must
419-
include a readable copy of the attribution notices contained
420-
within such NOTICE file, excluding those notices that do not
421-
pertain to any part of the Derivative Works, in at least one
422-
of the following places: within a NOTICE text file distributed
423-
as part of the Derivative Works; within the Source form or
424-
documentation, if provided along with the Derivative Works; or,
425-
within a display generated by the Derivative Works, if and
426-
wherever such third-party notices normally appear. The contents
427-
of the NOTICE file are for informational purposes only and
428-
do not modify the License. You may add Your own attribution
429-
notices within Derivative Works that You distribute, alongside
430-
or as an addendum to the NOTICE text from the Work, provided
431-
that such additional attribution notices cannot be construed
432-
as modifying the License.
433-
434-
You may add Your own copyright statement to Your modifications and
435-
may provide additional or different license terms and conditions
436-
for use, reproduction, or distribution of Your modifications, or
437-
for any such Derivative Works as a whole, provided Your use,
438-
reproduction, and distribution of the Work otherwise complies with
439-
the conditions stated in this License.
440-
441-
5. Submission of Contributions. Unless You explicitly state otherwise,
442-
any Contribution intentionally submitted for inclusion in the Work
443-
by You to the Licensor shall be under the terms and conditions of
444-
this License, without any additional terms or conditions.
445-
Notwithstanding the above, nothing herein shall supersede or modify
446-
the terms of any separate license agreement you may have executed
447-
with Licensor regarding such Contributions.
448-
449-
6. Trademarks. This License does not grant permission to use the trade
450-
names, trademarks, service marks, or product names of the Licensor,
451-
except as required for reasonable and customary use in describing the
452-
origin of the Work and reproducing the content of the NOTICE file.
453-
454-
7. Disclaimer of Warranty. Unless required by applicable law or
455-
agreed to in writing, Licensor provides the Work (and each
456-
Contributor provides its Contributions) on an "AS IS" BASIS,
457-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
458-
implied, including, without limitation, any warranties or conditions
459-
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
460-
PARTICULAR PURPOSE. You are solely responsible for determining the
461-
appropriateness of using or redistributing the Work and assume any
462-
risks associated with Your exercise of permissions under this License.
463-
464-
8. Limitation of Liability. In no event and under no legal theory,
465-
whether in tort (including negligence), contract, or otherwise,
466-
unless required by applicable law (such as deliberate and grossly
467-
negligent acts) or agreed to in writing, shall any Contributor be
468-
liable to You for damages, including any direct, indirect, special,
469-
incidental, or consequential damages of any character arising as a
470-
result of this License or out of the use or inability to use the
471-
Work (including but not limited to damages for loss of goodwill,
472-
work stoppage, computer failure or malfunction, or any and all
473-
other commercial damages or losses), even if such Contributor
474-
has been advised of the possibility of such damages.
475-
476-
9. Accepting Warranty or Additional Liability. While redistributing
477-
the Work or Derivative Works thereof, You may choose to offer,
478-
and charge a fee for, acceptance of support, warranty, indemnity,
479-
or other liability obligations and/or rights consistent with this
480-
License. However, in accepting such obligations, You may act only
481-
on Your own behalf and on Your sole responsibility, not on behalf
482-
of any other Contributor, and only if You agree to indemnify,
483-
defend, and hold each Contributor harmless for any liability
484-
incurred by, or claims asserted against, such Contributor by reason
485-
of your accepting any such warranty or additional liability.
486-
487-
END OF TERMS AND CONDITIONS
488-
489-
APPENDIX: How to apply the Apache License to your work.
490-
491-
To apply the Apache License to your work, attach the following
492-
boilerplate notice, with the fields enclosed by brackets "{}"
493-
replaced with your own identifying information. (Don't include
494-
the brackets!) The text should be enclosed in the appropriate
495-
comment syntax for the file format. We also recommend that a
496-
file or class name and description of purpose be included on the
497-
same "printed page" as the copyright notice for easier
498-
identification within third-party archives.
499-
500-
Copyright {yyyy} {name of copyright owner}
501-
502-
Licensed under the Apache License, Version 2.0 (the "License");
503-
you may not use this file except in compliance with the License.
504-
You may obtain a copy of the License at
505-
506-
https://www.apache.org/licenses/LICENSE-2.0
507-
508-
Unless required by applicable law or agreed to in writing, software
509-
distributed under the License is distributed on an "AS IS" BASIS,
510-
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
511-
See the License for the specific language governing permissions and
512-
limitations under the License.
513-
```
514-
515303
## github.com/google/go-containerregistry
516304

517305
The source files:

debian/control

-2
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ Build-Depends:
1010
dh-apparmor,
1111
git,
1212
libfuse-dev,
13-
libglib2.0-dev,
1413
libseccomp-dev,
1514
libtool,
1615
pkg-config,
@@ -28,7 +27,6 @@ Depends: ${misc:Depends}, ${shlibs:Depends},
2827
cryptsetup-bin,
2928
fuse,
3029
fuse2fs,
31-
libglib2.0-0,
3230
libseccomp2,
3331
squashfs-tools,
3432
uidmap

debian/singularity-ce.install

-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
usr/bin/singularity
22
usr/bin/run-singularity
3-
usr/lib/*/singularity/bin/conmon
43
usr/lib/*/singularity/bin/singularity-buildkitd
54
usr/lib/*/singularity/bin/squashfuse_ll
65
usr/lib/*/singularity/bin/starter

dist/rpm/singularity-ce.spec.in

+1-4
Original file line numberDiff line numberDiff line change
@@ -48,9 +48,6 @@ BuildRequires: /usr/bin/pkg-config
4848
# Paths to runtime dependencies detected by mconfig, so must be present at build time.
4949
BuildRequires: cryptsetup
5050
BuildRequires: squashfs-tools
51-
# Required for building bundled conmon
52-
BuildRequires: libseccomp-devel
53-
BuildRequires: glib2-devel
5451
# Required for building bundled squashfuse
5552
BuildRequires: autoconf
5653
BuildRequires: automake
@@ -60,6 +57,7 @@ BuildRequires: zlib-devel
6057
# Required for libsubid support
6158
BuildRequires: shadow-utils-subid-devel
6259

60+
Requires: conmon
6361
Requires: crun
6462
Requires: shadow-utils
6563
Requires: shadow-utils-subid
@@ -122,7 +120,6 @@ make DESTDIR=$RPM_BUILD_ROOT install -C builddir V=
122120
%{_bindir}/run-singularity
123121
%dir %{_libexecdir}/singularity
124122
%dir %{_libexecdir}/singularity/bin
125-
%{_libexecdir}/singularity/bin/conmon
126123
%{_libexecdir}/singularity/bin/singularity-buildkitd
127124
%{_libexecdir}/singularity/bin/squashfuse_ll
128125
%{_libexecdir}/singularity/bin/starter

internal/pkg/util/bin/bin.go

+3-4
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
// Copyright (c) 2019-2023, Sylabs Inc. All rights reserved.
1+
// Copyright (c) 2019-2025, Sylabs Inc. All rights reserved.
22
// This software is licensed under a 3-clause BSD license. Please consult the
33
// LICENSE.md file distributed with the sources of this project regarding your
44
// rights to use or distribute this software.
@@ -29,10 +29,9 @@ func FindBin(name string) (path string, err error) {
2929
// distro provided OCI runtime
3030
case "crun", "runc":
3131
return findOnPath(name)
32-
// our, or distro provided conmon
32+
// distro provided conmon
3333
case "conmon":
34-
// Behavior depends on a buildcfg - whether to use bundled or external conmon
35-
return findConmon(name)
34+
return findOnPath(name)
3635
// cryptsetup & nvidia-container-cli paths must be explicitly specified
3736
// They are called as root from the RPC server in a setuid install, so this
3837
// limits to sysadmin controlled paths.

0 commit comments

Comments
 (0)