-
Notifications
You must be signed in to change notification settings - Fork 71
/
main.go
26 lines (22 loc) · 614 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 (
"log"
"github.com/hashicorp/packer-plugin-sdk/plugin"
v "github.com/hashicorp/packer-plugin-sdk/version"
"github.com/rgl/packer-plugin-windows-update/update"
)
var (
version = "0.0.0"
commit = "unknown"
date = "unknown"
)
func main() {
log.Printf("Starting packer-plugin-windows-update (version %s; commit %s; date %s)", version, commit, date)
pps := plugin.NewSet()
pps.RegisterProvisioner(plugin.DEFAULT_NAME, new(update.Provisioner))
pps.SetVersion(v.InitializePluginVersion(version, ""))
err := pps.Run()
if err != nil {
log.Fatalf("Failed to start: %v", err)
}
}