yaml2pcl

package
v0.0.17 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 2, 2024 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Overview

package yaml2pcl provides a method to convert k8s yaml to PCL (pulumi schema)

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConvertDirectory

func ConvertDirectory(dirName string) (string, hcl.Diagnostics, error)

ConvertDirectory returns a string conversion of the input directory with YAML manifests into PCL: sample below Output: resource foo "kubernetes:core/v1:Namespace" { apiVersion = "v1" kind = "Namespace" metadata = { name = "foo" } }

func ConvertFile

func ConvertFile(filename string) (string, hcl.Diagnostics, error)

ConvertFile returns a string conversion of the input YAML in a file into PCL: sample below Output: resource foo "kubernetes:core/v1:Namespace" { apiVersion = "v1" kind = "Namespace" metadata = { name = "foo" } }

Types

type Visitor

type Visitor struct {
}

func (*Visitor) Visit

func (v *Visitor) Visit(node ast.Node) ast.Visitor

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL