Example #1
0
File: image.go Project: appc/acpush
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

package schema

import (
	"encoding/json"
	"errors"

	"github.com/appc/acpush/Godeps/_workspace/src/github.com/appc/spec/schema/types"
)

const (
	ACIExtension      = ".aci"
	ImageManifestKind = types.ACKind("ImageManifest")
)

type ImageManifest struct {
	ACKind        types.ACKind       `json:"acKind"`
	ACVersion     types.SemVer       `json:"acVersion"`
	Name          types.ACIdentifier `json:"name"`
	Labels        types.Labels       `json:"labels,omitempty"`
	App           *types.App         `json:"app,omitempty"`
	Annotations   types.Annotations  `json:"annotations,omitempty"`
	Dependencies  types.Dependencies `json:"dependencies,omitempty"`
	PathWhitelist []string           `json:"pathWhitelist,omitempty"`
}

// imageManifest is a model to facilitate extra validation during the
// unmarshalling of the ImageManifest
Example #2
0
File: pod.go Project: appc/acpush
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

package schema

import (
	"encoding/json"
	"errors"
	"fmt"

	"github.com/appc/acpush/Godeps/_workspace/src/github.com/appc/spec/schema/types"
)

const PodManifestKind = types.ACKind("PodManifest")

type PodManifest struct {
	ACVersion   types.SemVer        `json:"acVersion"`
	ACKind      types.ACKind        `json:"acKind"`
	Apps        AppList             `json:"apps"`
	Volumes     []types.Volume      `json:"volumes"`
	Isolators   []types.Isolator    `json:"isolators"`
	Annotations types.Annotations   `json:"annotations"`
	Ports       []types.ExposedPort `json:"ports"`
}

// podManifest is a model to facilitate extra validation during the
// unmarshalling of the PodManifest
type podManifest PodManifest