Merge branch 'master' into website-post-update-revisions
This commit is contained in:
commit
7c5c20bfda
|
@ -4,8 +4,8 @@ Describe the change you are making here!
|
||||||
|
|
||||||
Please include tests. Check out these examples:
|
Please include tests. Check out these examples:
|
||||||
|
|
||||||
- https://github.com/mitchellh/packer/blob/master/builder/virtualbox/common/ssh_config_test.go#L19-L37
|
- https://github.com/hashicorp/packer/blob/master/builder/virtualbox/common/ssh_config_test.go#L19-L37
|
||||||
- https://github.com/mitchellh/packer/blob/master/post-processor/compress/post-processor_test.go#L153-L182
|
- https://github.com/hashicorp/packer/blob/master/post-processor/compress/post-processor_test.go#L153-L182
|
||||||
|
|
||||||
If your PR resolves any open issue(s), please indicate them like this so they will be closed when your PR is merged:
|
If your PR resolves any open issue(s), please indicate them like this so they will be closed when your PR is merged:
|
||||||
|
|
||||||
|
|
34
CHANGELOG.md
34
CHANGELOG.md
|
@ -1,9 +1,22 @@
|
||||||
## (Unreleased)
|
## (Unreleased)
|
||||||
|
|
||||||
|
### IMPROVEMENTS:
|
||||||
|
|
||||||
|
* builder/amazon: validate ami name. [GH-4762]
|
||||||
|
* builder/digitalocean: Added support for monitoring. [GH-4782]
|
||||||
|
* builder/openstack: Add ssh agent support. [GH-4655]
|
||||||
|
* builder/parallels-iso: Configuration of disk type, plain or expanding.
|
||||||
|
[GH-4621]
|
||||||
|
|
||||||
|
## 1.0.0 (April 4, 2017)
|
||||||
|
|
||||||
### BUG FIXES:
|
### BUG FIXES:
|
||||||
|
|
||||||
* builder/googlecompute: Correct values for `on_host_maintenance`. [GH-4643]
|
* core: fix version number
|
||||||
* builder/amazon: Fix crash in `step_region_copy`. [GH-4642]
|
* communicator/ssh: don't return error if we can't close connection. #4741
|
||||||
|
* builder/googlecompute: Use "default" service account. [GH-4749]
|
||||||
|
* core: Invoking packer `--help` or `--version` now exits with status 0.
|
||||||
|
[GH-4723]
|
||||||
* core: show correct step name when debugging. [GH-4672]
|
* core: show correct step name when debugging. [GH-4672]
|
||||||
* builder/virtualbox: fix `none` communicator by allowing skipping upload of
|
* builder/virtualbox: fix `none` communicator by allowing skipping upload of
|
||||||
version file. [GH-4678]
|
version file. [GH-4678]
|
||||||
|
@ -12,22 +25,21 @@
|
||||||
* builder/amazon: Fix b/c issue by reporting again the tags we create.
|
* builder/amazon: Fix b/c issue by reporting again the tags we create.
|
||||||
[GH-4704]
|
[GH-4704]
|
||||||
* builder/virtualbox: retry removing floppy controller. [GH-4705]
|
* builder/virtualbox: retry removing floppy controller. [GH-4705]
|
||||||
* builder/googlecompute: Use "default" service account. [GH-4749]
|
* builder/googlecompute: Correct values for `on_host_maintenance`. [GH-4643]
|
||||||
|
* builder/amazon: Fix crash in `step_region_copy`. [GH-4642]
|
||||||
|
|
||||||
### IMRPOVEMENTS:
|
### IMPROVEMENTS:
|
||||||
|
|
||||||
* builder/amazon: validate ssh key name/file. [GH-4665]
|
* More diligently try to complete azure-setup.sh. [GH-4752]
|
||||||
* builder/amazon: set force_deregister to true on -force. [GH-4649]
|
|
||||||
* builder/hyper-v: validate output dir in step, not in config. [GH-4645]
|
|
||||||
* website: fix display on ios devices. [GH-4618]
|
|
||||||
* builder/openstack: Add ssh agent support. [GH-4655]
|
|
||||||
* builder/parallels-iso: Configuration of disk type, plain or expanding.
|
|
||||||
[GH-4621]
|
|
||||||
* builder/ansible: Clearer error message when we have problems getting the
|
* builder/ansible: Clearer error message when we have problems getting the
|
||||||
ansible version. [GH-4694]
|
ansible version. [GH-4694]
|
||||||
* builder/amazon-chroot: Ability to give an empty list in `copy_files` to
|
* builder/amazon-chroot: Ability to give an empty list in `copy_files` to
|
||||||
prevent the default `/etc/resolv.conf` file from being copied. If `copy_files`
|
prevent the default `/etc/resolv.conf` file from being copied. If `copy_files`
|
||||||
isn't given at all, the default behavior remains. [GH-4708]
|
isn't given at all, the default behavior remains. [GH-4708]
|
||||||
|
* builder/amazon: validate ssh key name/file. [GH-4665]
|
||||||
|
* builder/amazon: set force_deregister to true on -force. [GH-4649]
|
||||||
|
* builder/hyper-v: validate output dir in step, not in config. [GH-4645]
|
||||||
|
* website: fix display on ios devices. [GH-4618]
|
||||||
|
|
||||||
## 0.12.3 (March 1, 2017)
|
## 0.12.3 (March 1, 2017)
|
||||||
|
|
||||||
|
|
|
@ -65,28 +65,28 @@ following steps in order to be able to compile and test Packer. These instructio
|
||||||
```
|
```
|
||||||
|
|
||||||
3. Download the Packer source (and its dependencies) by running `go get
|
3. Download the Packer source (and its dependencies) by running `go get
|
||||||
github.com/mitchellh/packer`. This will download the Packer source to
|
github.com/hashicorp/packer`. This will download the Packer source to
|
||||||
`$GOPATH/src/github.com/mitchellh/packer`.
|
`$GOPATH/src/github.com/hashicorp/packer`.
|
||||||
|
|
||||||
4. When working on packer `cd $GOPATH/src/github.com/mitchellh/packer` so you
|
4. When working on packer `cd $GOPATH/src/github.com/hashicorp/packer` so you
|
||||||
can run `make` and easily access other files. Run `make help` to get
|
can run `make` and easily access other files. Run `make help` to get
|
||||||
information about make targets.
|
information about make targets.
|
||||||
|
|
||||||
5. Make your changes to the Packer source. You can run `make` in
|
5. Make your changes to the Packer source. You can run `make` in
|
||||||
`$GOPATH/src/github.com/mitchellh/packer` to run tests and build the packer
|
`$GOPATH/src/github.com/hashicorp/packer` to run tests and build the packer
|
||||||
binary. Any compilation errors will be shown when the binaries are
|
binary. Any compilation errors will be shown when the binaries are
|
||||||
rebuilding. If you don't have `make` you can simply run `go build -o bin/packer .` from the project root.
|
rebuilding. If you don't have `make` you can simply run `go build -o bin/packer .` from the project root.
|
||||||
|
|
||||||
6. After running building packer successfully, use
|
6. After running building packer successfully, use
|
||||||
`$GOPATH/src/github.com/mitchellh/packer/bin/packer` to build a machine and
|
`$GOPATH/src/github.com/hashicorp/packer/bin/packer` to build a machine and
|
||||||
verify your changes work. For instance: `$GOPATH/src/github.com/mitchellh/packer/bin/packer build template.json`.
|
verify your changes work. For instance: `$GOPATH/src/github.com/hashicorp/packer/bin/packer build template.json`.
|
||||||
|
|
||||||
7. If everything works well and the tests pass, run `go fmt` on your code
|
7. If everything works well and the tests pass, run `go fmt` on your code
|
||||||
before submitting a pull-request.
|
before submitting a pull-request.
|
||||||
|
|
||||||
### Opening an Pull Request
|
### Opening an Pull Request
|
||||||
|
|
||||||
When you are ready to open a pull-request, you will need to [fork packer](https://github.com/mitchellh/packer#fork-destination-box), push your changes to your fork, and then open a pull-request.
|
When you are ready to open a pull-request, you will need to [fork packer](https://github.com/hashicorp/packer#fork-destination-box), push your changes to your fork, and then open a pull-request.
|
||||||
|
|
||||||
For example, my github username is `cbednarski` so I would do the following:
|
For example, my github username is `cbednarski` so I would do the following:
|
||||||
|
|
||||||
|
@ -104,7 +104,7 @@ From there, open your fork in your browser to open a new pull-request.
|
||||||
|
|
||||||
The easiest way to work on a fork is to set it as a remote of the packer project. After following the steps in "Setting up Go to work on Packer":
|
The easiest way to work on a fork is to set it as a remote of the packer project. After following the steps in "Setting up Go to work on Packer":
|
||||||
|
|
||||||
1. Navigate to $GOPATH/src/github.com/mitchellh/packer
|
1. Navigate to $GOPATH/src/github.com/hashicorp/packer
|
||||||
2. Add the remote `git remote add <name of remote> <github url of fork>`. For example `git remote add mwhooker https://github.com/mwhooker/packer.git`.
|
2. Add the remote `git remote add <name of remote> <github url of fork>`. For example `git remote add mwhooker https://github.com/mwhooker/packer.git`.
|
||||||
3. Checkout a feature branch: `git checkout -b new-feature`
|
3. Checkout a feature branch: `git checkout -b new-feature`
|
||||||
4. Make changes
|
4. Make changes
|
||||||
|
|
|
@ -5,8 +5,8 @@
|
||||||
[![GoDoc][godoc-badge]][godoc]
|
[![GoDoc][godoc-badge]][godoc]
|
||||||
[![GoReportCard][report-badge]][report]
|
[![GoReportCard][report-badge]][report]
|
||||||
|
|
||||||
[travis-badge]: https://travis-ci.org/mitchellh/packer.svg?branch=master
|
[travis-badge]: https://travis-ci.org/hashicorp/packer.svg?branch=master
|
||||||
[travis]: https://travis-ci.org/mitchellh/packer
|
[travis]: https://travis-ci.org/hashicorp/packer
|
||||||
[appveyor-badge]: https://ci.appveyor.com/api/projects/status/github/mitchellh/packer?branch=master&svg=true
|
[appveyor-badge]: https://ci.appveyor.com/api/projects/status/github/mitchellh/packer?branch=master&svg=true
|
||||||
[appveyor]: https://ci.appveyor.com/project/hashicorp/packer
|
[appveyor]: https://ci.appveyor.com/project/hashicorp/packer
|
||||||
[godoc-badge]: https://godoc.org/github.com/mitchellh/packer?status.svg
|
[godoc-badge]: https://godoc.org/github.com/mitchellh/packer?status.svg
|
||||||
|
@ -49,7 +49,7 @@ The images that Packer creates can easily be turned into
|
||||||
## Quick Start
|
## Quick Start
|
||||||
Download and install packages and dependencies
|
Download and install packages and dependencies
|
||||||
```
|
```
|
||||||
go get github.com/mitchellh/packer
|
go get github.com/hashicorp/packer
|
||||||
```
|
```
|
||||||
|
|
||||||
**Note:** There is a great
|
**Note:** There is a great
|
||||||
|
@ -107,4 +107,4 @@ http://www.packer.io/docs
|
||||||
|
|
||||||
## Developing Packer
|
## Developing Packer
|
||||||
|
|
||||||
See [CONTRIBUTING.md](https://github.com/mitchellh/packer/blob/master/CONTRIBUTING.md) for best practices and instructions on setting up your development environment to work on Packer.
|
See [CONTRIBUTING.md](https://github.com/hashicorp/packer/blob/master/CONTRIBUTING.md) for best practices and instructions on setting up your development environment to work on Packer.
|
||||||
|
|
|
@ -29,9 +29,9 @@ build_script:
|
||||||
- ps: |
|
- ps: |
|
||||||
go.exe test (go.exe list ./... `
|
go.exe test (go.exe list ./... `
|
||||||
|? { -not $_.Contains('/vendor/') } `
|
|? { -not $_.Contains('/vendor/') } `
|
||||||
|? { $_ -ne 'github.com/mitchellh/packer/builder/parallels/common' } `
|
|? { $_ -ne 'github.com/hashicorp/packer/builder/parallels/common' } `
|
||||||
|? { $_ -ne 'github.com/mitchellh/packer/common' }`
|
|? { $_ -ne 'github.com/hashicorp/packer/common' }`
|
||||||
|? { $_ -ne 'github.com/mitchellh/packer/provisioner/ansible' })
|
|? { $_ -ne 'github.com/hashicorp/packer/provisioner/ansible' })
|
||||||
|
|
||||||
test: off
|
test: off
|
||||||
|
|
||||||
|
|
|
@ -11,12 +11,12 @@ import (
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/aws/session"
|
"github.com/aws/aws-sdk-go/aws/session"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
awscommon "github.com/hashicorp/packer/builder/amazon/common"
|
||||||
|
"github.com/hashicorp/packer/common"
|
||||||
|
"github.com/hashicorp/packer/helper/config"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
|
"github.com/hashicorp/packer/template/interpolate"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
awscommon "github.com/mitchellh/packer/builder/amazon/common"
|
|
||||||
"github.com/mitchellh/packer/common"
|
|
||||||
"github.com/mitchellh/packer/helper/config"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
"github.com/mitchellh/packer/template/interpolate"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// The unique ID for this builder
|
// The unique ID for this builder
|
||||||
|
|
|
@ -3,7 +3,7 @@ package chroot
|
||||||
import (
|
import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/mitchellh/packer/packer"
|
"github.com/hashicorp/packer/packer"
|
||||||
)
|
)
|
||||||
|
|
||||||
func testConfig() map[string]interface{} {
|
func testConfig() map[string]interface{} {
|
||||||
|
|
|
@ -12,7 +12,7 @@ import (
|
||||||
"strings"
|
"strings"
|
||||||
"syscall"
|
"syscall"
|
||||||
|
|
||||||
"github.com/mitchellh/packer/packer"
|
"github.com/hashicorp/packer/packer"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Communicator is a special communicator that works by executing
|
// Communicator is a special communicator that works by executing
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
package chroot
|
package chroot
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/mitchellh/packer/packer"
|
"github.com/hashicorp/packer/packer"
|
||||||
"testing"
|
"testing"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -3,9 +3,9 @@ package chroot
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/mitchellh/packer/packer"
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/packer/post-processor/shell-local"
|
"github.com/hashicorp/packer/post-processor/shell-local"
|
||||||
"github.com/mitchellh/packer/template/interpolate"
|
"github.com/hashicorp/packer/template/interpolate"
|
||||||
)
|
)
|
||||||
|
|
||||||
func RunLocalCommands(commands []string, wrappedCommand CommandWrapper, ctx interpolate.Context, ui packer.Ui) error {
|
func RunLocalCommands(commands []string, wrappedCommand CommandWrapper, ctx interpolate.Context, ui packer.Ui) error {
|
||||||
|
|
|
@ -7,9 +7,9 @@ import (
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
awscommon "github.com/hashicorp/packer/builder/amazon/common"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
awscommon "github.com/mitchellh/packer/builder/amazon/common"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// StepAttachVolume attaches the previously created volume to an
|
// StepAttachVolume attaches the previously created volume to an
|
||||||
|
|
|
@ -4,8 +4,8 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// StepCheckRootDevice makes sure the root device on the AMI is EBS-backed.
|
// StepCheckRootDevice makes sure the root device on the AMI is EBS-backed.
|
||||||
|
|
|
@ -3,8 +3,8 @@ package chroot
|
||||||
import (
|
import (
|
||||||
"log"
|
"log"
|
||||||
|
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// StepChrootProvision provisions the instance within a chroot.
|
// StepChrootProvision provisions the instance within a chroot.
|
||||||
|
|
|
@ -3,8 +3,8 @@ package chroot
|
||||||
import (
|
import (
|
||||||
"bytes"
|
"bytes"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
"log"
|
"log"
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
)
|
)
|
||||||
|
|
|
@ -6,9 +6,9 @@ import (
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/aws"
|
"github.com/aws/aws-sdk-go/aws"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
awscommon "github.com/hashicorp/packer/builder/amazon/common"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
awscommon "github.com/mitchellh/packer/builder/amazon/common"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// StepCreateVolume creates a new volume from the snapshot of the root
|
// StepCreateVolume creates a new volume from the snapshot of the root
|
||||||
|
|
|
@ -2,8 +2,8 @@ package chroot
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
"log"
|
"log"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -2,8 +2,8 @@ package chroot
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
"log"
|
"log"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -2,8 +2,8 @@ package chroot
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
"log"
|
"log"
|
||||||
"os"
|
"os"
|
||||||
"path/filepath"
|
"path/filepath"
|
||||||
|
|
|
@ -5,9 +5,9 @@ import (
|
||||||
"log"
|
"log"
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
"github.com/hashicorp/packer/builder/amazon/common"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/builder/amazon/common"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// StepInstanceInfo verifies that this builder is running on an EC2 instance.
|
// StepInstanceInfo verifies that this builder is running on an EC2 instance.
|
||||||
|
|
|
@ -9,9 +9,9 @@ import (
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
|
"github.com/hashicorp/packer/template/interpolate"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
"github.com/mitchellh/packer/template/interpolate"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type mountPathData struct {
|
type mountPathData struct {
|
||||||
|
|
|
@ -3,8 +3,8 @@ package chroot
|
||||||
import (
|
import (
|
||||||
"bytes"
|
"bytes"
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
"os"
|
"os"
|
||||||
"os/exec"
|
"os/exec"
|
||||||
"syscall"
|
"syscall"
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
package chroot
|
package chroot
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type postMountCommandsData struct {
|
type postMountCommandsData struct {
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
package chroot
|
package chroot
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type preMountCommandsData struct {
|
type preMountCommandsData struct {
|
||||||
|
|
|
@ -5,8 +5,8 @@ import (
|
||||||
"log"
|
"log"
|
||||||
"os"
|
"os"
|
||||||
|
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// StepPrepareDevice finds an available device and sets it.
|
// StepPrepareDevice finds an available device and sets it.
|
||||||
|
|
|
@ -5,9 +5,9 @@ import (
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/aws"
|
"github.com/aws/aws-sdk-go/aws"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
awscommon "github.com/hashicorp/packer/builder/amazon/common"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
awscommon "github.com/mitchellh/packer/builder/amazon/common"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// StepRegisterAMI creates the AMI.
|
// StepRegisterAMI creates the AMI.
|
||||||
|
|
|
@ -6,9 +6,9 @@ import (
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
awscommon "github.com/hashicorp/packer/builder/amazon/common"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
awscommon "github.com/mitchellh/packer/builder/amazon/common"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// StepSnapshot creates a snapshot of the created volume.
|
// StepSnapshot creates a snapshot of the created volume.
|
||||||
|
|
|
@ -12,7 +12,7 @@ import (
|
||||||
"github.com/aws/aws-sdk-go/aws/credentials/ec2rolecreds"
|
"github.com/aws/aws-sdk-go/aws/credentials/ec2rolecreds"
|
||||||
"github.com/aws/aws-sdk-go/aws/ec2metadata"
|
"github.com/aws/aws-sdk-go/aws/ec2metadata"
|
||||||
"github.com/aws/aws-sdk-go/aws/session"
|
"github.com/aws/aws-sdk-go/aws/session"
|
||||||
"github.com/mitchellh/packer/template/interpolate"
|
"github.com/hashicorp/packer/template/interpolate"
|
||||||
)
|
)
|
||||||
|
|
||||||
// AccessConfig is for common configuration related to AWS access
|
// AccessConfig is for common configuration related to AWS access
|
||||||
|
|
|
@ -2,8 +2,9 @@ package common
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"regexp"
|
||||||
|
|
||||||
"github.com/mitchellh/packer/template/interpolate"
|
"github.com/hashicorp/packer/template/interpolate"
|
||||||
)
|
)
|
||||||
|
|
||||||
// AMIConfig is for common configuration related to creating AMIs.
|
// AMIConfig is for common configuration related to creating AMIs.
|
||||||
|
@ -68,6 +69,18 @@ func (c *AMIConfig) Prepare(ctx *interpolate.Context) []error {
|
||||||
errs = append(errs, fmt.Errorf("Cannot share snapshot encrypted with default KMS key"))
|
errs = append(errs, fmt.Errorf("Cannot share snapshot encrypted with default KMS key"))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if len(c.AMIName) < 3 || len(c.AMIName) > 128 {
|
||||||
|
errs = append(errs, fmt.Errorf("AMIName must be between 3 and 128 characters long"))
|
||||||
|
}
|
||||||
|
|
||||||
|
amiNameRe := regexp.MustCompile(`^[0-9a-zA-Z().\-/_]+$`)
|
||||||
|
if !amiNameRe.MatchString(c.AMIName) {
|
||||||
|
errs = append(errs, fmt.Errorf("AMIName should only contain letters,"+
|
||||||
|
" numbers, '(', ')', '.', '-', '/' and '_'. You can use the "+
|
||||||
|
"`clean_ami_name` template filter to automatically clean your ami "+
|
||||||
|
"name."))
|
||||||
|
}
|
||||||
|
|
||||||
if len(errs) > 0 {
|
if len(errs) > 0 {
|
||||||
return errs
|
return errs
|
||||||
}
|
}
|
||||||
|
|
|
@ -74,3 +74,37 @@ func TestAMIConfigPrepare_Share_EncryptedBoot(t *testing.T) {
|
||||||
t.Fatal("shouldn't be able to share ami with encrypted boot volume")
|
t.Fatal("shouldn't be able to share ami with encrypted boot volume")
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func TestAMINameValidation(t *testing.T) {
|
||||||
|
c := testAMIConfig()
|
||||||
|
|
||||||
|
c.AMIName = "aa"
|
||||||
|
if err := c.Prepare(nil); err == nil {
|
||||||
|
t.Fatal("shouldn't be able to have an ami name with less than 3 characters")
|
||||||
|
}
|
||||||
|
|
||||||
|
var longAmiName string
|
||||||
|
for i := 0; i < 129; i++ {
|
||||||
|
longAmiName += "a"
|
||||||
|
}
|
||||||
|
c.AMIName = longAmiName
|
||||||
|
if err := c.Prepare(nil); err == nil {
|
||||||
|
t.Fatal("shouldn't be able to have an ami name with great than 128 characters")
|
||||||
|
}
|
||||||
|
|
||||||
|
c.AMIName = "+aaa"
|
||||||
|
if err := c.Prepare(nil); err == nil {
|
||||||
|
t.Fatal("shouldn't be able to have an ami name with invalid characters")
|
||||||
|
}
|
||||||
|
|
||||||
|
c.AMIName = "foo().-/_bar"
|
||||||
|
if err := c.Prepare(nil); err != nil {
|
||||||
|
t.Fatal("expected 'foobar' to be a valid ami name")
|
||||||
|
}
|
||||||
|
|
||||||
|
c.AMIName = `xyz-base-2017-04-05-1934`
|
||||||
|
if err := c.Prepare(nil); err != nil {
|
||||||
|
t.Fatalf("expected `xyz-base-2017-04-05-1934` to pass validation.")
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
|
@ -9,7 +9,7 @@ import (
|
||||||
"github.com/aws/aws-sdk-go/aws"
|
"github.com/aws/aws-sdk-go/aws"
|
||||||
"github.com/aws/aws-sdk-go/aws/session"
|
"github.com/aws/aws-sdk-go/aws/session"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
"github.com/mitchellh/packer/packer"
|
"github.com/hashicorp/packer/packer"
|
||||||
)
|
)
|
||||||
|
|
||||||
// Artifact is an artifact implementation that contains built AMIs.
|
// Artifact is an artifact implementation that contains built AMIs.
|
||||||
|
|
|
@ -4,7 +4,7 @@ import (
|
||||||
"reflect"
|
"reflect"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/mitchellh/packer/packer"
|
"github.com/hashicorp/packer/packer"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestArtifact_Impl(t *testing.T) {
|
func TestArtifact_Impl(t *testing.T) {
|
||||||
|
|
|
@ -5,7 +5,7 @@ import (
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/aws"
|
"github.com/aws/aws-sdk-go/aws"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
"github.com/mitchellh/packer/template/interpolate"
|
"github.com/hashicorp/packer/template/interpolate"
|
||||||
)
|
)
|
||||||
|
|
||||||
// BlockDevice
|
// BlockDevice
|
||||||
|
|
|
@ -7,9 +7,9 @@ import (
|
||||||
"regexp"
|
"regexp"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/mitchellh/packer/common/uuid"
|
"github.com/hashicorp/packer/common/uuid"
|
||||||
"github.com/mitchellh/packer/helper/communicator"
|
"github.com/hashicorp/packer/helper/communicator"
|
||||||
"github.com/mitchellh/packer/template/interpolate"
|
"github.com/hashicorp/packer/template/interpolate"
|
||||||
)
|
)
|
||||||
|
|
||||||
var reShutdownBehavior = regexp.MustCompile("^(stop|terminate)$")
|
var reShutdownBehavior = regexp.MustCompile("^(stop|terminate)$")
|
||||||
|
|
|
@ -6,7 +6,7 @@ import (
|
||||||
"regexp"
|
"regexp"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/mitchellh/packer/helper/communicator"
|
"github.com/hashicorp/packer/helper/communicator"
|
||||||
)
|
)
|
||||||
|
|
||||||
func init() {
|
func init() {
|
||||||
|
|
|
@ -8,8 +8,8 @@ import (
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
packerssh "github.com/hashicorp/packer/communicator/ssh"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
packerssh "github.com/mitchellh/packer/communicator/ssh"
|
|
||||||
"golang.org/x/crypto/ssh"
|
"golang.org/x/crypto/ssh"
|
||||||
"golang.org/x/crypto/ssh/agent"
|
"golang.org/x/crypto/ssh/agent"
|
||||||
)
|
)
|
||||||
|
|
|
@ -8,8 +8,8 @@ import (
|
||||||
"github.com/aws/aws-sdk-go/aws/session"
|
"github.com/aws/aws-sdk-go/aws/session"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type StepAMIRegionCopy struct {
|
type StepAMIRegionCopy struct {
|
||||||
|
|
|
@ -7,10 +7,10 @@ import (
|
||||||
"github.com/aws/aws-sdk-go/aws/awserr"
|
"github.com/aws/aws-sdk-go/aws/awserr"
|
||||||
"github.com/aws/aws-sdk-go/aws/session"
|
"github.com/aws/aws-sdk-go/aws/session"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
retry "github.com/hashicorp/packer/common"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
|
"github.com/hashicorp/packer/template/interpolate"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
retry "github.com/mitchellh/packer/common"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
"github.com/mitchellh/packer/template/interpolate"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type StepCreateTags struct {
|
type StepCreateTags struct {
|
||||||
|
|
|
@ -5,8 +5,8 @@ import (
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/aws"
|
"github.com/aws/aws-sdk-go/aws"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type StepDeregisterAMI struct {
|
type StepDeregisterAMI struct {
|
||||||
|
|
|
@ -6,8 +6,8 @@ import (
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/aws"
|
"github.com/aws/aws-sdk-go/aws"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type StepCreateEncryptedAMICopy struct {
|
type StepCreateEncryptedAMICopy struct {
|
||||||
|
|
|
@ -11,9 +11,9 @@ import (
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
"github.com/hashicorp/packer/helper/communicator"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/helper/communicator"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// StepGetPassword reads the password from a Windows server and sets it
|
// StepGetPassword reads the password from a Windows server and sets it
|
||||||
|
|
|
@ -7,8 +7,8 @@ import (
|
||||||
"runtime"
|
"runtime"
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type StepKeyPair struct {
|
type StepKeyPair struct {
|
||||||
|
|
|
@ -6,9 +6,9 @@ import (
|
||||||
"github.com/aws/aws-sdk-go/aws"
|
"github.com/aws/aws-sdk-go/aws"
|
||||||
"github.com/aws/aws-sdk-go/aws/session"
|
"github.com/aws/aws-sdk-go/aws/session"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
|
"github.com/hashicorp/packer/template/interpolate"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
"github.com/mitchellh/packer/template/interpolate"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type StepModifyAMIAttributes struct {
|
type StepModifyAMIAttributes struct {
|
||||||
|
|
|
@ -5,8 +5,8 @@ import (
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/aws"
|
"github.com/aws/aws-sdk-go/aws"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type StepModifyEBSBackedInstance struct {
|
type StepModifyEBSBackedInstance struct {
|
||||||
|
|
|
@ -5,8 +5,8 @@ import (
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/aws"
|
"github.com/aws/aws-sdk-go/aws"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// StepPreValidate provides an opportunity to pre-validate any configuration for
|
// StepPreValidate provides an opportunity to pre-validate any configuration for
|
||||||
|
|
|
@ -11,9 +11,9 @@ import (
|
||||||
"github.com/aws/aws-sdk-go/aws"
|
"github.com/aws/aws-sdk-go/aws"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
|
"github.com/hashicorp/packer/template/interpolate"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
"github.com/mitchellh/packer/template/interpolate"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type StepRunSourceInstance struct {
|
type StepRunSourceInstance struct {
|
||||||
|
|
|
@ -8,10 +8,10 @@ import (
|
||||||
"github.com/aws/aws-sdk-go/aws"
|
"github.com/aws/aws-sdk-go/aws"
|
||||||
"github.com/aws/aws-sdk-go/private/waiter"
|
"github.com/aws/aws-sdk-go/private/waiter"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
"github.com/hashicorp/packer/common/uuid"
|
||||||
|
"github.com/hashicorp/packer/helper/communicator"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/common/uuid"
|
|
||||||
"github.com/mitchellh/packer/helper/communicator"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type StepSecurityGroup struct {
|
type StepSecurityGroup struct {
|
||||||
|
|
|
@ -7,8 +7,8 @@ import (
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// StepSourceAMIInfo extracts critical information from the source AMI
|
// StepSourceAMIInfo extracts critical information from the source AMI
|
||||||
|
|
|
@ -4,8 +4,8 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type StepStopEBSBackedInstance struct {
|
type StepStopEBSBackedInstance struct {
|
||||||
|
|
|
@ -4,9 +4,9 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
|
"github.com/hashicorp/packer/template/interpolate"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
"github.com/mitchellh/packer/template/interpolate"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type StepTagEBSVolumes struct {
|
type StepTagEBSVolumes struct {
|
||||||
|
|
|
@ -11,13 +11,13 @@ import (
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/aws/session"
|
"github.com/aws/aws-sdk-go/aws/session"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
awscommon "github.com/hashicorp/packer/builder/amazon/common"
|
||||||
|
"github.com/hashicorp/packer/common"
|
||||||
|
"github.com/hashicorp/packer/helper/communicator"
|
||||||
|
"github.com/hashicorp/packer/helper/config"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
|
"github.com/hashicorp/packer/template/interpolate"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
awscommon "github.com/mitchellh/packer/builder/amazon/common"
|
|
||||||
"github.com/mitchellh/packer/common"
|
|
||||||
"github.com/mitchellh/packer/helper/communicator"
|
|
||||||
"github.com/mitchellh/packer/helper/config"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
"github.com/mitchellh/packer/template/interpolate"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// The unique ID for this builder
|
// The unique ID for this builder
|
||||||
|
|
|
@ -8,9 +8,9 @@ import (
|
||||||
"github.com/aws/aws-sdk-go/aws"
|
"github.com/aws/aws-sdk-go/aws"
|
||||||
"github.com/aws/aws-sdk-go/aws/session"
|
"github.com/aws/aws-sdk-go/aws/session"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
"github.com/mitchellh/packer/builder/amazon/common"
|
"github.com/hashicorp/packer/builder/amazon/common"
|
||||||
builderT "github.com/mitchellh/packer/helper/builder/testing"
|
builderT "github.com/hashicorp/packer/helper/builder/testing"
|
||||||
"github.com/mitchellh/packer/packer"
|
"github.com/hashicorp/packer/packer"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestBuilderAcc_basic(t *testing.T) {
|
func TestBuilderAcc_basic(t *testing.T) {
|
||||||
|
|
|
@ -3,7 +3,7 @@ package ebs
|
||||||
import (
|
import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/mitchellh/packer/packer"
|
"github.com/hashicorp/packer/packer"
|
||||||
)
|
)
|
||||||
|
|
||||||
func testConfig() map[string]interface{} {
|
func testConfig() map[string]interface{} {
|
||||||
|
|
|
@ -5,9 +5,9 @@ import (
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/aws"
|
"github.com/aws/aws-sdk-go/aws"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
"github.com/hashicorp/packer/builder/amazon/common"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/builder/amazon/common"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// stepCleanupVolumes cleans up any orphaned volumes that were not designated to
|
// stepCleanupVolumes cleans up any orphaned volumes that were not designated to
|
||||||
|
|
|
@ -4,9 +4,9 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
awscommon "github.com/hashicorp/packer/builder/amazon/common"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
awscommon "github.com/mitchellh/packer/builder/amazon/common"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type stepCreateAMI struct {
|
type stepCreateAMI struct {
|
||||||
|
|
|
@ -7,9 +7,9 @@ import (
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/aws"
|
"github.com/aws/aws-sdk-go/aws"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
"github.com/mitchellh/packer/builder/amazon/common"
|
"github.com/hashicorp/packer/builder/amazon/common"
|
||||||
builderT "github.com/mitchellh/packer/helper/builder/testing"
|
builderT "github.com/hashicorp/packer/helper/builder/testing"
|
||||||
"github.com/mitchellh/packer/packer"
|
"github.com/hashicorp/packer/packer"
|
||||||
)
|
)
|
||||||
|
|
||||||
type TFBuilder struct {
|
type TFBuilder struct {
|
||||||
|
|
|
@ -10,13 +10,13 @@ import (
|
||||||
"github.com/aws/aws-sdk-go/aws/session"
|
"github.com/aws/aws-sdk-go/aws/session"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
"github.com/hashicorp/errwrap"
|
"github.com/hashicorp/errwrap"
|
||||||
|
awscommon "github.com/hashicorp/packer/builder/amazon/common"
|
||||||
|
"github.com/hashicorp/packer/common"
|
||||||
|
"github.com/hashicorp/packer/helper/communicator"
|
||||||
|
"github.com/hashicorp/packer/helper/config"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
|
"github.com/hashicorp/packer/template/interpolate"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
awscommon "github.com/mitchellh/packer/builder/amazon/common"
|
|
||||||
"github.com/mitchellh/packer/common"
|
|
||||||
"github.com/mitchellh/packer/helper/communicator"
|
|
||||||
"github.com/mitchellh/packer/helper/config"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
"github.com/mitchellh/packer/template/interpolate"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
const BuilderId = "mitchellh.amazon.ebssurrogate"
|
const BuilderId = "mitchellh.amazon.ebssurrogate"
|
||||||
|
|
|
@ -3,7 +3,7 @@ package ebssurrogate
|
||||||
import (
|
import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/mitchellh/packer/packer"
|
"github.com/hashicorp/packer/packer"
|
||||||
)
|
)
|
||||||
|
|
||||||
func testConfig() map[string]interface{} {
|
func testConfig() map[string]interface{} {
|
||||||
|
|
|
@ -4,7 +4,7 @@ import (
|
||||||
"errors"
|
"errors"
|
||||||
"github.com/aws/aws-sdk-go/aws"
|
"github.com/aws/aws-sdk-go/aws"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
"github.com/mitchellh/packer/template/interpolate"
|
"github.com/hashicorp/packer/template/interpolate"
|
||||||
)
|
)
|
||||||
|
|
||||||
type RootBlockDevice struct {
|
type RootBlockDevice struct {
|
||||||
|
|
|
@ -5,9 +5,9 @@ import (
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/aws"
|
"github.com/aws/aws-sdk-go/aws"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
awscommon "github.com/hashicorp/packer/builder/amazon/common"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
awscommon "github.com/mitchellh/packer/builder/amazon/common"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// StepRegisterAMI creates the AMI.
|
// StepRegisterAMI creates the AMI.
|
||||||
|
|
|
@ -6,9 +6,9 @@ import (
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
awscommon "github.com/hashicorp/packer/builder/amazon/common"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
awscommon "github.com/mitchellh/packer/builder/amazon/common"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// StepSnapshotNewRootVolume creates a snapshot of the created volume.
|
// StepSnapshotNewRootVolume creates a snapshot of the created volume.
|
||||||
|
|
|
@ -7,7 +7,7 @@ import (
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
"github.com/mitchellh/packer/packer"
|
"github.com/hashicorp/packer/packer"
|
||||||
)
|
)
|
||||||
|
|
||||||
// map of region to list of volume IDs
|
// map of region to list of volume IDs
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
package ebsvolume
|
package ebsvolume
|
||||||
|
|
||||||
import (
|
import (
|
||||||
awscommon "github.com/mitchellh/packer/builder/amazon/common"
|
awscommon "github.com/hashicorp/packer/builder/amazon/common"
|
||||||
"github.com/mitchellh/packer/template/interpolate"
|
"github.com/hashicorp/packer/template/interpolate"
|
||||||
)
|
)
|
||||||
|
|
||||||
type BlockDevice struct {
|
type BlockDevice struct {
|
||||||
|
|
|
@ -9,13 +9,13 @@ import (
|
||||||
"github.com/aws/aws-sdk-go/aws/session"
|
"github.com/aws/aws-sdk-go/aws/session"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
"github.com/hashicorp/errwrap"
|
"github.com/hashicorp/errwrap"
|
||||||
|
awscommon "github.com/hashicorp/packer/builder/amazon/common"
|
||||||
|
"github.com/hashicorp/packer/common"
|
||||||
|
"github.com/hashicorp/packer/helper/communicator"
|
||||||
|
"github.com/hashicorp/packer/helper/config"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
|
"github.com/hashicorp/packer/template/interpolate"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
awscommon "github.com/mitchellh/packer/builder/amazon/common"
|
|
||||||
"github.com/mitchellh/packer/common"
|
|
||||||
"github.com/mitchellh/packer/helper/communicator"
|
|
||||||
"github.com/mitchellh/packer/helper/config"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
"github.com/mitchellh/packer/template/interpolate"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
const BuilderId = "mitchellh.amazon.ebsvolume"
|
const BuilderId = "mitchellh.amazon.ebsvolume"
|
||||||
|
|
|
@ -3,7 +3,7 @@ package ebsvolume
|
||||||
import (
|
import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/mitchellh/packer/packer"
|
"github.com/hashicorp/packer/packer"
|
||||||
)
|
)
|
||||||
|
|
||||||
func testConfig() map[string]interface{} {
|
func testConfig() map[string]interface{} {
|
||||||
|
|
|
@ -4,10 +4,10 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
awscommon "github.com/hashicorp/packer/builder/amazon/common"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
|
"github.com/hashicorp/packer/template/interpolate"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
awscommon "github.com/mitchellh/packer/builder/amazon/common"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
"github.com/mitchellh/packer/template/interpolate"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type stepTagEBSVolumes struct {
|
type stepTagEBSVolumes struct {
|
||||||
|
|
|
@ -11,13 +11,13 @@ import (
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/aws/session"
|
"github.com/aws/aws-sdk-go/aws/session"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
awscommon "github.com/hashicorp/packer/builder/amazon/common"
|
||||||
|
"github.com/hashicorp/packer/common"
|
||||||
|
"github.com/hashicorp/packer/helper/communicator"
|
||||||
|
"github.com/hashicorp/packer/helper/config"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
|
"github.com/hashicorp/packer/template/interpolate"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
awscommon "github.com/mitchellh/packer/builder/amazon/common"
|
|
||||||
"github.com/mitchellh/packer/common"
|
|
||||||
"github.com/mitchellh/packer/helper/communicator"
|
|
||||||
"github.com/mitchellh/packer/helper/config"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
"github.com/mitchellh/packer/template/interpolate"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// The unique ID for this builder
|
// The unique ID for this builder
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
package instance
|
package instance
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/mitchellh/packer/packer"
|
"github.com/hashicorp/packer/packer"
|
||||||
"io/ioutil"
|
"io/ioutil"
|
||||||
"os"
|
"os"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
|
@ -4,9 +4,9 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
|
"github.com/hashicorp/packer/template/interpolate"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
"github.com/mitchellh/packer/template/interpolate"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type bundleCmdData struct {
|
type bundleCmdData struct {
|
||||||
|
|
|
@ -5,9 +5,9 @@ import (
|
||||||
|
|
||||||
"github.com/aws/aws-sdk-go/aws"
|
"github.com/aws/aws-sdk-go/aws"
|
||||||
"github.com/aws/aws-sdk-go/service/ec2"
|
"github.com/aws/aws-sdk-go/service/ec2"
|
||||||
|
awscommon "github.com/hashicorp/packer/builder/amazon/common"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
awscommon "github.com/mitchellh/packer/builder/amazon/common"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type StepRegisterAMI struct{}
|
type StepRegisterAMI struct{}
|
||||||
|
|
|
@ -3,9 +3,9 @@ package instance
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
|
"github.com/hashicorp/packer/template/interpolate"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
"github.com/mitchellh/packer/template/interpolate"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type uploadCmdData struct {
|
type uploadCmdData struct {
|
||||||
|
|
|
@ -2,8 +2,8 @@ package instance
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
"os"
|
"os"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -19,8 +19,8 @@ import (
|
||||||
"github.com/Azure/azure-sdk-for-go/storage"
|
"github.com/Azure/azure-sdk-for-go/storage"
|
||||||
"github.com/Azure/go-autorest/autorest"
|
"github.com/Azure/go-autorest/autorest"
|
||||||
"github.com/Azure/go-autorest/autorest/azure"
|
"github.com/Azure/go-autorest/autorest/azure"
|
||||||
"github.com/mitchellh/packer/builder/azure/common"
|
"github.com/hashicorp/packer/builder/azure/common"
|
||||||
"github.com/mitchellh/packer/version"
|
"github.com/hashicorp/packer/version"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|
|
@ -10,17 +10,17 @@ import (
|
||||||
"strings"
|
"strings"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
packerAzureCommon "github.com/mitchellh/packer/builder/azure/common"
|
packerAzureCommon "github.com/hashicorp/packer/builder/azure/common"
|
||||||
|
|
||||||
"github.com/Azure/go-autorest/autorest/azure"
|
"github.com/Azure/go-autorest/autorest/azure"
|
||||||
|
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
"github.com/mitchellh/packer/builder/azure/common/lin"
|
"github.com/hashicorp/packer/builder/azure/common/lin"
|
||||||
|
|
||||||
|
packerCommon "github.com/hashicorp/packer/common"
|
||||||
|
"github.com/hashicorp/packer/helper/communicator"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
packerCommon "github.com/mitchellh/packer/common"
|
|
||||||
"github.com/mitchellh/packer/helper/communicator"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type Builder struct {
|
type Builder struct {
|
||||||
|
|
|
@ -6,7 +6,7 @@ package arm
|
||||||
import (
|
import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestStateBagShouldBePopulatedExpectedValues(t *testing.T) {
|
func TestStateBagShouldBePopulatedExpectedValues(t *testing.T) {
|
||||||
|
|
|
@ -22,13 +22,13 @@ import (
|
||||||
"github.com/Azure/go-autorest/autorest/to"
|
"github.com/Azure/go-autorest/autorest/to"
|
||||||
"github.com/masterzen/winrm"
|
"github.com/masterzen/winrm"
|
||||||
|
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
"github.com/mitchellh/packer/builder/azure/pkcs12"
|
"github.com/hashicorp/packer/builder/azure/pkcs12"
|
||||||
"github.com/mitchellh/packer/common"
|
"github.com/hashicorp/packer/common"
|
||||||
"github.com/mitchellh/packer/helper/communicator"
|
"github.com/hashicorp/packer/helper/communicator"
|
||||||
"github.com/mitchellh/packer/helper/config"
|
"github.com/hashicorp/packer/helper/config"
|
||||||
"github.com/mitchellh/packer/packer"
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/packer/template/interpolate"
|
"github.com/hashicorp/packer/template/interpolate"
|
||||||
|
|
||||||
"golang.org/x/crypto/ssh"
|
"golang.org/x/crypto/ssh"
|
||||||
)
|
)
|
||||||
|
|
|
@ -9,7 +9,7 @@ package arm
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/Azure/go-autorest/autorest/azure"
|
"github.com/Azure/go-autorest/autorest/azure"
|
||||||
"github.com/mitchellh/packer/builder/azure/common"
|
"github.com/hashicorp/packer/builder/azure/common"
|
||||||
)
|
)
|
||||||
|
|
||||||
type configRetriever struct {
|
type configRetriever struct {
|
||||||
|
|
|
@ -9,8 +9,8 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
"github.com/mitchellh/packer/packer"
|
"github.com/hashicorp/packer/packer"
|
||||||
)
|
)
|
||||||
|
|
||||||
// List of configuration parameters that are required by the ARM builder.
|
// List of configuration parameters that are required by the ARM builder.
|
||||||
|
|
|
@ -8,7 +8,7 @@ import (
|
||||||
|
|
||||||
"github.com/Azure/go-autorest/autorest"
|
"github.com/Azure/go-autorest/autorest"
|
||||||
"github.com/Azure/go-autorest/autorest/azure"
|
"github.com/Azure/go-autorest/autorest/azure"
|
||||||
"github.com/mitchellh/packer/builder/azure/common/logutil"
|
"github.com/hashicorp/packer/builder/azure/common/logutil"
|
||||||
"io"
|
"io"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -4,9 +4,9 @@
|
||||||
package arm
|
package arm
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common"
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/builder/azure/common"
|
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
func processInterruptibleResult(
|
func processInterruptibleResult(
|
||||||
|
|
|
@ -7,10 +7,10 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/Azure/azure-sdk-for-go/arm/compute"
|
"github.com/Azure/azure-sdk-for-go/arm/compute"
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common"
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/builder/azure/common"
|
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type StepCaptureImage struct {
|
type StepCaptureImage struct {
|
||||||
|
|
|
@ -8,8 +8,8 @@ import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
"github.com/Azure/azure-sdk-for-go/arm/compute"
|
"github.com/Azure/azure-sdk-for-go/arm/compute"
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestStepCaptureImageShouldFailIfCaptureFails(t *testing.T) {
|
func TestStepCaptureImageShouldFailIfCaptureFails(t *testing.T) {
|
||||||
|
|
|
@ -7,9 +7,9 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
"github.com/Azure/azure-sdk-for-go/arm/resources/resources"
|
"github.com/Azure/azure-sdk-for-go/arm/resources/resources"
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type StepCreateResourceGroup struct {
|
type StepCreateResourceGroup struct {
|
||||||
|
|
|
@ -7,8 +7,8 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestStepCreateResourceGroupShouldFailIfCreateFails(t *testing.T) {
|
func TestStepCreateResourceGroupShouldFailIfCreateFails(t *testing.T) {
|
||||||
|
|
|
@ -8,10 +8,10 @@ import (
|
||||||
"net/url"
|
"net/url"
|
||||||
"strings"
|
"strings"
|
||||||
|
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
|
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type StepDeleteOSDisk struct {
|
type StepDeleteOSDisk struct {
|
||||||
|
|
|
@ -7,8 +7,8 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestStepDeleteOSDiskShouldFailIfGetFails(t *testing.T) {
|
func TestStepDeleteOSDiskShouldFailIfGetFails(t *testing.T) {
|
||||||
|
|
|
@ -6,10 +6,10 @@ package arm
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common"
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/builder/azure/common"
|
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type StepDeleteResourceGroup struct {
|
type StepDeleteResourceGroup struct {
|
||||||
|
|
|
@ -7,8 +7,8 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestStepDeleteResourceGroupShouldFailIfDeleteFails(t *testing.T) {
|
func TestStepDeleteResourceGroupShouldFailIfDeleteFails(t *testing.T) {
|
||||||
|
|
|
@ -6,10 +6,10 @@ package arm
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common"
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/builder/azure/common"
|
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type StepDeployTemplate struct {
|
type StepDeployTemplate struct {
|
||||||
|
|
|
@ -7,8 +7,8 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestStepDeployTemplateShouldFailIfDeployFails(t *testing.T) {
|
func TestStepDeployTemplateShouldFailIfDeployFails(t *testing.T) {
|
||||||
|
|
|
@ -7,9 +7,9 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type StepGetCertificate struct {
|
type StepGetCertificate struct {
|
||||||
|
|
|
@ -7,8 +7,8 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestStepGetCertificateShouldFailIfGetFails(t *testing.T) {
|
func TestStepGetCertificateShouldFailIfGetFails(t *testing.T) {
|
||||||
|
|
|
@ -6,9 +6,9 @@ package arm
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type EndpointType int
|
type EndpointType int
|
||||||
|
|
|
@ -7,8 +7,8 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestStepGetIPAddressShouldFailIfGetFails(t *testing.T) {
|
func TestStepGetIPAddressShouldFailIfGetFails(t *testing.T) {
|
||||||
|
|
|
@ -8,10 +8,10 @@ import (
|
||||||
|
|
||||||
"github.com/Azure/azure-sdk-for-go/arm/compute"
|
"github.com/Azure/azure-sdk-for-go/arm/compute"
|
||||||
|
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
|
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type StepGetOSDisk struct {
|
type StepGetOSDisk struct {
|
||||||
|
|
|
@ -9,7 +9,7 @@ import (
|
||||||
|
|
||||||
"github.com/Azure/azure-sdk-for-go/arm/compute"
|
"github.com/Azure/azure-sdk-for-go/arm/compute"
|
||||||
|
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
|
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
)
|
)
|
||||||
|
|
|
@ -6,10 +6,10 @@ package arm
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common"
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/builder/azure/common"
|
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type StepPowerOffCompute struct {
|
type StepPowerOffCompute struct {
|
||||||
|
|
|
@ -7,8 +7,8 @@ import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestStepPowerOffComputeShouldFailIfPowerOffFails(t *testing.T) {
|
func TestStepPowerOffComputeShouldFailIfPowerOffFails(t *testing.T) {
|
||||||
|
|
|
@ -4,9 +4,9 @@
|
||||||
package arm
|
package arm
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
|
"github.com/hashicorp/packer/packer"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
|
||||||
"github.com/mitchellh/packer/packer"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type StepSetCertificate struct {
|
type StepSetCertificate struct {
|
||||||
|
|
|
@ -6,8 +6,8 @@ package arm
|
||||||
import (
|
import (
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestStepSetCertificateShouldPassIfGetPasses(t *testing.T) {
|
func TestStepSetCertificateShouldPassIfGetPasses(t *testing.T) {
|
||||||
|
|
|
@ -5,9 +5,9 @@ package arm
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common"
|
||||||
|
"github.com/hashicorp/packer/builder/azure/common/constants"
|
||||||
"github.com/mitchellh/multistep"
|
"github.com/mitchellh/multistep"
|
||||||
"github.com/mitchellh/packer/builder/azure/common"
|
|
||||||
"github.com/mitchellh/packer/builder/azure/common/constants"
|
|
||||||
"testing"
|
"testing"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue