1e71ca95cSGerald Jelinek#!/bin/ksh -p
2e71ca95cSGerald Jelinek#
3e71ca95cSGerald Jelinek# CDDL HEADER START
4e71ca95cSGerald Jelinek#
5e71ca95cSGerald Jelinek# The contents of this file are subject to the terms of the
6e71ca95cSGerald Jelinek# Common Development and Distribution License (the "License").
7e71ca95cSGerald Jelinek# You may not use this file except in compliance with the License.
8e71ca95cSGerald Jelinek#
9e71ca95cSGerald Jelinek# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
10e71ca95cSGerald Jelinek# or http://www.opensolaris.org/os/licensing.
11e71ca95cSGerald Jelinek# See the License for the specific language governing permissions
12e71ca95cSGerald Jelinek# and limitations under the License.
13e71ca95cSGerald Jelinek#
14e71ca95cSGerald Jelinek# When distributing Covered Code, include this CDDL HEADER in each
15e71ca95cSGerald Jelinek# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
16e71ca95cSGerald Jelinek# If applicable, add the following below this CDDL HEADER, with the
17e71ca95cSGerald Jelinek# fields enclosed by brackets "[]" replaced with your own identifying
18e71ca95cSGerald Jelinek# information: Portions Copyright [yyyy] [name of copyright owner]
19e71ca95cSGerald Jelinek#
20e71ca95cSGerald Jelinek# CDDL HEADER END
21*2a8b76b2SSusan Kamm-Worrell#
22*2a8b76b2SSusan Kamm-Worrell
23e71ca95cSGerald Jelinek#
24e71ca95cSGerald Jelinek#
25*2a8b76b2SSusan Kamm-Worrell# Copyright (c) 2009, 2010, Oracle and/or its affiliates. All rights reserved.
26e71ca95cSGerald Jelinek#
27e71ca95cSGerald Jelinek
28e71ca95cSGerald Jelinek. /usr/lib/brand/solaris10/common.ksh
29e71ca95cSGerald Jelinek
30e71ca95cSGerald Jelinek# States
31e71ca95cSGerald Jelinek# ZONE_STATE_CONFIGURED           0 (never see)
32e71ca95cSGerald Jelinek# ZONE_STATE_INCOMPLETE           1 (never see)
33e71ca95cSGerald Jelinek# ZONE_STATE_INSTALLED            2
34e71ca95cSGerald Jelinek# ZONE_STATE_READY                3
35e71ca95cSGerald Jelinek# ZONE_STATE_RUNNING              4
36e71ca95cSGerald Jelinek# ZONE_STATE_SHUTTING_DOWN        5
37e71ca95cSGerald Jelinek# ZONE_STATE_DOWN                 6
38e71ca95cSGerald Jelinek# ZONE_STATE_MOUNTED              7
39e71ca95cSGerald Jelinek
40e71ca95cSGerald Jelinek# cmd
41e71ca95cSGerald Jelinek#
42e71ca95cSGerald Jelinek# ready			0
43e71ca95cSGerald Jelinek# boot			1
44e71ca95cSGerald Jelinek# halt			4
45e71ca95cSGerald Jelinek
46e71ca95cSGerald Jelinekzonename=$1
47e71ca95cSGerald Jelinekzonepath=$2
48e71ca95cSGerald Jelinekstate=$3
49e71ca95cSGerald Jelinekcmd=$4
50*2a8b76b2SSusan Kamm-Worrellaltroot=$5		# unused at this time for s10 branded zones
51e71ca95cSGerald Jelinek
52e71ca95cSGerald Jelinek# If we're readying the zone, update the zone index file to look like this is
53e71ca95cSGerald Jelinek# the global zone.
54e71ca95cSGerald Jelinekif (( $cmd == 0 )); then
55e71ca95cSGerald Jelinek	echo "global:installed:/" > $zonepath/root/etc/zones/index
56e71ca95cSGerald Jelinekfi
57e71ca95cSGerald Jelinek
58e71ca95cSGerald Jelinekexit 0
59