~smoser/cirros/buildroot-upgrade

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
26
27
28
29
30
31
32
33
34
35
36
# set version to build
VER=0.3.2

# get some build dependencies:
sudo apt-get update
sudo apt-get -qy install bison flex texinfo build-essential gettext ncurses-dev unzip bzr qemu-kvm quilt wget rsync

bzr init-repo cirros
cd cirros
bzr branch lp:cirros trunk

bzr branch -r $VER trunk cirros-$VER
cd cirros-$VER

./bin/build-release $VER 2>&1 | tee build-$VER.log

# pull that release content into an existing mirror dir
rsync -av --progress $USER@$HOST:/path/to/build-$VER/release $VER

## now create simplestreams data ##
# to create simplestream data with mirror at $mirror_d
( cd .. && bzr branch lp:simplestreams simplestreams )
bzr branch lp:cirros cirros

./bin/mirror-dump-sstream-data "$mirror_d" > mdata.txt
../simplestreams/tools/tenv tab2streams mdata.txt cirros-streams.d
../simplestreams/tools/tenv env -u GNUPGHOME   \
    SS_GPG_BATCH=1 SS_GPG_DEFAULT_KEY=A5DDB840 js2signed cirros-streams.d
##

# to sign individual things
for x in "$out/release/"*; do
   [ "${x%.asc}" = "$x" ] || continue
   [ -e "$x.asc" ] && continue
   gpg --armor --sign --detach-sig "$x"
done