Documentation ¶
Index ¶
- func CheckCacheXrootdEnv(exportPath string, server server_structs.XRootDServer, uid int, gid int) (string, error)
- func CheckOriginXrootdEnv(exportPath string, server server_structs.XRootDServer, uid int, gid int, ...) error
- func CheckXrootdEnv(server server_structs.XRootDServer) error
- func ConfigXrootd(ctx context.Context, origin bool) (string, error)
- func ConfigureLaunchers(privileged bool, configPath string, useCMSD bool, enableCache bool) (launchers []daemon.Launcher, err error)
- func CopyXrootdCertificates(server server_structs.XRootDServer) error
- func EmitAuthfile(server server_structs.XRootDServer) error
- func EmitIssuerMetadata(exportPath string, xServeUrl string) error
- func EmitScitokensConfig(server server_structs.XRootDServer) error
- func LaunchDaemons(ctx context.Context, launchers []daemon.Launcher, egrp *errgroup.Group, ...) (pids []int, err error)
- func LaunchXrootdMaintenance(ctx context.Context, server server_structs.XRootDServer, ...)
- func ScanLinesWithCont(data []byte, atEOF bool) (advance int, token []byte, err error)
- func SetUpMonitoring(ctx context.Context, egrp *errgroup.Group) error
- func WriteCacheScitokensConfig(nsAds []server_structs.NamespaceAdV2) error
- func WriteOriginScitokensConfig(exportedPaths []string) error
- type CacheConfig
- type GlobalCfg
- type Issuer
- type LoggingConfig
- type OriginConfig
- type PrivilegedXrootdLauncher
- type ScitokensCfg
- type ServerConfig
- type UnprivilegedXrootdLauncher
- type XrootdConfig
- type XrootdOptions
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckCacheXrootdEnv ¶ added in v1.0.4
func CheckCacheXrootdEnv(exportPath string, server server_structs.XRootDServer, uid int, gid int) (string, error)
func CheckOriginXrootdEnv ¶ added in v1.0.4
func CheckOriginXrootdEnv(exportPath string, server server_structs.XRootDServer, uid int, gid int, groupname string) error
CheckOriginXrootdEnv is almost a misnomer -- it does both checking and configuring. In partcicular, it is responsible for setting up the exports and handling all the symlinking we use to export our directories.
func CheckXrootdEnv ¶ added in v1.0.4
func CheckXrootdEnv(server server_structs.XRootDServer) error
func ConfigXrootd ¶ added in v1.0.4
func ConfigureLaunchers ¶ added in v1.0.4
func CopyXrootdCertificates ¶
func CopyXrootdCertificates(server server_structs.XRootDServer) error
Copies the server certificate/key files into the XRootD runtime directory. Combines the two files into a single one so the new certificate shows up atomically from XRootD's perspective. Adjusts the ownership and mode to match that expected by the XRootD framework.
func EmitAuthfile ¶ added in v1.0.4
func EmitAuthfile(server server_structs.XRootDServer) error
Parse the input xrootd authfile, add any default configurations, and then save it into the xrootd runtime directory
func EmitIssuerMetadata ¶ added in v1.0.4
func EmitScitokensConfig ¶
func EmitScitokensConfig(server server_structs.XRootDServer) error
Writes out the server's scitokens.cfg configuration
func LaunchDaemons ¶
func LaunchXrootdMaintenance ¶
func LaunchXrootdMaintenance(ctx context.Context, server server_structs.XRootDServer, sleepTime time.Duration)
Launch a separate goroutine that performs the XRootD maintenance tasks. For maintenance that is periodic, `sleepTime` is the maintenance period.
func ScanLinesWithCont ¶
Scan through the lines of a file, respecting line continuation characters. That is,
``` foo \ bar ```
Would be parsed as a single line, `foo bar`.
Follows the ScanFunc interface defined by bufio.
func SetUpMonitoring ¶ added in v1.0.4
Set up xrootd monitoring
The `ctx` is the context for listening to server shutdown event in order to cleanup internal cache eviction goroutine and `wg` is the wait group to notify when the clean up goroutine finishes
func WriteCacheScitokensConfig ¶ added in v1.0.4
func WriteCacheScitokensConfig(nsAds []server_structs.NamespaceAdV2) error
Writes out the cache's scitokens.cfg configuration
func WriteOriginScitokensConfig ¶ added in v1.0.4
Writes out the origin's scitokens.cfg configuration
Types ¶
type CacheConfig ¶ added in v1.0.4
type GlobalCfg ¶ added in v1.0.4
type GlobalCfg struct {
Audience []string
}
XRootD server-wide configurations for SciTokens.
type Issuer ¶ added in v1.0.4
type Issuer struct { Name string Issuer string BasePaths []string RestrictedPaths []string MapSubject bool DefaultUser string UsernameClaim string NameMapfile string }
Per-issuer configuration
func GenerateDirectorMonitoringIssuer ¶ added in v1.0.4
We have a special issuer just for director-based monitoring of the origin.
func GenerateMonitoringIssuer ¶ added in v1.0.4
We have a special issuer just for self-monitoring the origin.
func GenerateOriginIssuer ¶ added in v1.0.4
type LoggingConfig ¶
type LoggingConfig struct { OriginCms string OriginHttp string OriginOfs string OriginOss string OriginScitokens string OriginXrd string OriginXrootd string CacheHttp string CacheOfs string CachePfc string CachePss string PssSetOptCache string CacheScitokens string CacheXrd string CacheXrootd string }
type OriginConfig ¶ added in v1.0.4
type OriginConfig struct { Multiuser bool EnableCmsd bool EnableMacaroons bool EnableVoms bool EnablePublicReads bool EnableListings bool SelfTest bool CalculatedPort string FederationPrefix string HttpServiceUrl string RunLocation string StorageType string // S3 specific options that are kept top-level because // they aren't specific to each export S3Region string S3ServiceUrl string S3UrlStyle string Exports []server_utils.OriginExport }
type PrivilegedXrootdLauncher ¶
type PrivilegedXrootdLauncher struct {
// contains filtered or unexported fields
}
func (PrivilegedXrootdLauncher) Name ¶ added in v1.0.4
func (launcher PrivilegedXrootdLauncher) Name() string
type ScitokensCfg ¶ added in v1.0.4
Top-level configuration object for the template
func LoadScitokensConfig ¶ added in v1.0.4
func LoadScitokensConfig(fileName string) (cfg ScitokensCfg, err error)
Given a filename, load and parse the file into a ScitokensCfg object
type ServerConfig ¶ added in v1.0.4
type UnprivilegedXrootdLauncher ¶
type UnprivilegedXrootdLauncher struct { daemon.DaemonLauncher // contains filtered or unexported fields }
type XrootdConfig ¶ added in v1.0.4
type XrootdConfig struct { Server ServerConfig Origin OriginConfig Xrootd XrootdOptions Cache CacheConfig Logging LoggingConfig }
type XrootdOptions ¶ added in v1.0.4
type XrootdOptions struct { Port int ManagerHost string ManagerPort string ConfigFile string MacaroonsKeyFile string RobotsTxtFile string Sitename string SummaryMonitoringHost string SummaryMonitoringPort int DetailedMonitoringHost string DetailedMonitoringPort int Authfile string ScitokensConfig string Mount string LocalMonitoringPort int }