Skip to content

Commit

Permalink
Merge pull request #659 from jeremmfr/main
Browse files Browse the repository at this point in the history
Release v2.7.0
  • Loading branch information
jeremmfr authored May 3, 2024
2 parents 4413a84 + bf38653 commit 8f6519d
Show file tree
Hide file tree
Showing 152 changed files with 9,205 additions and 5,432 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/linters.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@ jobs:
- name: Check out code
uses: actions/checkout@v4
- name: golangci-lint
uses: golangci/golangci-lint-action@v4
uses: golangci/golangci-lint-action@v5
with:
version: 'v1.56.1'
version: 'v1.57.1'
args: -c .golangci.yml -v

markdown-lint:
Expand Down
35 changes: 33 additions & 2 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@ run:
linters:
enable-all: true
disable:
# maligned # deprecated 1.38 but govet-fieldalignment not usuable
- maligned # deprecated 1.38
- interfacer # deprecated 1.38
- scopelint # deprecated 1.39
- golint # deprecated 1.41
- exhaustivestruct # deprecated 1.46
# ifshort deprecated 1.48 but no replacement
- ifshort # deprecated 1.48
- deadcode # deprecated 1.49
- structcheck # deprecated 1.49
- varcheck # deprecated 1.49
Expand Down Expand Up @@ -60,6 +60,37 @@ linters-settings:
disable:
- fieldalignment
- shadow
revive:
rules:
# defaults
- name: blank-imports
- name: context-as-argument
- name: context-keys-type
- name: dot-imports
- name: empty-block
- name: error-naming
- name: error-return
- name: error-strings
- name: errorf
- name: exported
- name: increment-decrement
- name: indent-error-flow
- name: package-comments
- name: range
- name: receiver-naming
- name: redefines-builtin-id
- name: superfluous-else
- name: time-naming
- name: unexported-return
- name: unreachable-code
- name: unused-parameter
- name: var-declaration
- name: var-naming
# additionals
- name: confusing-naming
- name: import-alias-naming
- name: import-shadowing
- name: unhandled-error
issues:
exclude-rules:
- text: "github.com/jeremmfr/terraform-provider-junos/internal"
Expand Down
42 changes: 42 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,48 @@
<!-- markdownlint-disable-file MD013 MD041 -->
# changelog

## v2.7.0 (2024-05-03)

FEATURES:

* add **junos_forwardingoptions_evpn_vxlan** resource (Partial Fix [#645](https://github.com/jeremmfr/terraform-provider-junos/issues/645))

ENHANCEMENTS:

* **data-source/junos_interfaces_physical_present**:
* add `interfaces` block map attribute with same attributes as `interface_statuses` and additional `logical_interface_names` attribute (Fix [#641](https://github.com/jeremmfr/terraform-provider-junos/issues/641))
* deprecate `interface_statuses` attribute (read the `interfaces` attribute instead)
* **resource/junos_evpn**: add `no_core_isolation` argument (Fix [#644](https://github.com/jeremmfr/terraform-provider-junos/issues/644))
* **resource/junos_ospf_area**: resource now use new [terraform-plugin-framework](https://github.com/hashicorp/terraform-plugin-framework)
some of config errors are now sent during Plan instead of during Apply
optional boolean attributes doesn't accept value *false*
optional string attributes doesn't accept *empty* value
the resource schema has been upgraded to have one-blocks in single mode instead of list
* **resource/junos_ospf**: resource now use new [terraform-plugin-framework](https://github.com/hashicorp/terraform-plugin-framework)
some of config errors are now sent during Plan instead of during Apply
optional boolean attributes doesn't accept value *false*
optional string attributes doesn't accept *empty* value
the resource schema has been upgraded to have one-blocks in single mode instead of list
* **resource/junos_vlan**:
* resource now use new [terraform-plugin-framework](https://github.com/hashicorp/terraform-plugin-framework)
some of config errors are now sent during Plan instead of during Apply
optional boolean attributes doesn't accept value *false*
optional string attributes doesn't accept *empty* value
the resource schema has been upgraded to have one-blocks in single mode instead of list
* `community_vlans` argument is now a Set of String (instead of Set of Number) to accept VLAN name in addition to VLAN id
data in the state has been updated for the new format
Number in config is automatically converted to String by Terraform
* `isolated_vlan` argument is now a String (instead of Number) to accept VLAN name in addition to VLAN id
data in the state has been updated for the new format
Number in config is automatically converted to String by Terraform
* `vlan_id` argument is now a String (instead of Number) to accept `all` or `none` in addition to VLAN id
data in the state has been updated for the new format
Number in config is automatically converted to String by Terraform
* add `routing_instance` argument (Partial fix [#646](https://github.com/jeremmfr/terraform-provider-junos/issues/646))
and therefore `id` format has been changed to `<name>_-_<routing_instance>` (instead of `<name>`)
* add `no_arp_suppression` argument (Partial fix [#646](https://github.com/jeremmfr/terraform-provider-junos/issues/646))
* add `translation_vni` argument inside `vxlan` block argument

## v2.6.0 (2024-03-13)

FEATURES:
Expand Down
17 changes: 14 additions & 3 deletions docs/data-sources/interfaces_physical_present.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,20 @@ The following attributes are exported:
- **id** (String)
An identifier for the data source.
- **interface_names** (List of String)
List of interface names found.
- **interface_statuses** (Block List)
For each interface name.
Found interface names.
- **interfaces** (Block Map)
Dictionary of found interfaces with interface name as key.
- **name** (String)
Interface name (as the map key).
- **admin_status** (String)
Admin status.
- **oper_status** (String)
Operational status.
- **logical_interface_names** (List of String)
Logical interface names under this physical interface.
- **interface_statuses** (Block List, **Deprecated**)
For each found interface name, its status.
Deprecated attribute, use the `interfaces` attribute instead.
- **name** (String)
Interface name.
- **admin_status** (String)
Expand Down
4 changes: 2 additions & 2 deletions docs/resources/eventoptions_generate_event.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,15 +24,15 @@ The following arguments are supported:

- **name** (Required, String, Forces new resource)
Name of the event to be generated.
- **no_drift** (Optional, Boolean)
Avoid event generation delay propagating to next event.
- **start_time** (Optional, String)
Start-time to generate event (YYYY-MM-DD.HH:MM:SS).
`time_interval` need to be set.
- **time_interval** (Optional, Number)
Frequency for generating the event (60..2592000 seconds).
- **time_of_day** (Optional, String)
Time of day at which to generate event (HH:MM:SS).
- **no_drift** (Optional, Boolean)
Avoid event generation delay propagating to next event.

## Attribute Reference

Expand Down
3 changes: 3 additions & 0 deletions docs/resources/evpn.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,9 @@ The following arguments are supported:
Time window for detection of duplicate MACs (5..600 seconds).
- **multicast_mode** (Optional, String)
Multicast mode for EVPN.
- **no_core_isolation** (Optional, Boolean)
Disable EVPN Core isolation.
`routing_instance` need to be `default`.
- **switch_or_ri_options** (Optional, Block, Forces new resource)
Declare `switch-options` or `routing-instance` configuration.
Need to be set if `routing_instance` = `default` or `routing_instance_evpn` = true.
Expand Down
48 changes: 48 additions & 0 deletions docs/resources/forwardingoptions_evpn_vxlan.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
---
page_title: "Junos: junos_forwardingoptions_evpn_vxlan"
---

# junos_forwardingoptions_evpn_vxlan

-> **Note:** This resource should only be created **once** for root level or each routing-instance.
It's used to configure static (not object) options in `forwarding-options evpn-vxlan` block in root or
routing-instance level.

Configure static configuration in `forwarding-options evpn-vxlan` block for root or
routing-instance level.

## Example Usage

```hcl
# Configure forwarding-options evpn-vxlan
resource "junos_forwardingoptions_evpn_vxlan" "demo" {
shared_tunnels = true
}
```

## Argument Reference

The following arguments are supported:

- **routing_instance** (Optional, String, Forces new resource)
Routing instance if not root level.
Need to be `default` or name of routing instance.
Defaults to `default`
- **shared_tunnels** (Optional, Boolean)
Create VTEP tunnels to EVPN PE.

## Attribute Reference

The following attributes are exported:

- **id** (String)
An identifier for the resource with format `<routing_instance>`.

## Import

Junos forwarding-options evpn-vxlan can be imported using an id made up of
`<routing_instance>`, e.g.

```shell
$ terraform import junos_forwardingoptions_evpn_vxlan.demo default
```
10 changes: 5 additions & 5 deletions docs/resources/forwardingoptions_sampling.md
Original file line number Diff line number Diff line change
Expand Up @@ -99,16 +99,16 @@ The following arguments are supported:
Disable sampled packet dumps.
- **files** (Optional, Number)
Maximum number of sampled packet dump files (2..10000).
- **no_stamp** (Optional, Boolean)
Don't timestamp every packet in the dump.
- **no_world_readable** (Optional, Boolean)
Don't allow any user to read the sampled dump.
- **size** (Optional, Number)
Maximum sample dump file size (1024..104857600).
- **stamp** (Optional, Boolean)
Timestamp every packet in the dump.
- **no_stamp** (Optional, Boolean)
Don't timestamp every packet in the dump.
- **world_readable** (Optional, Boolean)
Allow any user to read the sampled dump.
- **no_world_readable** (Optional, Boolean)
Don't allow any user to read the sampled dump.
- **flow_active_timeout** (Optional, Number)
Interval after which an active flow is exported (60..1800 seconds).
- **flow_inactive_timeout** (Optional, Number)
Expand Down Expand Up @@ -183,5 +183,5 @@ Junos forwarding-options sampling can be imported using an id made up of
`<routing_instance>`, e.g.

```shell
$ terraform import junos_forwardingoptions_sampling_instance.demo default
$ terraform import junos_forwardingoptions_sampling.demo default
```
4 changes: 2 additions & 2 deletions docs/resources/oam_gretunnel_interface.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,12 @@ page_title: "Junos: junos_oam_gretunnel_interface"

# junos_oam_gretunnel_interface

Provides a protocol oam gre-tunnel interface resource.
Provides a oam gre-tunnel interface resource.

## Example Usage

```hcl
# Add protocol oam gre-tunnel interface
# Add oam gre-tunnel interface
resource "junos_oam_gretunnel_interface" "gr1" {
name = "gr-1/1/10.1"
hold_time = 30
Expand Down
10 changes: 5 additions & 5 deletions docs/resources/ospf.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,14 @@ resource "junos_ospf" "ospf" {

The following arguments are supported:

- **routing_instance** (Optional, String, Forces new resource)
Routing instance.
Need to be `default` (for root level) or the name of routing instance.
Defaults to `default`.
- **version** (Optional, String)
Version of ospf.
Need to be `v2` or `v3`.
Defaults to `v2`.
- **routing_instance** (Optional, String, Forces new resource)
Routing instance.
Need to be `default` (for root level) or the name of routing instance.
Defaults to `default`.
- **database_protection** (Optional, Block)
Declare `database-protection` configuration.
- **maximum_lsa** (Required, Number)
Expand Down Expand Up @@ -77,7 +77,7 @@ The following arguments are supported:
- **labeled_preference** (Optional, Number)
Preference of labeled routes.
- **lsa_refresh_interval** (Optional, Number)
LSA refresh interval (minutes) (25..50).
LSA refresh interval (25..50 minutes).
- **no_nssa_abr** (Optional, Boolean)
Disable full NSSA functionality at ABR.
- **no_rfc1583** (Optional, Boolean)
Expand Down
Loading

0 comments on commit 8f6519d

Please sign in to comment.