forked from digitalocean/packer-plugin-digitalocean
-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.go
26 lines (22 loc) · 768 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
package main
import (
"fmt"
"os"
"github.com/digitalocean/packer-plugin-digitalocean/builder/digitalocean"
"github.com/digitalocean/packer-plugin-digitalocean/datasource/image"
digitaloceanPP "github.com/digitalocean/packer-plugin-digitalocean/post-processor/digitalocean-import"
"github.com/digitalocean/packer-plugin-digitalocean/version"
"github.com/hashicorp/packer-plugin-sdk/plugin"
)
func main() {
pps := plugin.NewSet()
pps.RegisterBuilder(plugin.DEFAULT_NAME, new(digitalocean.Builder))
pps.RegisterPostProcessor("import", new(digitaloceanPP.PostProcessor))
pps.RegisterDatasource("image", new(image.Datasource))
pps.SetVersion(version.PluginVersion)
err := pps.Run()
if err != nil {
fmt.Fprintln(os.Stderr, err.Error())
os.Exit(1)
}
}