mirror of
https://github.com/kairos-io/kairos-agent.git
synced 2025-05-12 10:24:23 +00:00
* Fix hooks under encrypted partitions
We had a mess of mounting and unmounting things around when we try to
copy things to persistent.
Part of the changes (using the by-label to mount the persistent) are due
to the change in kcrypt. As we set the same label to the encrypted fs
and unencrypted fs, our utils.Mount could get mistaken and return the
first hit, which usually its the encrypted one, and we cannot mount that
one.
This patch brings it up to date.
- Makes bundles and logs hooks work when we have encrypted persistent.
It didnt work before.
- Makes both workflows the same.
- Locks everything once its over, to not leave encrypted parts around
- Mounts OEM so kcrypt can read the config if we are using a remote
server for encryption
- Mounts by label so there is not a change of getting the wrong device
- Uses the mount syscall directly. The util can mistake and return the
actual encrypted part if they both have the same label and finds it
first
---------
Signed-off-by: Itxaka <itxaka@kairos.io>
(cherry picked from commit b5869b4017
)
236 lines
11 KiB
Modula-2
236 lines
11 KiB
Modula-2
module github.com/kairos-io/kairos-agent/v2
|
|
|
|
go 1.22.5
|
|
|
|
require (
|
|
github.com/Masterminds/semver/v3 v3.3.0
|
|
github.com/Masterminds/sprig/v3 v3.3.0
|
|
github.com/cavaliergopher/grab/v3 v3.0.1
|
|
github.com/erikgeiser/promptkit v0.9.0
|
|
github.com/google/go-containerregistry v0.20.2
|
|
github.com/hashicorp/go-multierror v1.1.1
|
|
github.com/jaypipes/ghw v0.12.0
|
|
github.com/joho/godotenv v1.5.1
|
|
github.com/kairos-io/kairos-sdk v0.4.1
|
|
github.com/kairos-io/kcrypt v0.12.3
|
|
github.com/labstack/echo/v4 v4.12.0
|
|
github.com/mitchellh/mapstructure v1.5.0
|
|
github.com/mudler/go-nodepair v0.0.0-20221223092639-ba399a66fdfb
|
|
github.com/mudler/go-pluggable v0.0.0-20230126220627-7710299a0ae5
|
|
github.com/mudler/go-processmanager v0.0.0-20240820160718-8b802d3ecf82
|
|
github.com/mudler/yip v1.9.4
|
|
github.com/nxadm/tail v1.4.11
|
|
github.com/onsi/ginkgo/v2 v2.20.2
|
|
github.com/onsi/gomega v1.34.2
|
|
github.com/pterm/pterm v0.12.79
|
|
github.com/rs/zerolog v1.33.0
|
|
github.com/sanity-io/litter v1.5.5
|
|
github.com/sirupsen/logrus v1.9.3
|
|
github.com/spf13/viper v1.19.0
|
|
github.com/urfave/cli/v2 v2.27.4
|
|
golang.org/x/net v0.28.0
|
|
golang.org/x/oauth2 v0.22.0
|
|
golang.org/x/sys v0.24.0
|
|
gopkg.in/yaml.v3 v3.0.1
|
|
k8s.io/mount-utils v0.31.0
|
|
)
|
|
|
|
require (
|
|
github.com/distribution/reference v0.6.0
|
|
github.com/google/go-github/v63 v63.0.0
|
|
github.com/twpayne/go-vfs/v4 v4.3.0
|
|
)
|
|
|
|
require (
|
|
atomicgo.dev/cursor v0.2.0 // indirect
|
|
atomicgo.dev/keyboard v0.2.9 // indirect
|
|
atomicgo.dev/schedule v0.1.0 // indirect
|
|
dario.cat/mergo v1.0.1 // indirect
|
|
github.com/Masterminds/goutils v1.1.1 // indirect
|
|
github.com/Microsoft/go-winio v0.6.2 // indirect
|
|
github.com/Microsoft/hcsshim v0.11.7 // indirect
|
|
github.com/ProtonMail/go-crypto v1.0.0 // indirect
|
|
github.com/StackExchange/wmi v1.2.1 // indirect
|
|
github.com/alecthomas/assert/v2 v2.6.0 // indirect
|
|
github.com/anatol/devmapper.go v0.0.0-20230829043248-59ac2b9706ba // indirect
|
|
github.com/anatol/luks.go v0.0.0-20240507052915-92f8bb765f98 // indirect
|
|
github.com/atotto/clipboard v0.1.4 // indirect
|
|
github.com/avast/retry-go v3.0.0+incompatible // indirect
|
|
github.com/aybabtme/rgbterm v0.0.0-20170906152045-cc83f3b3ce59 // indirect
|
|
github.com/aymanbagabas/go-osc52/v2 v2.0.1 // indirect
|
|
github.com/cavaliergopher/grab v2.0.0+incompatible // indirect
|
|
github.com/charmbracelet/bubbles v0.16.1 // indirect
|
|
github.com/charmbracelet/bubbletea v0.24.2 // indirect
|
|
github.com/charmbracelet/lipgloss v0.7.1 // indirect
|
|
github.com/chuckpreslar/emission v0.0.0-20170206194824-a7ddd980baf9 // indirect
|
|
github.com/cloudflare/circl v1.3.7 // indirect
|
|
github.com/containerd/cgroups v1.1.0 // indirect
|
|
github.com/containerd/console v1.0.4-0.20230313162750-1ae8d489ac81 // indirect
|
|
github.com/containerd/containerd v1.7.20 // indirect
|
|
github.com/containerd/continuity v0.4.2 // indirect
|
|
github.com/containerd/errdefs v0.1.0 // indirect
|
|
github.com/containerd/log v0.1.0 // indirect
|
|
github.com/containerd/stargz-snapshotter/estargz v0.14.3 // indirect
|
|
github.com/coreos/go-systemd/v22 v22.5.0 // indirect
|
|
github.com/cpuguy83/go-md2man/v2 v2.0.4 // indirect
|
|
github.com/cyphar/filepath-securejoin v0.2.4 // indirect
|
|
github.com/denisbrodbeck/machineid v1.0.1 // indirect
|
|
github.com/dgryski/go-camellia v0.0.0-20191119043421-69a8a13fb23d // indirect
|
|
github.com/disintegration/imaging v1.6.2 // indirect
|
|
github.com/diskfs/go-diskfs v1.3.0 // indirect
|
|
github.com/docker/cli v27.1.1+incompatible // indirect
|
|
github.com/docker/distribution v2.8.2+incompatible // indirect
|
|
github.com/docker/docker v27.1.2+incompatible // indirect
|
|
github.com/docker/docker-credential-helpers v0.7.0 // indirect
|
|
github.com/docker/go-connections v0.4.0 // indirect
|
|
github.com/docker/go-units v0.5.0 // indirect
|
|
github.com/edsrzf/mmap-go v1.1.0 // indirect
|
|
github.com/eliukblau/pixterm v1.3.1 // indirect
|
|
github.com/emirpasic/gods v1.18.1 // indirect
|
|
github.com/felixge/httpsnoop v1.0.4 // indirect
|
|
github.com/foxboron/go-uefi v0.0.0-20240805124652-e2076f0e58ca // indirect
|
|
github.com/fsnotify/fsnotify v1.7.0 // indirect
|
|
github.com/gen2brain/shm v0.0.0-20200228170931-49f9650110c5 // indirect
|
|
github.com/ghodss/yaml v1.0.0 // indirect
|
|
github.com/go-git/gcfg v1.5.1-0.20230307220236-3a3c6141e376 // indirect
|
|
github.com/go-git/go-billy/v5 v5.5.0 // indirect
|
|
github.com/go-git/go-git/v5 v5.12.0 // indirect
|
|
github.com/go-logr/logr v1.4.2 // indirect
|
|
github.com/go-logr/stdr v1.2.2 // indirect
|
|
github.com/go-ole/go-ole v1.2.6 // indirect
|
|
github.com/go-task/slim-sprig/v3 v3.0.0 // indirect
|
|
github.com/godbus/dbus/v5 v5.1.0 // indirect
|
|
github.com/gofrs/flock v0.8.1 // indirect
|
|
github.com/gofrs/uuid v4.4.0+incompatible // indirect
|
|
github.com/gogo/protobuf v1.3.2 // indirect
|
|
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
|
|
github.com/golang/protobuf v1.5.4 // indirect
|
|
github.com/google/go-cmp v0.6.0 // indirect
|
|
github.com/google/go-querystring v1.1.0 // indirect
|
|
github.com/google/pprof v0.0.0-20240827171923-fa2c70bbbfe5 // indirect
|
|
github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510 // indirect
|
|
github.com/google/uuid v1.6.0 // indirect
|
|
github.com/gookit/color v1.5.4 // indirect
|
|
github.com/hashicorp/errwrap v1.1.0 // indirect
|
|
github.com/hashicorp/hcl v1.0.0 // indirect
|
|
github.com/huandu/xstrings v1.5.0 // indirect
|
|
github.com/itchyny/gojq v0.12.16 // indirect
|
|
github.com/itchyny/timefmt-go v0.1.6 // indirect
|
|
github.com/jaypipes/pcidb v1.0.0 // indirect
|
|
github.com/jbenet/go-context v0.0.0-20150711004518-d14ea06fba99 // indirect
|
|
github.com/jezek/xgb v0.0.0-20210312150743-0e0f116e1240 // indirect
|
|
github.com/jzelinskie/whirlpool v0.0.0-20201016144138-0675e54bb004 // indirect
|
|
github.com/kbinani/screenshot v0.0.0-20210720154843-7d3a670d8329 // indirect
|
|
github.com/kendru/darwin/go/depgraph v0.0.0-20221105232959-877d6a81060c // indirect
|
|
github.com/kevinburke/ssh_config v1.2.0 // indirect
|
|
github.com/klauspost/compress v1.17.4 // indirect
|
|
github.com/labstack/gommon v0.4.2 // indirect
|
|
github.com/lithammer/fuzzysearch v1.1.8 // indirect
|
|
github.com/lucasb-eyer/go-colorful v1.2.0 // indirect
|
|
github.com/lufia/plan9stats v0.0.0-20211012122336-39d0f177ccd0 // indirect
|
|
github.com/lxn/win v0.0.0-20210218163916-a377121e959e // indirect
|
|
github.com/magiconair/properties v1.8.7 // indirect
|
|
github.com/makiuchi-d/gozxing v0.1.1 // indirect
|
|
github.com/mattn/go-colorable v0.1.13 // indirect
|
|
github.com/mattn/go-isatty v0.0.20 // indirect
|
|
github.com/mattn/go-localereader v0.0.1 // indirect
|
|
github.com/mattn/go-runewidth v0.0.15 // indirect
|
|
github.com/mauromorales/xpasswd v0.4.0 // indirect
|
|
github.com/mitchellh/copystructure v1.2.0 // indirect
|
|
github.com/mitchellh/go-homedir v1.1.0 // indirect
|
|
github.com/mitchellh/reflectwalk v1.0.2 // indirect
|
|
github.com/moby/docker-image-spec v1.3.1 // indirect
|
|
github.com/moby/sys/mountinfo v0.7.1 // indirect
|
|
github.com/moby/sys/sequential v0.5.0 // indirect
|
|
github.com/mudler/entities v0.8.1 // indirect
|
|
github.com/muesli/ansi v0.0.0-20230316100256-276c6243b2f6 // indirect
|
|
github.com/muesli/cancelreader v0.2.2 // indirect
|
|
github.com/muesli/reflow v0.3.0 // indirect
|
|
github.com/muesli/termenv v0.15.2 // indirect
|
|
github.com/nfnt/resize v0.0.0-20180221191011-83c6a9932646 // indirect
|
|
github.com/opencontainers/go-digest v1.0.0 // indirect
|
|
github.com/opencontainers/image-spec v1.1.0 // indirect
|
|
github.com/opencontainers/runc v1.1.14 // indirect
|
|
github.com/opencontainers/runtime-spec v1.1.0 // indirect
|
|
github.com/otiai10/copy v1.14.0 // indirect
|
|
github.com/packethost/packngo v0.29.0 // indirect
|
|
github.com/pelletier/go-toml/v2 v2.2.2 // indirect
|
|
github.com/phayes/permbits v0.0.0-20190612203442-39d7c581d2ee // indirect
|
|
github.com/pierrec/lz4 v2.6.1+incompatible // indirect
|
|
github.com/pjbgf/sha1cd v0.3.0 // indirect
|
|
github.com/pkg/errors v0.9.1 // indirect
|
|
github.com/pkg/xattr v0.4.9 // indirect
|
|
github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c // indirect
|
|
github.com/qeesung/image2ascii v1.0.1 // indirect
|
|
github.com/rancher-sandbox/linuxkit v1.0.2 // indirect
|
|
github.com/rivo/uniseg v0.4.7 // indirect
|
|
github.com/russross/blackfriday/v2 v2.1.0 // indirect
|
|
github.com/saferwall/pe v1.5.4 // indirect
|
|
github.com/sagikazarmark/locafero v0.4.0 // indirect
|
|
github.com/sagikazarmark/slog-shim v0.1.0 // indirect
|
|
github.com/samber/lo v1.37.0 // indirect
|
|
github.com/santhosh-tekuri/jsonschema/v5 v5.3.1 // indirect
|
|
github.com/satori/go.uuid v1.2.1-0.20181028125025-b2ce2384e17b // indirect
|
|
github.com/secDre4mer/pkcs7 v0.0.0-20240322103146-665324a4461d // indirect
|
|
github.com/sergi/go-diff v1.3.2-0.20230802210424-5b0b94c5c0d3 // indirect
|
|
github.com/shirou/gopsutil/v4 v4.24.7 // indirect
|
|
github.com/shoenig/go-m1cpu v0.1.6 // indirect
|
|
github.com/shopspring/decimal v1.4.0 // indirect
|
|
github.com/skeema/knownhosts v1.2.2 // indirect
|
|
github.com/skip2/go-qrcode v0.0.0-20200617195104-da1b6568686e // indirect
|
|
github.com/sourcegraph/conc v0.3.0 // indirect
|
|
github.com/spectrocloud-labs/herd v0.4.2 // indirect
|
|
github.com/spf13/afero v1.11.0 // indirect
|
|
github.com/spf13/cast v1.7.0 // indirect
|
|
github.com/spf13/pflag v1.0.5 // indirect
|
|
github.com/subosito/gotenv v1.6.0 // indirect
|
|
github.com/swaggest/jsonschema-go v0.3.62 // indirect
|
|
github.com/swaggest/refl v1.3.0 // indirect
|
|
github.com/tklauser/go-sysconf v0.3.12 // indirect
|
|
github.com/tklauser/numcpus v0.6.1 // indirect
|
|
github.com/tredoe/osutil v1.5.0 // indirect
|
|
github.com/ulikunitz/xz v0.5.11 // indirect
|
|
github.com/valyala/bytebufferpool v1.0.0 // indirect
|
|
github.com/valyala/fasttemplate v1.2.2 // indirect
|
|
github.com/vbatts/tar-split v0.11.3 // indirect
|
|
github.com/vishvananda/netlink v1.2.1-beta.2 // indirect
|
|
github.com/vishvananda/netns v0.0.4 // indirect
|
|
github.com/vmware/vmw-guestinfo v0.0.0-20220317130741-510905f0efa3 // indirect
|
|
github.com/wayneashleyberry/terminal-dimensions v1.1.0 // indirect
|
|
github.com/xanzy/ssh-agent v0.3.3 // indirect
|
|
github.com/xo/terminfo v0.0.0-20220910002029-abceb7e1c41e // indirect
|
|
github.com/xrash/smetrics v0.0.0-20240521201337-686a1a2994c1 // indirect
|
|
github.com/yusufpapurcu/wmi v1.2.4 // indirect
|
|
github.com/zcalusic/sysinfo v1.1.0 // indirect
|
|
go.opencensus.io v0.24.0 // indirect
|
|
go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.49.0 // indirect
|
|
go.opentelemetry.io/otel v1.24.0 // indirect
|
|
go.opentelemetry.io/otel/metric v1.24.0 // indirect
|
|
go.opentelemetry.io/otel/trace v1.24.0 // indirect
|
|
go.uber.org/atomic v1.10.0 // indirect
|
|
go.uber.org/multierr v1.9.0 // indirect
|
|
golang.org/x/crypto v0.26.0 // indirect
|
|
golang.org/x/exp v0.0.0-20240719175910-8a7402abbf56 // indirect
|
|
golang.org/x/image v0.18.0 // indirect
|
|
golang.org/x/mod v0.20.0 // indirect
|
|
golang.org/x/sync v0.8.0 // indirect
|
|
golang.org/x/term v0.23.0 // indirect
|
|
golang.org/x/text v0.17.0 // indirect
|
|
golang.org/x/tools v0.24.0 // indirect
|
|
golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2 // indirect
|
|
google.golang.org/genproto/googleapis/rpc v0.0.0-20240314234333-6e1732d8331c // indirect
|
|
google.golang.org/grpc v1.62.1 // indirect
|
|
google.golang.org/protobuf v1.34.1 // indirect
|
|
gopkg.in/djherbis/times.v1 v1.3.0 // indirect
|
|
gopkg.in/ini.v1 v1.67.0 // indirect
|
|
gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7 // indirect
|
|
gopkg.in/warnings.v0 v0.1.2 // indirect
|
|
gopkg.in/yaml.v1 v1.0.0-20140924161607-9f9df34309c0 // indirect
|
|
gopkg.in/yaml.v2 v2.4.0 // indirect
|
|
howett.net/plist v1.0.0 // indirect
|
|
k8s.io/klog/v2 v2.130.1 // indirect
|
|
k8s.io/utils v0.0.0-20240711033017-18e509b52bc8 // indirect
|
|
pault.ag/go/modprobe v0.1.2 // indirect
|
|
pault.ag/go/topsort v0.1.1 // indirect
|
|
)
|