windowsanswerfiles

package
v0.10.1-alpha.7 Latest Latest
Warning

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

Go to latest
Published: Sep 1, 2020 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	XmlHeader = `<?xml version="1.0" encoding="UTF-8"?>` + "\n"
)

Variables

This section is empty.

Functions

func GenerateInstallScriptFile

func GenerateInstallScriptFile(fileContentBase64 string, filepath string) error

func GenerateTagFile

func GenerateTagFile(filepath string) error

Types

type AdministratorPassword

type AdministratorPassword struct {
	XMLName  xml.Name `xml:"AdministratorPassword,omitempty"`
	Password `xml:"omitempty"`
}

type AutoLogon

type AutoLogon struct {
	Enabled string `xml:"Enabled,omitempty"`
}

type Component

type Component struct {
	XMLName                                   xml.Name    `xml:"component"`
	Name                                      string      `xml:"name,attr"`
	PublicKeyToken                            string      `xml:"publicKeyToken,attr"`
	Language                                  string      `xml:"language,attr"`
	VersionScope                              string      `xml:"versionScope,attr"`
	ProcessorArchitecture                     string      `xml:"processorArchitecture,attr"`
	DoNotOpenInitialConfigurationTasksAtLogon string      `xml:"DoNotOpenInitialConfigurationTasksAtLogon,omitempty"`
	DoNotOpenServerManagerAtLogon             string      `xml:"DoNotOpenServerManagerAtLogon,omitempty"`
	DenyTSConnections                         string      `xml:"fDenyTSConnections,omitempty"`
	FirewallGroups                            interface{} `xml:"FirewallGroups>FirewallGroup"`
	ShellSetup                                `xml:"ShellSetup,omitempty"`
	RunSynchronous                            interface{} `xml:"RunSynchronous>RunSynchronousCommand"`
	InternationalCore                         `xml:"InternationalCore,omitempty"`
	ShellSetupOobe                            `xml:"ShellSetupOobe,omitempty"`
}

type FirewallGroup

type FirewallGroup struct {
	XMLName     xml.Name `xml:"FirewallGroup"`
	WCMAction   string   `xml:"wcm:action,attr"`
	WCMKeyValue string   `xml:"wcm:keyValue,attr"`
	Active      string   `xml:"Active"`
	Group       string   `xml:"Group"`
	Profile     string   `xml:"Profile"`
}

type InternationalCore

type InternationalCore struct {
	XMLName      xml.Name `xml:"InternationalCore,omitempty"`
	InputLocale  string   `xml:"InputLocale,omitempty"`
	SystemLocale string   `xml:"SystemLocale,omitempty"`
	UILanguage   string   `xml:"UILanguage,omitempty"`
	UserLocale   string   `xml:"UserLocale,omitempty"`
}

type LocalAccount

type LocalAccount struct {
	XMLName     xml.Name `xml:"LocalAccount,omitempty"`
	WCMAction   string   `xml:"wcm:action,attr"`
	Password    Password `xml:"Password,omitempty"`
	DisplayName string   `xml:"DisplayName,omitempty"`
	Name        string   `xml:"Name,omitempty"`
	Group       string   `xml:"Group,omitempty"`
}

type Oobe

type Oobe struct {
	XMLName                 xml.Name `xml:"OOBE,omitempty"`
	HideEULAPage            string   `xml:"HideEULAPage,omitempty"`
	HideLocalAccountScreen  string   `xml:"HideLocalAccountScreen,omitempty"`
	SkipMachineOOBE         string   `xml:"SkipMachineOOBE,omitempty"`
	SkipUserOOBE            string   `xml:"SkipUserOOBE,omitempty"`
	NetworkLocation         string   `xml:"NetworkLocation,omitempty"`
	ProtectYourPC           string   `xml:"ProtectYourPC,omitempty"`
	HideWirelessSetupInOOBE string   `xml:"HideWirelessSetupInOOBE,omitempty"`
}

type Password

type Password struct {
	XMLName   xml.Name `xml:"Password,omitempty"`
	Value     string   `xml:"Value,omitempty"`
	PlainText string   `xml:"PlainText,omitempty"`
}

type RunSynchronousCommand

type RunSynchronousCommand struct {
	XMLName     xml.Name `xml:"RunSynchronousCommand,omitempty"`
	WCMAction   string   `xml:"wcm:action,attr"`
	Order       string   `xml:"Order,omitempty"`
	Description string   `xml:"Description,omitempty"`
	Path        string   `xml:"Path,omitempty"`
	WillReboot  string   `xml:"WillReboot,omitempty"`
}

type Settings

type Settings struct {
	XMLName    xml.Name `xml:"settings"`
	Pass       string   `xml:"pass,attr"`
	Components []Component
}

type ShellSetup

type ShellSetup struct {
	XMLName      xml.Name `xml:"omitempty"`
	TimeZone     string   `xml:"TimeZone,omitempty"`
	ComputerName string   `xml:"ComputerName,omitempty"`
}

type ShellSetupOobe

type ShellSetupOobe struct {
	XMLName      xml.Name    `xml:"omitempty"`
	Oobe         interface{} `xml:"OOBE,omitempty"`
	UserAccounts interface{} `xml:"UserAccounts,omitempty"`
	AutoLogon    interface{} `xml:"AutoLogon,omitempty"`
}

type Unattend

type Unattend struct {
	XMLName  xml.Name `xml:"unattend"`
	XMLns    string   `xml:"xmlns,attr"`
	WCM      string   `xml:"xmlns:wcm,attr"`
	Settings []Settings
}

func CreateUnattendObject

func CreateUnattendObject(hostname string) *Unattend

func (*Unattend) AddUser

func (unattend *Unattend) AddUser(name string, group string, password string) error

func (*Unattend) SaveXmlFile

func (unattend *Unattend) SaveXmlFile(filepath string) error

type UserAccounts

type UserAccounts struct {
	XMLName               xml.Name              `xml:"UserAccounts,omitempty"`
	LocalAccounts         []LocalAccount        `xml:"LocalAccounts>LocalAccount,omitempty"`
	AdministratorPassword AdministratorPassword `xml:"AdministratorPassword,omitempty"`
}

Jump to

Keyboard shortcuts

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