source: ProjectBuilder/devel/contrib/mkctn@ 2372

Last change on this file since 2372 was 2372, checked in by Bruno Cornec, 5 years ago

Fix opensuse < 15 creation of ctn

  • Property svn:executable set to *
File size: 791 bytes
Line 
1#!/bin/bash
2#
3DISTRO=$1
4DISTROVER=$2
5ORIGREPO=$3
6ARCH=x86_64
7
8M=$DISTRO-$DISTROVER-$ARCH
9
10if [ _"$DISTRO" = _"mageia" ]; then
11 ORIGREPO=mageiaofficial
12 DISTROVER=${DISTROVER}-$ARCH
13elif [ _"$DISTRO" = _"opensuse" ]; then
14 vm=`echo $DISTROVER | cut -d . -f1`
15 if [ $vm -ge 15 ] && [ $vm -lt 42 ]; then
16 ORIGREPO=opensuse/leap
17 else
18 ORIGREPO=$DISTRO
19 fi
20else
21 ORIGREPO="$DISTRO"
22fi
23
24echo "Working on $M ..."
25echo "-----------------------------------"
26if [ _"$DISTRO" != _"mageia" ]; then
27 docker pull ${ORIGREPO}:$DISTROVER
28fi
29pb -p pb -T docker --stop-on-error -m $M newve -i ${ORIGREPO}:$DISTROVER && \
30pb -p pb -T docker --stop-on-error -m $M sbx2setupve && \
31pb -p pb -T docker --stop-on-error -m $M prepve && \
32pb -p pb -T docker --stop-on-error -m $M build2ve
33docker image prune -f
34
Note: See TracBrowser for help on using the repository browser.