fixed struct alignment && refactor linter (#369)
All checks were successful
test / test (push) Successful in 42s
All checks were successful
test / test (push) Successful in 42s
## Pull Request template Please, go through these steps before clicking submit on this PR. 1. Give a descriptive title to your PR. 2. Provide a description of your changes. 3. Make sure you have some relevant tests. 4. Put `closes #XXXX` in your comment to auto-close the issue that your PR fixes (if applicable). **PLEASE REMOVE THIS TEMPLATE BEFORE SUBMITTING** Reviewed-on: #369 Co-authored-by: Evstigneev Denis <danteevstigneev@yandex.ru> Co-committed-by: Evstigneev Denis <danteevstigneev@yandex.ru>
This commit is contained in:
@@ -10,11 +10,18 @@ import (
|
||||
type DigitalOceanMetadata struct {
|
||||
Metadata struct {
|
||||
V1 struct {
|
||||
DropletID int64 `json:"droplet_id"`
|
||||
Hostname string `json:"hostname"`
|
||||
VendorData string `json:"vendor_data"`
|
||||
Features map[string]interface{} `json:"features"`
|
||||
|
||||
Hostname string `json:"hostname"`
|
||||
VendorData string `json:"vendor_data"`
|
||||
Region string `json:"region"`
|
||||
|
||||
PublicKeys []string `json:"public_keys"`
|
||||
Region string `json:"region"`
|
||||
|
||||
DNS struct {
|
||||
Nameservers []string `json:"nameservers"`
|
||||
} `json:"dns"`
|
||||
|
||||
Interfaces struct {
|
||||
Private []struct {
|
||||
IPv4 struct {
|
||||
@@ -31,24 +38,23 @@ type DigitalOceanMetadata struct {
|
||||
Netmask string `json:"netmask"`
|
||||
Gateway string `json:"gateway"`
|
||||
} `json:"ipv4"`
|
||||
IPv6 struct {
|
||||
Address string `json:"ip_address"`
|
||||
CIDR int `json:"cidr"`
|
||||
Gateway string `json:"gateway"`
|
||||
} `json:"ipv6"`
|
||||
Mac string `json:"mac"`
|
||||
Type string `json:"type"`
|
||||
IPv6 struct {
|
||||
Address string `json:"ip_address"`
|
||||
Gateway string `json:"gateway"`
|
||||
CIDR int `json:"cidr"`
|
||||
} `json:"ipv6"`
|
||||
} `json:"public"`
|
||||
} `json:"interfaces"`
|
||||
|
||||
DropletID int64 `json:"droplet_id"`
|
||||
|
||||
FloatingIP struct {
|
||||
IPv4 struct {
|
||||
Active bool `json:"active"`
|
||||
} `json:"ipv4"`
|
||||
} `json:"floating_ip"`
|
||||
DNS struct {
|
||||
Nameservers []string `json:"nameservers"`
|
||||
} `json:"dns"`
|
||||
Features map[string]interface{} `json:"features"`
|
||||
} `json:"v1"`
|
||||
} `json:"metadata"`
|
||||
}
|
||||
|
Reference in New Issue
Block a user