utilityMacOSPKGAppMetadata

package
v0.32.0-alpha Latest Latest
Warning

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

Go to latest
Published: Oct 6, 2025 License: MPL-2.0 Imports: 24 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ReadTimeout = 240 // Extended timeout for metadata extraction
)

Variables

This section is empty.

Functions

func NewMacOSPKGAppMetadataDataSource

func NewMacOSPKGAppMetadataDataSource() datasource.DataSource

Types

type BundleInfoModel

type BundleInfoModel struct {
	BundleID        types.String `tfsdk:"bundle_id"`
	Version         types.String `tfsdk:"version"`
	Path            types.String `tfsdk:"path"`
	CFBundleVersion types.String `tfsdk:"cf_bundle_version"`
}

BundleInfoModel represents information about an included bundle in the PKG

type MacOSPKGAppMetadataDataSource

type MacOSPKGAppMetadataDataSource struct {
	ProviderTypeName string
	TypeName         string
	// contains filtered or unexported fields
}

func (*MacOSPKGAppMetadataDataSource) Configure

Configure configures the data source with the provider client

func (*MacOSPKGAppMetadataDataSource) Metadata

Metadata returns the datasource type name.

func (*MacOSPKGAppMetadataDataSource) Read

Read fetches the data from the PKG file and sets it in the data source state

func (*MacOSPKGAppMetadataDataSource) Schema

Schema defines the schema for the data source

type MacOSPKGAppMetadataDataSourceModel

type MacOSPKGAppMetadataDataSourceModel struct {
	InstallerFilePathSource types.String             `tfsdk:"installer_file_path_source"` // Path to a local PKG file
	InstallerURLSource      types.String             `tfsdk:"installer_url_source"`       // URL to a PKG file
	Metadata                *MetadataDataSourceModel `tfsdk:"metadata"`                   // Extracted metadata
	Timeouts                timeouts.Value           `tfsdk:"timeouts"`
}

MacOSPKGAppMetadataDataSourceModel defines the data source model

type MetadataDataSourceModel

type MetadataDataSourceModel struct {
	// Core bundle metadata (as requested)
	CFBundleIdentifier         types.String `tfsdk:"cf_bundle_identifier"`
	CFBundleShortVersionString types.String `tfsdk:"cf_bundle_short_version_string"`

	// Additional metadata extracted from PKG/XAR
	Name            types.String `tfsdk:"name"`
	PackageIDs      types.List   `tfsdk:"package_ids"`
	InstallLocation types.String `tfsdk:"install_location"`
	AppPaths        types.List   `tfsdk:"app_paths"`
	MinOSVersion    types.String `tfsdk:"min_os_version"`
	SizeMB          types.Int32  `tfsdk:"size_mb"`
	SHA256Checksum  types.String `tfsdk:"sha256_checksum"`
	MD5Checksum     types.String `tfsdk:"md5_checksum"`

	// Included bundles inside the PKG
	IncludedBundles types.List `tfsdk:"included_bundles"`
}

MetadataDataSourceModel represents detailed metadata for a macOS PKG app

Jump to

Keyboard shortcuts

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