Skip to content

Commit

Permalink
chore(release): 1.4.0
Browse files Browse the repository at this point in the history
  • Loading branch information
semantic-release-bot committed May 1, 2023
1 parent 591096d commit b86ea25
Show file tree
Hide file tree
Showing 3 changed files with 84 additions and 1 deletion.
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
## [1.4.0](https://github.com/terraform-routeros/terraform-provider-routeros/compare/v1.3.9...v1.4.0) (2023-05-01)


### Features

* Support for ip/services ([#195](https://github.com/terraform-routeros/terraform-provider-routeros/issues/195)) ([591096d](https://github.com/terraform-routeros/terraform-provider-routeros/commit/591096d4a249acb6f4484bc16a5aec691577453c)), closes [#182](https://github.com/terraform-routeros/terraform-provider-routeros/issues/182)

## [1.3.9](https://github.com/terraform-routeros/terraform-provider-routeros/compare/v1.3.8...v1.3.9) (2023-05-01)


Expand Down
76 changes: 76 additions & 0 deletions docs/resources/ip_service.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
# routeros_ip_service (Resource)


## Example Usage
```terraform
locals {
tls_service = {"api-ssl" = 8729, "www-ssl" = 443}
disable_service = {"api" = 8728, "ftp" = 21, "telnet" = 23, "www" = 80}
enable_service = {"ssh" = 22, "winbox" = 8291}
}
resource "routeros_system_certificate" "tls_cert" {
name = "tls-cert"
common_name = "Mikrotik Router"
days_valid = 3650
key_usage = ["key-cert-sign", "crl-sign", "digital-signature", "key-agreement", "tls-server"]
key_size = "prime256v1"
sign {
}
}
# terraform state rm 'routeros_ip_service.tls["www-ssl"]'
# terraform import 'routeros_ip_service.tls["www-ssl"]' www-ssl
resource "routeros_ip_service" "tls" {
for_each = local.tls_service
numbers = each.key
port = each.value
certificate = routeros_system_certificate.tls_cert.name
tls_version = "only-1.2"
disabled = false
}
resource "routeros_ip_service" "disabled" {
for_each = local.disable_service
numbers = each.key
port = each.value
disabled = true
}
resource "routeros_ip_service" "enabled" {
for_each = local.enable_service
numbers = each.key
port = each.value
disabled = false
}
```

<!-- schema generated by tfplugindocs -->
## Schema

### Required

- `numbers` (String) The name of the service whose settings will be changed ( api, api-ssl, ftp, ssh, telnet, winbox, www, www-ssl ).
- `port` (Number) The port particular service listens on.

### Optional

- `address` (String) List of IP/IPv6 prefixes from which the service is accessible.
- `certificate` (String) The name of the certificate used by a particular service. Applicable only for services that depend on certificates ( www-ssl, api-ssl ).
- `disabled` (Boolean)
- `tls_version` (String) Specifies which TLS versions to allow by a particular service.
- `vrf` (String) Specify which VRF instance to use by a particular service.

### Read-Only

- `id` (String) The ID of this resource.
- `invalid` (Boolean)
- `name` (String) Service name.

## Import
Import is supported using the following syntax:
```shell
#The ID can be found via API or the terminal
#The command for the terminal is -> :put [/ip/service get [print show-ids]]
terraform import routeros_ip_service.www_ssl www-ssl
```
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "terraform-provider-routeros",
"version": "1.3.9",
"version": "1.4.0",
"repository": {
"type": "git",
"url": "https://github.com/terraform-routeros/terraform-provider-routeros"
Expand Down

0 comments on commit b86ea25

Please sign in to comment.