12 # See the License for the specific language governing permissions
13 # and limitations under the License.
14 #
15 # When distributing Covered Code, include this CDDL HEADER in each
16 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
17 # If applicable, add the following below this CDDL HEADER, with the
18 # fields enclosed by brackets "[]" replaced with your own identifying
19 # information: Portions Copyright [yyyy] [name of copyright owner]
20 #
21 # CDDL HEADER END
22 #
23 #
24 # Copyright 2012 OmniTI Computer Consulting, Inc. All rights reserved.
25 # Use is subject to license terms.
26 #
27 fail() {
28 echo "ERROR: $*"
29 exit 1
30 }
31
32 PUBLISHER=omnios
33 : ${PKGURL:=http://pkg.omniti.com/omnios/release}
34 : ${GZIP_CMD:=gzip}
35 SRCDIR=$(dirname $0)
36 DIDWORK=0
37 BUILDNUM=${VERSION//r/}
38 if [[ ${SRCDIR:0:1} != "/" ]]; then
39 SRCDIR=`pwd`/$SRCDIR
40 fi
41 if [[ -z "${1}" ]]; then
42 echo "$0 <zfs pool> [checkpoint]"
43 exit 1
44 else
45 BASE=${1}
46 shift
47 BASEDIR=`zfs get -o value -H mountpoint $BASE`
48 fi
49 MKFILEDIR=/tmp
50 WORKDIR=$BASEDIR
51 ROOTDIR=$WORKDIR/root
52 if [[ ! -d $ROOTDIR ]]; then
53 zfs create -o compression=off $BASE/root || fail "zfs create failed"
|
12 # See the License for the specific language governing permissions
13 # and limitations under the License.
14 #
15 # When distributing Covered Code, include this CDDL HEADER in each
16 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
17 # If applicable, add the following below this CDDL HEADER, with the
18 # fields enclosed by brackets "[]" replaced with your own identifying
19 # information: Portions Copyright [yyyy] [name of copyright owner]
20 #
21 # CDDL HEADER END
22 #
23 #
24 # Copyright 2012 OmniTI Computer Consulting, Inc. All rights reserved.
25 # Use is subject to license terms.
26 #
27 fail() {
28 echo "ERROR: $*"
29 exit 1
30 }
31
32 # NOTE --> The URL needs to be updated with every release.
33 # Change "bloody" to whatever release the current branch is.
34 PUBLISHER=omnios
35 : ${PKGURL:=http://pkg.omniti.com/omnios/bloody}
36 : ${GZIP_CMD:=gzip}
37 SRCDIR=$(dirname $0)
38 DIDWORK=0
39 BUILDNUM=${VERSION//r/}
40 if [[ ${SRCDIR:0:1} != "/" ]]; then
41 SRCDIR=`pwd`/$SRCDIR
42 fi
43 if [[ -z "${1}" ]]; then
44 echo "$0 <zfs pool> [checkpoint]"
45 exit 1
46 else
47 BASE=${1}
48 shift
49 BASEDIR=`zfs get -o value -H mountpoint $BASE`
50 fi
51 MKFILEDIR=/tmp
52 WORKDIR=$BASEDIR
53 ROOTDIR=$WORKDIR/root
54 if [[ ! -d $ROOTDIR ]]; then
55 zfs create -o compression=off $BASE/root || fail "zfs create failed"
|