Skip to content

Commit

Permalink
doc: Add Example Of Network Data
Browse files Browse the repository at this point in the history
* adding example of network data

Resolves: doc/add-net-data
  • Loading branch information
irishgordo committed Jul 6, 2024
1 parent d2f4cf3 commit 28c7613
Showing 1 changed file with 19 additions and 3 deletions.
22 changes: 19 additions & 3 deletions docs/resources/cloudinit_secret.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ description: |-

```terraform
resource "harvester_cloudinit_secret" "cloud-config-opensuse154" {
name = "cloud-config-opensuse154"
name = "cloud-config-opensuse156"
namespace = "default"
depends_on = [
Expand All @@ -39,7 +39,15 @@ resource "harvester_cloudinit_secret" "cloud-config-opensuse154" {
- >-
public_key content of harvester_ssh_key.mysshkey
EOF
network_data = ""
network_data = <<-EOF
network:
version: 2
ethernets:
eth0:
dhcp4: true
nameservers:
addresses: [8.8.8.8,8.8.4.4,1.1.1.1]
EOF
}
resource "harvester_cloudinit_secret" "cloud-config-ubuntu20" {
Expand All @@ -60,8 +68,16 @@ resource "harvester_cloudinit_secret" "cloud-config-ubuntu20" {
- enable
- '--now'
- qemu-guest-agent
EOF
network_data = <<-EOF
network:
version: 2
ethernets:
enp1s0:
dhcp4: true
nameservers:
addresses: [8.8.8.8,8.8.4.4,1.1.1.1]
EOF
network_data = ""
}
```

Expand Down

0 comments on commit 28c7613

Please sign in to comment.