Skip to content

Commit

Permalink
Merge pull request #61 from danitso/release-0.4.0
Browse files Browse the repository at this point in the history
Release 0.4.0
  • Loading branch information
danitso-dp authored Feb 10, 2021
2 parents eb06704 + f8aaed1 commit a7b53dc
Show file tree
Hide file tree
Showing 118 changed files with 3,109 additions and 659 deletions.
61 changes: 61 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
name: Create release
on:
push:
tags:
- 'v*'
jobs:
release:
name: Tag
runs-on: ubuntu-20.04
steps:
-
name: Checkout the code
uses: actions/checkout@v2
with:
fetch-depth: 0
-
name: Install and configure Go
uses: actions/setup-go@v2
with:
go-version: 1.15
-
name: Install and configure GoReleaser
env:
GORELEASER_VERSION: '0.155.1'
run: |
curl -sL -o goreleaser_amd64.deb "https://github.com/goreleaser/goreleaser/releases/download/v${GORELEASER_VERSION}/goreleaser_amd64.deb"
sudo dpkg -i goreleaser_amd64.deb
rm -f goreleaser_amd64.deb
-
name: Import the GPG signing key
env:
GPG_KEY: ${{ secrets.GPG_KEY }}
GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}
run: |
mkdir -p ~/.gnupg
chmod 0700 ~/.gnupg
cat << EOF > ~/.gnupg/gpg.conf
use-agent
pinentry-mode loopback
EOF
echo "$GPG_KEY" | base64 -d | gpg --batch --allow-secret-key-import --import
gpg --keyid-format LONG --list-secret-keys
cat << EOF > ~/.gnupg/gpg-agent.conf
default-cache-ttl 7200
max-cache-ttl 31536000
allow-loopback-pinentry
allow-preset-passphrase
EOF
echo RELOADAGENT | gpg-connect-agent
printf '%s' "$GPG_PASSPHRASE" > ./.gpg_passphrase
-
name: Create release
env:
GPG_FINGERPRINT: ${{ secrets.GPG_FINGERPRINT }}
run: |
goreleaser build --parallelism 2 --rm-dist --timeout 1h
34 changes: 34 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Test changes
on:
pull_request:
branches:
- main
- master
- 'v*'
jobs:
test:
name: Pull Request
runs-on: ubuntu-20.04
steps:
-
name: Checkout the code
uses: actions/checkout@v2
with:
fetch-depth: 0
-
name: Install and configure Go
uses: actions/setup-go@v2
with:
go-version: 1.15
-
name: Install and configure GoReleaser
env:
GORELEASER_VERSION: '0.155.1'
run: |
curl -sL -o goreleaser_amd64.deb "https://github.com/goreleaser/goreleaser/releases/download/v${GORELEASER_VERSION}/goreleaser_amd64.deb"
sudo dpkg -i goreleaser_amd64.deb
rm -f goreleaser_amd64.deb
-
name: Create snapshot
run: |
goreleaser build --config .goreleaser.test.yml --parallelism 2 --rm-dist --snapshot --timeout 1h
37 changes: 37 additions & 0 deletions .goreleaser.test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
before:
hooks:
- go mod tidy
builds:
- env:
- CGO_ENABLED=0
mod_timestamp: '{{ .CommitTimestamp }}'
flags:
- -trimpath
ldflags:
- '-s -w -X main.version={{.Version}} -X main.commit={{.Commit}}'
goos:
- freebsd
- windows
- linux
- darwin
goarch:
- amd64
- '386'
- arm
- arm64
ignore:
- goos: darwin
goarch: '386'
binary: '{{ .ProjectName }}_v{{ .Version }}'
archives:
- format: zip
name_template: '{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}'
checksum:
name_template: '{{ .ProjectName }}_{{ .Version }}_SHA256SUMS'
algorithm: sha256
signs:
- artifacts: none
release:
draft: false
changelog:
skip: true
48 changes: 48 additions & 0 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
before:
hooks:
- go mod tidy
builds:
- env:
- CGO_ENABLED=0
mod_timestamp: '{{ .CommitTimestamp }}'
flags:
- -trimpath
ldflags:
- '-s -w -X main.version={{.Version}} -X main.commit={{.Commit}}'
goos:
- freebsd
- windows
- linux
- darwin
goarch:
- amd64
- '386'
- arm
- arm64
ignore:
- goos: darwin
goarch: '386'
binary: '{{ .ProjectName }}_v{{ .Version }}'
archives:
- format: zip
name_template: '{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}'
checksum:
name_template: '{{ .ProjectName }}_{{ .Version }}_SHA256SUMS'
algorithm: sha256
signs:
- artifacts: checksum
args:
- "--batch"
- "--local-user"
- "{{ .Env.GPG_FINGERPRINT }}"
- "--output"
- "${signature}"
- "--passphrase-fd"
- "0"
- "--detach-sign"
- "${artifact}"
stdin_file: ./.gpg_passphrase
release:
draft: false
changelog:
skip: true
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ cache:
- $HOME/gopath/pkg/mod

go:
- 1.13.x
- 1.15.x

git:
depth: 1
Expand Down
21 changes: 20 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,17 +1,36 @@
## 0.4.0 (UNRELEASED)
## v0.4.0

FEATURES:

* **New Data Source:** `proxmox_virtual_environment_time`
* **New Resource:** `proxmox_virtual_environment_time`

BREAKING CHANGES:

* resource/virtual_environment_vm: `interface` is now required to create disks

```
disk {
datastore_id = "local-lvm"
file_id = "${proxmox_virtual_environment_file.ubuntu_cloud_image.id}"
interface = "scsi0"
}
```

ENHANCEMENTS:

* provider/configuration: Add `virtual_environment.otp` argument for TOTP support
* resource/virtual_environment_vm: Clone supports resize and datastore_id for moving disks
* resource/virtual_environment_vm: Bulk clones can now use retries as argument to try multiple times to create a clone.
* resource/virtual_environment_vm: `on_boot` parameter can be used to start a VM after the Node has been rebooted.
* resource/virtual_environment_vm: `reboot` parameter can be used to reboot a VM after creation
* resource/virtual_environment_vm: Has now multiple new parameters to set timeouts for the vm creation/cloning `timeout_clone`, `timeout_move_disk`, `timeout_reboot`, `timeout_shutdown_vm`, `timeout_start_vm`, `timeout_stop_vm`

BUG FIXES:

* library/virtual_environment_nodes: Fix node IP address format
* library/virtual_environment_nodes: Fix WaitForNodeTask now detects errors correctly
* library/virtual_environment_vm: Fix CloneVM now waits for the task to be finished and detect errors.
* resource/virtual_environment_container: Fix VM ID collision when `vm_id` is not specified
* resource/virtual_environment_vm: Fix VM ID collision when `vm_id` is not specified
* resource/virtual_environment_vm: Fix disk import issue when importing from directory-based datastores
Expand Down
29 changes: 29 additions & 0 deletions docs/data-sources/alias.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
---
layout: page
title: Alias
permalink: /data-sources/alias
nav_order: 1
parent: Data Sources
subcategory: Virtual Environment
---

# Data Source: Alias

Retrieves information about a specific alias.

## Example Usage

```
data "proxmox_virtual_environment_cluster_alias" "local_network" {
name = "local_network"
}
```

## Argument Reference

* `name` - (Required) Alias name.

## Attribute Reference

* `cidr` - (Required) Network/IP specification in CIDR format.
* `comment` - (Optional) Alias comment.
26 changes: 26 additions & 0 deletions docs/data-sources/aliases.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
---
layout: page
title: Aliases
permalink: /data-sources/aliases
nav_order: 2
parent: Data Sources
subcategory: Virtual Environment
---

# Data Source: Aliases

Retrieves the identifiers for all the available aliases.

## Example Usage

```
data "proxmox_virtual_environment_cluster_aliases" "available_aliases" {}
```

## Argument Reference

There are no arguments available for this data source.

## Attribute Reference

* `alias_ids` - The pool identifiers.
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
---
layout: page
title: Datastores
permalink: /data-sources/virtual-environment/datastores
nav_order: 1
parent: Virtual Environment Data Sources
grand_parent: Data Sources
permalink: /data-sources/datastores
nav_order: 3
parent: Data Sources
subcategory: Virtual Environment
---

# Data Source: Datastores
Expand All @@ -19,11 +19,11 @@ data "proxmox_virtual_environment_datastores" "first_node" {
}
```

## Arguments Reference
## Argument Reference

* `node_name` - (Required) A node name.

## Attributes Reference
## Attribute Reference

* `active` - Whether the datastore is active.
* `content_types` - The allowed content types.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
---
layout: page
title: DNS
permalink: /data-sources/virtual-environment/dns
nav_order: 2
parent: Virtual Environment Data Sources
grand_parent: Data Sources
permalink: /data-sources/dns
nav_order: 4
parent: Data Sources
subcategory: Virtual Environment
---

# Data Source: DNS
Expand All @@ -19,11 +19,11 @@ data "proxmox_virtual_environment_dns" "first_node" {
}
```

## Arguments Reference
## Argument Reference

* `node_name` - (Required) A node name.

## Attributes Reference
## Attribute Reference

* `domain` - The DNS search domain.
* `servers` - The DNS servers.
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
---
layout: page
title: Group
permalink: /data-sources/virtual-environment/group
nav_order: 3
parent: Virtual Environment Data Sources
grand_parent: Data Sources
permalink: /data-sources/group
nav_order: 5
parent: Data Sources
subcategory: Virtual Environment
---

# Data Source: Group
Expand All @@ -19,11 +19,11 @@ data "proxmox_virtual_environment_group" "operations_team" {
}
```

## Arguments Reference
## Argument Reference

* `group_id` - (Required) The group identifier.

## Attributes Reference
## Attribute Reference

* `acl` - The access control list.
* `path` - The path.
Expand Down
Loading

0 comments on commit a7b53dc

Please sign in to comment.