mirror of
https://github.com/fumiama/terasu-cloudflared.git
synced 2026-06-16 08:20:24 +08:00
TUN-3581: Tunnels can be run by name using only --credentials-file, no
origin cert necessary.
This commit is contained in:
@@ -22,9 +22,23 @@ type Config struct {
|
||||
}
|
||||
|
||||
type NamedTunnelConfig struct {
|
||||
Auth pogs.TunnelAuth
|
||||
ID uuid.UUID
|
||||
Client pogs.ClientInfo
|
||||
Credentials Credentials
|
||||
Client pogs.ClientInfo
|
||||
}
|
||||
|
||||
// Credentials are stored in the credentials file and contain all info needed to run a tunnel.
|
||||
type Credentials struct {
|
||||
AccountTag string
|
||||
TunnelSecret []byte
|
||||
TunnelID uuid.UUID
|
||||
TunnelName string
|
||||
}
|
||||
|
||||
func (c *Credentials) Auth() pogs.TunnelAuth {
|
||||
return pogs.TunnelAuth{
|
||||
AccountTag: c.AccountTag,
|
||||
TunnelSecret: c.TunnelSecret,
|
||||
}
|
||||
}
|
||||
|
||||
type ClassicTunnelConfig struct {
|
||||
|
||||
Reference in New Issue
Block a user