Skip to content

Commit

Permalink
Merge pull request #1709 from linode/dev
Browse files Browse the repository at this point in the history
Release v2.32.0
  • Loading branch information
lgarber-akamai authored Jan 10, 2025
2 parents a2484da + 132c968 commit 733403f
Show file tree
Hide file tree
Showing 73 changed files with 2,619 additions and 766 deletions.
38 changes: 38 additions & 0 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: "CodeQL Advanced"

on:
push:
branches: [ "dev", "main", "proj/*" ]
pull_request:
branches: [ "dev", "main", "proj/*" ]
schedule:
- cron: '39 0 * * 6'

jobs:
analyze:
name: Analyze (${{ matrix.language }})
runs-on: ubuntu-latest
permissions:
security-events: write

strategy:
fail-fast: false
matrix:
include:
- language: go
build-mode: autobuild
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
languages: ${{ matrix.language }}
build-mode: ${{ matrix.build-mode }}
queries: security-and-quality

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3
with:
category: "/language:${{matrix.language}}"
16 changes: 0 additions & 16 deletions .github/workflows/gosec_pr.yml

This file was deleted.

84 changes: 28 additions & 56 deletions .github/workflows/nightly_smoke_tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,62 +41,34 @@ jobs:
LINODE_TOKEN: ${{ secrets.DX_LINODE_TOKEN }}

- name: Notify Slack
if: always()
if: always() && github.repository == 'linode/terraform-provider-linode'
uses: slackapi/[email protected]
with:
channel-id: ${{ secrets.SLACK_CHANNEL_ID }}
method: chat.postMessage
token: ${{ secrets.SLACK_BOT_TOKEN }}
payload: |
{
"blocks": [
{
"type": "section",
"text": {
"type": "mrkdwn",
"text": ":rocket: *${{ github.workflow }} Completed in: ${{ github.repository }}* :white_check_mark:"
}
},
{
"type": "divider"
},
{
"type": "section",
"fields": [
{
"type": "mrkdwn",
"text": "*Build Result:*\n${{ steps.smoke_tests.outcome == 'success' && ':large_green_circle: Build Passed' || ':red_circle: Build Failed' }}"
},
{
"type": "mrkdwn",
"text": "*Branch:*\n`${{ github.ref_name }}`"
}
]
},
{
"type": "section",
"fields": [
{
"type": "mrkdwn",
"text": "*Commit Hash:*\n<${{ github.server_url }}/${{ github.repository }}/commit/${{ github.sha }}|${{ github.sha }}>"
},
{
"type": "mrkdwn",
"text": "*Run URL:*\n<${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}|View Run Details>"
}
]
},
{
"type": "divider"
},
{
"type": "context",
"elements": [
{
"type": "mrkdwn",
"text": "Triggered by: :bust_in_silhouette: `${{ github.actor }}`"
}
]
}
]
}
env:
SLACK_BOT_TOKEN: ${{ secrets.SLACK_BOT_TOKEN }}
channel: ${{ secrets.SLACK_CHANNEL_ID }}
blocks:
- type: section
text:
type: mrkdwn
text: ":rocket: *${{ github.workflow }} Completed in: ${{ github.repository }}* :white_check_mark:"
- type: divider
- type: section
fields:
- type: mrkdwn
text: "*Build Result:*\n${{ steps.smoke_tests.outcome == 'success' && ':large_green_circle: Build Passed' || ':red_circle: Build Failed' }}"
- type: mrkdwn
text: "*Branch:*\n`${{ github.ref_name }}`"
- type: section
fields:
- type: mrkdwn
text: "*Commit Hash:*\n<${{ github.server_url }}/${{ github.repository }}/commit/${{ github.sha }}|${{ github.sha }}>"
- type: mrkdwn
text: "*Run URL:*\n<${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}|View Run Details>"
- type: divider
- type: context
elements:
- type: mrkdwn
text: "Triggered by: :bust_in_silhouette: `${{ github.actor }}`"
27 changes: 26 additions & 1 deletion .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Pull Request
name: CI for Pull Requests
on: pull_request
jobs:
tests:
Expand All @@ -22,3 +22,28 @@ jobs:
run: go mod tidy
- name: Fail if changes
run: git diff-index --exit-code HEAD

dependency-review:
permissions:
contents: read
pull-requests: write
runs-on: ubuntu-latest
steps:
- name: 'Checkout repository'
uses: actions/checkout@v4
- name: 'Dependency Review'
uses: actions/dependency-review-action@v4
with:
comment-summary-in-pr: on-failure

gosec_scan:
runs-on: ubuntu-latest
env:
GO111MODULE: on
steps:
- name: Checkout Source
uses: actions/checkout@v4
- name: Run Gosec Security Scanner
uses: securego/gosec@master
with:
args: -exclude=G104 ./...
2 changes: 1 addition & 1 deletion .github/workflows/unit-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Unit Tests
on:
workflow_dispatch: null
push:
pull_request:

jobs:
unit_tests:
runs-on: ubuntu-latest
Expand Down
8 changes: 4 additions & 4 deletions docs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,17 +84,17 @@ This section outlines commonly used provider configuration options.

The Linode API CA file path can also be specified using the `LINODE_CA` environment variable.

* `obj_access_key` - (Optional) The access key to be used in [linode_object_storage_bucket](/docs/resources/object_storage_bucket.md) and [linode_object_storage_object](/docs/resources/object_storage_object.md).
* `obj_access_key` - (Optional) The access key to be used in [linode_object_storage_bucket](resources/object_storage_bucket.md) and [linode_object_storage_object](resources/object_storage_object.md).

The Object Access Key can also be specified using the `LINODE_OBJ_ACCESS_KEY` shell environment variable.

* `obj_secret_key` - (Optional) The secret key to be used in [linode_object_storage_bucket](/docs/resources/object_storage_bucket.md) and [linode_object_storage_object](/docs/resources/object_storage_object.md).
* `obj_secret_key` - (Optional) The secret key to be used in [linode_object_storage_bucket](resources/object_storage_bucket.md) and [linode_object_storage_object](resources/object_storage_object.md).

The Object Secret Key can also be specified using the `LINODE_OBJ_SECRET_KEY` shell environment variable.

* `obj_use_temp_keys` - (Optional) If true, temporary object keys will be created implicitly at apply-time for the [linode_object_storage_bucket](/docs/resources/object_storage_bucket.md) and [linode_object_storage_object](/docs/resources/object_storage_object.md) resource to use.
* `obj_use_temp_keys` - (Optional) If true, temporary object keys will be created implicitly at apply-time for the [linode_object_storage_bucket](resources/object_storage_bucket.md) and [linode_object_storage_object](resources/object_storage_object.md) resource to use.

* `obj_bucket_force_delete` - (Optional) If true, all objects and versions will purged from a [linode_object_storage_bucket](/docs/resources/object_storage_bucket.md) before it is destroyed.
* `obj_bucket_force_delete` - (Optional) If true, all objects and versions will purged from a [linode_object_storage_bucket](resources/object_storage_bucket.md) before it is destroyed.

* `skip_instance_ready_poll` - (Optional) Skip waiting for a linode_instance resource to be running.

Expand Down
3 changes: 1 addition & 2 deletions docs/resources/image.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,6 @@ resource "linode_image" "foobar" {
file_path = "path/to/image.img.gz"
file_hash = filemd5("path/to/image.img.gz")
// Note: Image replication may not be available to all users.
replica_regions = ["us-southeast", "us-east", "eu-west"]
}
```
Expand All @@ -78,7 +77,7 @@ The following arguments are supported:

* `tags` - (Optional) A list of customized tags.

* `replica_regions` - (Optional) A list of regions that customer wants to replicate this image in. At least one valid region is required and only core regions allowed. Existing images in the regions not passed will be removed. **Note:** Image replication may not be available to all users. See Replicate an Image [here](https://techdocs.akamai.com/linode-api/reference/post-replicate-image) for more details.
* `replica_regions` - (Optional) A list of regions that customer wants to replicate this image in. At least one valid region is required and only core regions allowed. Existing images in the regions not passed will be removed. See Replicate an Image [here](https://techdocs.akamai.com/linode-api/reference/post-replicate-image) for more details.

* `wait_for_replications` - (Optional) Whether to wait for all image replications become `available`. Default to false.

Expand Down
6 changes: 3 additions & 3 deletions docs/resources/object_storage_bucket.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ resource "linode_object_storage_bucket" "mybucket" {
access_key = linode_object_storage_key.mykey.access_key
secret_key = linode_object_storage_key.mykey.secret_key
cluster = "us-east-1"
region = "us-mia"
label = "mybucket"
lifecycle_rule {
Expand All @@ -63,7 +63,7 @@ provider "linode" {
resource "linode_object_storage_bucket" "mybucket" {
# no need to specify the keys with the resource
cluster = "us-east-1"
region = "us-mia"
label = "mybucket"
lifecycle_rule {
Expand All @@ -81,7 +81,7 @@ provider "linode" {
resource "linode_object_storage_bucket" "mybucket" {
# no need to specify the keys with the resource
cluster = "us-east-1"
region = "us-mia"
label = "mybucket"
lifecycle_rule {
Expand Down
8 changes: 4 additions & 4 deletions docs/resources/object_storage_object.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ Provides a Linode Object Storage Object resource. This can be used to create, mo
```hcl
resource "linode_object_storage_object" "object" {
bucket = "my-bucket"
cluster = "us-east-1"
region = "us-mia"
key = "my-object"
secret_key = linode_object_storage_key.my_key.secret_key
Expand All @@ -31,7 +31,7 @@ resource "linode_object_storage_object" "object" {
```hcl
resource "linode_object_storage_object" "object" {
bucket = "my-bucket"
cluster = "us-east-1"
region = "us-mia"
key = "my-object"
secret_key = linode_object_storage_key.my_key.secret_key
Expand All @@ -55,7 +55,7 @@ provider "linode" {
resource "linode_object_storage_object" "object" {
# no need to specify the keys with the resource
bucket = "my-bucket"
cluster = "us-east-1"
region = "us-mia"
key = "my-object"
source = pathexpand("~/files/log.txt")
}
Expand All @@ -71,7 +71,7 @@ provider "linode" {
resource "linode_object_storage_object" "object" {
# no need to specify the keys with the resource
bucket = "my-bucket"
cluster = "us-east-1"
region = "us-mia"
key = "my-object"
source = pathexpand("~/files/log.txt")
}
Expand Down
45 changes: 23 additions & 22 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ go 1.22.0
toolchain go1.22.5

require (
github.com/aws/aws-sdk-go-v2 v1.32.5
github.com/aws/aws-sdk-go-v2 v1.32.7
github.com/aws/aws-sdk-go-v2/config v1.28.5
github.com/aws/aws-sdk-go-v2/credentials v1.17.46
github.com/aws/aws-sdk-go-v2/feature/s3/manager v1.17.4
github.com/aws/aws-sdk-go-v2/service/s3 v1.67.0
github.com/aws/aws-sdk-go-v2/service/s3 v1.72.0
github.com/aws/smithy-go v1.22.1
github.com/go-resty/resty/v2 v2.15.3
github.com/go-resty/resty/v2 v2.16.2
github.com/google/go-cmp v0.6.0
github.com/hashicorp/go-cty v1.4.1-0.20200723130312-85980079f637
github.com/hashicorp/go-hclog v1.6.3
Expand All @@ -20,34 +20,34 @@ require (
github.com/hashicorp/terraform-plugin-framework-nettypes v0.2.0
github.com/hashicorp/terraform-plugin-framework-timeouts v0.4.1
github.com/hashicorp/terraform-plugin-framework-timetypes v0.5.0
github.com/hashicorp/terraform-plugin-framework-validators v0.15.0
github.com/hashicorp/terraform-plugin-framework-validators v0.16.0
github.com/hashicorp/terraform-plugin-go v0.25.0
github.com/hashicorp/terraform-plugin-log v0.9.0
github.com/hashicorp/terraform-plugin-mux v0.17.0
github.com/hashicorp/terraform-plugin-sdk/v2 v2.35.0
github.com/hashicorp/terraform-plugin-testing v1.10.0
github.com/linode/linodego v1.43.0
github.com/hashicorp/terraform-plugin-testing v1.11.0
github.com/linode/linodego v1.44.1
github.com/linode/linodego/k8s v1.25.2
github.com/stretchr/testify v1.9.0
golang.org/x/crypto v0.29.0
golang.org/x/net v0.31.0
golang.org/x/sync v0.9.0
github.com/stretchr/testify v1.10.0
golang.org/x/crypto v0.32.0
golang.org/x/net v0.34.0
golang.org/x/sync v0.10.0
)

require (
github.com/ProtonMail/go-crypto v1.1.0-alpha.2 // indirect
github.com/agext/levenshtein v1.2.2 // indirect
github.com/apparentlymart/go-textseg/v15 v15.0.0 // indirect
github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream v1.6.6 // indirect
github.com/aws/aws-sdk-go-v2/aws/protocol/eventstream v1.6.7 // indirect
github.com/aws/aws-sdk-go-v2/feature/ec2/imds v1.16.20 // indirect
github.com/aws/aws-sdk-go-v2/internal/configsources v1.3.24 // indirect
github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.6.24 // indirect
github.com/aws/aws-sdk-go-v2/internal/configsources v1.3.26 // indirect
github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.6.26 // indirect
github.com/aws/aws-sdk-go-v2/internal/ini v1.8.1 // indirect
github.com/aws/aws-sdk-go-v2/internal/v4a v1.3.23 // indirect
github.com/aws/aws-sdk-go-v2/internal/v4a v1.3.26 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.12.1 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/checksum v1.4.4 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.12.5 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/s3shared v1.18.4 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/checksum v1.4.7 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.12.7 // indirect
github.com/aws/aws-sdk-go-v2/service/internal/s3shared v1.18.7 // indirect
github.com/aws/aws-sdk-go-v2/service/sso v1.24.6 // indirect
github.com/aws/aws-sdk-go-v2/service/ssooidc v1.28.5 // indirect
github.com/aws/aws-sdk-go-v2/service/sts v1.33.1 // indirect
Expand All @@ -62,6 +62,7 @@ require (
github.com/gogo/protobuf v1.3.2 // indirect
github.com/golang/protobuf v1.5.4 // indirect
github.com/google/gnostic-models v0.6.8 // indirect
github.com/google/go-querystring v1.1.0 // indirect
github.com/google/gofuzz v1.2.0 // indirect
github.com/google/uuid v1.6.0 // indirect
github.com/hashicorp/errwrap v1.0.0 // indirect
Expand All @@ -72,7 +73,7 @@ require (
github.com/hashicorp/go-retryablehttp v0.7.7 // indirect
github.com/hashicorp/go-uuid v1.0.3 // indirect
github.com/hashicorp/hc-install v0.9.0 // indirect
github.com/hashicorp/hcl/v2 v2.22.0 // indirect
github.com/hashicorp/hcl/v2 v2.23.0 // indirect
github.com/hashicorp/logutils v1.0.0 // indirect
github.com/hashicorp/terraform-exec v0.21.0 // indirect
github.com/hashicorp/terraform-json v0.23.0 // indirect
Expand Down Expand Up @@ -101,10 +102,10 @@ require (
github.com/vmihailenco/tagparser/v2 v2.0.0 // indirect
github.com/zclconf/go-cty v1.15.0 // indirect
golang.org/x/mod v0.21.0 // indirect
golang.org/x/oauth2 v0.23.0 // indirect
golang.org/x/sys v0.27.0 // indirect
golang.org/x/term v0.26.0 // indirect
golang.org/x/text v0.20.0 // indirect
golang.org/x/oauth2 v0.24.0 // indirect
golang.org/x/sys v0.29.0 // indirect
golang.org/x/term v0.28.0 // indirect
golang.org/x/text v0.21.0 // indirect
golang.org/x/time v0.6.0 // indirect
golang.org/x/tools v0.21.1-0.20240508182429-e35e4ccd0d2d // indirect
google.golang.org/appengine v1.6.8 // indirect
Expand Down
Loading

0 comments on commit 733403f

Please sign in to comment.