File: bootc.install

package info (click to toggle)
cockpit 354-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 308,956 kB
  • sloc: javascript: 775,606; python: 40,351; ansic: 35,655; cpp: 11,117; sh: 3,511; makefile: 580; xml: 261
file content (25 lines) | stat: -rw-r--r-- 777 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#!/bin/sh
set -eux

cd /var/tmp/

# bootc images have their own deployed image in a local registry
podman run -d --rm --name ostree-registry -p 5000:5000 -v /var/lib/cockpit-test-registry/:/var/lib/registry localhost/test-registry

# build updated bootc image with our RPMs
podman build -t localhost/bootc-test --layers=false -f - . <<EOF
FROM localhost:5000/bootc:latest
COPY ./rpms /tmp/rpms
RUN rpm --upgrade --verbose /tmp/rpms/*.rpm && rm -r /tmp/rpms
COPY ./playground /usr/share/cockpit/playground
EOF

# deploy it
bootc switch --transport containers-storage localhost/bootc-test

# clean up
podman rm -ft0 ostree-registry
podman rmi localhost:5000/bootc localhost/bootc-test

# ensure that we don't accidentally test with container
podman rmi quay.io/cockpit/ws:latest