oficina / equipo Public

Clone
git clone https://amadan.net/oficina/equipo

Plain git — no account needed to clone.

Download

Download this file

1package equipo
2
3import (
4 "amadan.net/oficina/equipo/internal/equipo/setup"
5 "amadan.net/oficina/equipo/internal/runnerproto"
6 "time"
7)
8
9type Runner = setup.Runner
10type RunnerPrincipal = runnerproto.RunnerPrincipal
11type runnerRecord = setup.RunnerRecord
12type runnerEnrolment = setup.EnrolmentRecord
13
14type runnerCredentialRecord struct {
15 ID string `gorm:"primaryKey"`
16 RunnerID string `gorm:"index:runner_credential_runner"`
17 InstanceID string
18 Audience string
19 Person string
20 MachineKeyHash string
21 TokenHash string `gorm:"uniqueIndex:runner_token"`
22 ExpiresAt time.Time
23 RotatedAt *time.Time
24 RevokedAt *time.Time
25}
26
27func (runnerCredentialRecord) TableName() string { return "runner_credentials" }
28
29type runnerRate struct {
30 Key string `gorm:"primaryKey"`
31 WindowStart time.Time
32 Count int
33}
34