generated from hashicorp/packer-plugin-scaffolding
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathmain.go
33 lines (28 loc) · 991 Bytes
/
main.go
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
// Copyright (c) HashiCorp, Inc.
// SPDX-License-Identifier: MPL-2.0
package main
import (
"fmt"
"os"
"github.com/hashicorp/packer-plugin-sdk/plugin"
"github.com/naveenrajm7/packer-plugin-utm/builder/utm/cloud"
"github.com/naveenrajm7/packer-plugin-utm/builder/utm/iso"
"github.com/naveenrajm7/packer-plugin-utm/builder/utm/utm"
utmPPvagrant "github.com/naveenrajm7/packer-plugin-utm/post-processor/vagrant"
utmPPzip "github.com/naveenrajm7/packer-plugin-utm/post-processor/zip"
"github.com/naveenrajm7/packer-plugin-utm/version"
)
func main() {
pps := plugin.NewSet()
pps.RegisterBuilder("iso", new(iso.Builder))
pps.RegisterBuilder("utm", new(utm.Builder))
pps.RegisterBuilder("cloud", new(cloud.Builder))
pps.RegisterPostProcessor("zip", new(utmPPzip.PostProcessor))
pps.RegisterPostProcessor("vagrant", new(utmPPvagrant.PostProcessor))
pps.SetVersion(version.PluginVersion)
err := pps.Run()
if err != nil {
fmt.Fprintln(os.Stderr, err.Error())
os.Exit(1)
}
}