_id
stringlengths
2
7
text
stringlengths
6
2.61k
title
stringclasses
1 value
c176700
// Internal MAAS handling
c176701
// getSystemHandler on Linux writes messages to syslog.
c176702
// Return string for minor number of nvidia device corresponding to the given pci id
c176703
// GetLogger returns a logger suitable for using as logger.Log.
c176704
// SetLogger installs the given logger as global logger. It returns a function // that can be used to restore whatever logger was installed beforehand.
c176705
// WaitRecord blocks until a log.Record is received on the given channel. It // returns the emitted record, or nil if no record was received within the // given timeout. Useful in conjunction with log.ChannelHandler, for // asynchronous testing.
c176706
// AddContext will return a copy of the logger with extra context added
c176707
// NewDottedVersion returns a new Version.
c176708
// Parse parses a string starting with a dotted version and returns it.
c176709
// String returns version as a string
c176710
// Compare returns result of comparison between two versions
c176711
// Create the default profile of a project.
c176712
// Common logic between PUT and PATCH.
c176713
// Check if a project is empty.
c176714
// Certificate handling functions // GetCertificateFingerprints returns a list of certificate fingerprints
c176715
// GetCertificates returns a list of certificates
c176716
// GetCertificate returns the certificate entry for the provided fingerprint
c176717
// CreateCertificate adds a new certificate to the LXD trust store
c176718
// UpdateCertificate updates the certificate definition
c176719
// DeleteCertificate removes a certificate from the LXD trust store
c176720
// Return a list of templates used in a container or the content of a template
c176721
// Add a container template file
c176722
// Delete a container template
c176723
// Return the full path of a container template.
c176724
// Error implements the error interface.
c176725
// ErrorList implements the error interface.
c176726
// Add adds an Error with given key name, value and reason.
c176727
// UpdateSchema updates the schema.go file of the cluster and node databases.
c176728
// Like doProfileUpdate but does not update the database, since it was already // updated by doProfileUpdate itself, called on the notifying node.
c176729
// Profile update of a single container.
c176730
// Query the db for information about containers associated with the given // profile.
c176731
// GetNetworkNames returns a list of network names
c176732
// GetNetworks returns a list of Network struct
c176733
// GetNetwork returns a Network entry for the provided name
c176734
// GetNetworkLeases returns a list of Network struct
c176735
// GetNetworkState returns metrics and information on the running network
c176736
// CreateNetwork defines a new network using the provided Network struct
c176737
// UpdateNetwork updates the network to match the provided Network struct
c176738
// RenameNetwork renames an existing network entry
c176739
// Open the cluster database object. // // The name argument is the name of the cluster database. It defaults to // 'db.bin', but can be overwritten for testing. // // The dialer argument is a function that returns a gRPC dialer that can be // used to connect to a database node using the gRPC SQL package.
c176740
// URLEncode encodes a path and query parameters to a URL.
c176741
// IsUnixSocket returns true if the given path is either a Unix socket // or a symbolic link pointing at a Unix socket.
c176742
// HostPath returns the host path for the provided path // On a normal system, this does nothing // When inside of a snap environment, returns the real path
c176743
// FileMove tries to move a file by using os.Rename, // if that fails it tries to copy the file and remove the source.
c176744
// DirCopy copies a directory recursively, overwriting the target if it exists.
c176745
// StringMapHasStringKey returns true if any of the supplied keys are present in the map.
c176746
// Spawn the editor with a temporary YAML file for editing configs
c176747
// WriteTempFile creates a temp file with the specified content
c176748
// RenderTemplate renders a pongo2 template.
c176749
// Every returns a Schedule that always returns the given time interval.
c176750
// Currently only used for loop-backed LVM storage pools. Can be called without // overhead since it is essentially a noop for non-loop-backed LVM storage // pools.
c176751
// Dump returns a SQL text dump of all rows across all tables, similar to // sqlite3's dump feature
c176752
// Dump a single table, returning a SQL text containing statements for its // schema and data.
c176753
// ProjectHasProfiles is a helper to check if a project has the profiles // feature enabled.
c176754
// ProjectNames returns the names of all available projects.
c176755
// ProjectMap returns the names and ids of all available projects.
c176756
// ProjectHasImages is a helper to check if a project has the images // feature enabled.
c176757
// ProjectUpdate updates the project matching the given key parameters.
c176758
// GetCluster returns information about a cluster // // If this client is not trusted, the password must be supplied
c176759
// UpdateCluster requests to bootstrap a new cluster or join an existing one.
c176760
// GetClusterMemberNames returns the URLs of the current members in the cluster
c176761
// GetClusterMembers returns the current members of the cluster
c176762
// GetClusterMember returns information about the given member
c176763
// RenameClusterMember changes the name of an existing member
c176764
// Disconnect must be used once done listening for events
c176765
// CompareVersions the versions of two LXD nodes. // // A version consists of the version the node's schema and the number of API // extensions it supports. // // Return 0 if they equal, 1 if the first version is greater than the second // and 2 if the second is greater than the first. // // Return an error if inconsis...
c176766
// HasClientCertificate will return true if a client certificate has already been generated
c176767
// GenerateClientCertificate will generate the needed client.crt and client.key if needed
c176768
// LoadModule loads the kernel module with the given name, by invoking // modprobe.
c176769
// Parse runs the Go parser against the given package name.
c176770
// PprofAddress returns the network addresss of the pprof endpoint, or an empty string if there's no pprof endpoint
c176771
// PprofUpdateAddress updates the address for the pprof endpoint, shutting it down and restarting it.
c176772
// NewMethod return a new method code snippet for executing a certain mapping.
c176773
// Generate the desired method.
c176774
// Populate a field consisting of a slice of objects referencing the // entity. This information is available by joining a the view or table // associated with the type of the referenced objects, which must contain the // natural key of the entity.
c176775
// StoragePoolID returns the ID of the pool with the given name.
c176776
// StoragePoolIDsNotPending returns a map associating each storage pool name to its ID. // // Pending storage pools are skipped.
c176777
// StoragePoolNodeJoin adds a new entry in the storage_pools_nodes table. // // It should only be used when a new node joins the cluster, when it's safe to // assume that the relevant pool has already been created on the joining node, // and we just need to track it.
c176778
// StoragePoolNodeJoinCeph updates internal state to reflect that nodeID is // joining a cluster where poolID is a ceph pool.
c176779
// StoragePoolConfigAdd adds a new entry in the storage_pools_config table
c176780
// StoragePoolCreatePending creates a new pending storage pool on the node with // the given name.
c176781
// StoragePoolCreated sets the state of the given pool to "Created".
c176782
// StoragePoolErrored sets the state of the given pool to "Errored".
c176783
// StoragePoolNodeConfigs returns the node-specific configuration of all // nodes grouped by node name, for the given poolID. // // If the storage pool is not defined on all nodes, an error is returned.
c176784
// StoragePoolsGetDrivers returns the names of all storage volumes attached to // a given storage pool.
c176785
// StoragePoolGetID returns the id of a single storage pool.
c176786
// StoragePoolGet returns a single storage pool.
c176787
// Return the names of the nodes the given pool is defined on.
c176788
// StoragePoolConfigGet returns the config of a storage pool.
c176789
// StoragePoolCreate creates new storage pool.
c176790
// Add new storage pool config.
c176791
// StoragePoolUpdate updates a storage pool.
c176792
// StoragePoolConfigClear deletes the storage pool config.
c176793
// StoragePoolDelete deletes storage pool.
c176794
// StoragePoolVolumesGetNames gets the names of all storage volumes attached to // a given storage pool.
c176795
// StoragePoolVolumesGet returns all storage volumes attached to a given // storage pool on any node.
c176796
// StoragePoolNodeVolumesGet returns all storage volumes attached to a given // storage pool on the current node.
c176797
// Returns all storage volumes attached to a given storage pool on the given // node.
c176798
// StoragePoolVolumesGetType get all storage volumes attached to a given // storage pool of a given volume type, on the given node.
c176799
// StoragePoolVolumeSnapshotsGetType get all snapshots of a storage volume // attached to a given storage pool of a given volume type, on the given node.