mirror of
https://github.com/zitadel/zitadel.git
synced 2025-11-14 00:13:22 +00:00
35 lines
471 B
Go
35 lines
471 B
Go
|
|
package model
|
||
|
|
|
||
|
|
import (
|
||
|
|
"time"
|
||
|
|
|
||
|
|
"github.com/caos/zitadel/internal/eventstore/models"
|
||
|
|
)
|
||
|
|
|
||
|
|
type Machine struct {
|
||
|
|
models.ObjectRoot
|
||
|
|
|
||
|
|
Name string
|
||
|
|
Description string
|
||
|
|
}
|
||
|
|
|
||
|
|
func (sa *Machine) IsValid() bool {
|
||
|
|
return sa.Name != ""
|
||
|
|
}
|
||
|
|
|
||
|
|
type MachineKey struct {
|
||
|
|
models.ObjectRoot
|
||
|
|
|
||
|
|
KeyID string
|
||
|
|
Type MachineKeyType
|
||
|
|
ExpirationDate time.Time
|
||
|
|
PrivateKey []byte
|
||
|
|
}
|
||
|
|
|
||
|
|
type MachineKeyType int32
|
||
|
|
|
||
|
|
const (
|
||
|
|
MachineKeyTypeNONE = iota
|
||
|
|
MachineKeyTypeJSON
|
||
|
|
)
|