codesign

package
v2.0.0-alpha.57 Latest Latest
Warning

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

Go to latest
Published: Apr 17, 2025 License: MIT Imports: 25 Imported by: 5

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SelectConnectionCredentials

func SelectConnectionCredentials(
	authType AuthType,
	bitriseConnection *devportalservice.AppleDeveloperConnection,
	inputs ConnectionOverrideInputs, logger log.Logger) (devportalservice.Credentials, error)

SelectConnectionCredentials selects the final credentials for Apple services based on: - connections set up on Bitrise.io (globally for app) - step inputs for overriding the global config

Types

type AssetWriter

type AssetWriter interface {
	ForceCodesignAssets(distribution autocodesign.DistributionType, codesignAssetsByDistributionType map[autocodesign.DistributionType]autocodesign.AppCodesignAssets) error
}

AssetWriter ...

type AuthType

type AuthType int

AuthType ...

const (
	// APIKeyAuth ...
	APIKeyAuth AuthType = iota
	// AppleIDAuth ...
	AppleIDAuth
)

type Config

type Config struct {
	CertificatesAndPassphrases   []certdownloader.CertificateAndPassphrase
	Keychain                     keychain.Keychain
	DistributionMethod           autocodesign.DistributionType
	FallbackProvisioningProfiles []string
}

Config ...

func ParseConfig

func ParseConfig(input Input, cmdFactory command.Factory) (Config, error)

ParseConfig validates and parses step inputs related to code signing and returns with a Config

type ConnectionOverrideInputs

type ConnectionOverrideInputs struct {
	APIKeyPath              stepconf.Secret
	APIKeyID                string
	APIKeyIssuerID          string
	APIKeyEnterpriseAccount bool
}

ConnectionOverrideInputs are used in steps to control the API key based auth credentials This overrides the global API connection defined on Bitrise.io

type DetailsProvider

type DetailsProvider interface {
	IsSigningManagedAutomatically() (bool, error)
	Platform() (autocodesign.Platform, error)
	GetAppLayout(uiTestTargets bool) (autocodesign.AppLayout, error)
}

DetailsProvider ...

type Input

type Input struct {
	AuthType                     AuthType
	DistributionMethod           string
	CertificateURLList           string
	CertificatePassphraseList    stepconf.Secret
	KeychainPath                 string
	KeychainPassword             stepconf.Secret
	FallbackProvisioningProfiles string
}

Input ...

type Manager

type Manager struct {
	// contains filtered or unexported fields
}

Manager ...

func NewManagerWithArchive

func NewManagerWithArchive(
	opts Opts,
	appleAuth devportalservice.Credentials,
	bitriseTestDevices []devportalservice.TestDevice,
	clientFactory devportalclient.Factory,
	certDownloader autocodesign.CertificateProvider,
	fallbackProfileDownloader autocodesign.ProfileProvider,
	assetInstaller autocodesign.AssetWriter,
	localCodeSignAssetManager autocodesign.LocalCodeSignAssetManager,
	archive xcarchive.IosArchive,
	logger log.Logger,
) Manager

NewManagerWithArchive creates a codesign manager, which reads the code signing asset requirements from an XCArchive file.

func NewManagerWithProject

func NewManagerWithProject(
	opts Opts,
	appleAuth devportalservice.Credentials,
	bitriseTestDevices []devportalservice.TestDevice,
	clientFactory devportalclient.Factory,
	certDownloader autocodesign.CertificateProvider,
	fallbackProfileDownloader autocodesign.ProfileProvider,
	assetInstaller autocodesign.AssetWriter,
	localCodeSignAssetManager autocodesign.LocalCodeSignAssetManager,
	project projectmanager.Project,
	logger log.Logger,
) Manager

NewManagerWithProject creates a codesign manager, which reads the code signing asset requirements from an Xcode Project.

func (*Manager) PrepareCodesigning

func (m *Manager) PrepareCodesigning() (*devportalservice.APIKeyConnection, error)

PrepareCodesigning selects a suitable code signing strategy based on the step and project configuration, then downloads code signing assets (profiles, certificates) and registers test devices if needed

type Opts

type Opts struct {
	AuthType                   AuthType
	ShouldConsiderXcodeSigning bool
	TeamID                     string

	ExportMethod      autocodesign.DistributionType
	XcodeMajorVersion int

	RegisterTestDevices    bool
	SignUITests            bool
	MinDaysProfileValidity int
	IsVerboseLog           bool
}

Opts ...

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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