mirror of
https://github.com/linuxkit/linuxkit.git
synced 2025-07-22 02:21:34 +00:00
Merge pull request #2607 from ijc/content-trust
enable content trust for a bunch more repos
This commit is contained in:
commit
dfd72db820
@ -23,6 +23,9 @@ Replace by image: $0 --image <IMAGE> <NEW>
|
|||||||
Example: $0 --image linuxkit/foo abcdef567899
|
Example: $0 --image linuxkit/foo abcdef567899
|
||||||
Will tag all instances of linuxkit/foo with abcdef567899
|
Will tag all instances of linuxkit/foo with abcdef567899
|
||||||
|
|
||||||
|
$0 --image <IMAGE>:<NEW> is accepted as a convenient shortcut for cutting
|
||||||
|
and pasting e.g.the output of linuxkit pkg show-tag
|
||||||
|
|
||||||
By default, for convenience, if no mode is given (--image or --hash), the first method (--hash) is assumed.
|
By default, for convenience, if no mode is given (--image or --hash), the first method (--hash) is assumed.
|
||||||
Thus the following are equivalent:
|
Thus the following are equivalent:
|
||||||
$0 <OLD> <NEW>
|
$0 <OLD> <NEW>
|
||||||
@ -33,28 +36,39 @@ EOF
|
|||||||
|
|
||||||
|
|
||||||
# backwards compatibility
|
# backwards compatibility
|
||||||
if [ $# -eq 2 ]; then
|
if [ $# -eq 2 -a -n "${1%--*}" ]; then
|
||||||
set -- "--hash" "$1" "$2"
|
set -- "--hash" "$1" "$2"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# sufficient arguments
|
# sufficient arguments
|
||||||
if [ $# -ne 3 ] ; then
|
if [ $# -lt 2 -o $# -gt 3 ] ; then
|
||||||
usage
|
usage
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
# which mode?
|
# which mode?
|
||||||
case "$1" in
|
case "$1" in
|
||||||
--hash)
|
--hash)
|
||||||
|
if [ $# -ne 3 ] ; then
|
||||||
|
usage
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
old=$2
|
old=$2
|
||||||
new=$3
|
new=$3
|
||||||
|
|
||||||
git grep -w -l "\b$old\b" | xargs sed -i.bak -e "s,$old,$new,g"
|
git grep -w -l "\b$old\b" | xargs sed -i.bak -e "s,$old,$new,g"
|
||||||
;;
|
;;
|
||||||
--image)
|
--image)
|
||||||
image=$2
|
case $# in
|
||||||
hash=$3
|
2)
|
||||||
|
image=${2%:*}
|
||||||
|
hash=${2#*:}
|
||||||
|
;;
|
||||||
|
3)
|
||||||
|
image=$2
|
||||||
|
hash=$3
|
||||||
|
;;
|
||||||
|
esac
|
||||||
git grep -E -l "\b$image:" | xargs sed -i.bak -e "s,$image:[[:xdigit:]]"'\{40\}'",$image:$hash,g"
|
git grep -E -l "\b$image:" | xargs sed -i.bak -e "s,$image:[[:xdigit:]]"'\{40\}'",$image:$hash,g"
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
|
@ -7,7 +7,7 @@ init:
|
|||||||
- linuxkit/containerd:ed8e8f92e24dd4b94260cf147594ae3fd13a2182
|
- linuxkit/containerd:ed8e8f92e24dd4b94260cf147594ae3fd13a2182
|
||||||
onboot:
|
onboot:
|
||||||
- name: ltp
|
- name: ltp
|
||||||
image: linuxkit/test-ltp:96c9845f8bca2cfb2d3c5e6ca53d82f77b2fddd0
|
image: linuxkit/test-ltp:0967388fb338867dddd3c1a72470a1a7cec5a0dd
|
||||||
binds:
|
binds:
|
||||||
- /etc/ltp/baseline:/etc/ltp/baseline
|
- /etc/ltp/baseline:/etc/ltp/baseline
|
||||||
- name: poweroff
|
- name: poweroff
|
||||||
|
@ -1,5 +1,4 @@
|
|||||||
image: test-ltp
|
image: test-ltp
|
||||||
network: true
|
network: true
|
||||||
disable-content-trust: true
|
|
||||||
arches:
|
arches:
|
||||||
- amd64
|
- amd64
|
||||||
|
@ -1,2 +1 @@
|
|||||||
image: mkimage-dynamic-vhd
|
image: mkimage-dynamic-vhd
|
||||||
disable-content-trust: true
|
|
||||||
|
@ -1,2 +1 @@
|
|||||||
image: mkimage-gcp
|
image: mkimage-gcp
|
||||||
disable-content-trust: true
|
|
||||||
|
@ -1,4 +1,3 @@
|
|||||||
image: mkimage-iso-bios
|
image: mkimage-iso-bios
|
||||||
disable-content-trust: true
|
|
||||||
arches:
|
arches:
|
||||||
- amd64
|
- amd64
|
||||||
|
@ -1,3 +1,2 @@
|
|||||||
image: mkimage-iso-efi
|
image: mkimage-iso-efi
|
||||||
disable-content-trust: true
|
|
||||||
network: true
|
network: true
|
||||||
|
@ -1,2 +1 @@
|
|||||||
image: mkimage-vhd
|
image: mkimage-vhd
|
||||||
disable-content-trust: true
|
|
||||||
|
@ -1,2 +1 @@
|
|||||||
image: mkimage-vmdk
|
image: mkimage-vmdk
|
||||||
disable-content-trust: true
|
|
||||||
|
Loading…
Reference in New Issue
Block a user