Documentation ¶
Index ¶
Constants ¶
View Source
const ( //PROJECTADMIN project administrator PROJECTADMIN = 1 //DEVELOPER developer DEVELOPER = 2 //GUEST guest GUEST = 3 )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AccessLog ¶
type AccessLog struct { LogID int `orm:"column(log_id)" json:"LogId"` UserID int `orm:"column(user_id)" json:"UserId"` ProjectID int64 `orm:"column(project_id)" json:"ProjectId"` RepoName string `orm:"column(repo_name)"` RepoTag string `orm:"column(repo_tag)"` GUID string `orm:"column(GUID)" json:"Guid"` Operation string `orm:"column(operation)"` OpTime time.Time `orm:"column(op_time)"` Username string Keywords string BeginTime time.Time BeginTimestamp int64 EndTime time.Time EndTimestamp int64 }
AccessLog holds information about logs which are used to record the actions that user take to the resourses.
type Event ¶
type Event struct { ID string `json:"Id"` TimeStamp time.Time Action string Target *Target Request *Request Actor *Actor }
Event holds the details of a event.
type Manifest ¶
type Manifest struct { SchemaVersion int `json:"schemaVersion"` Name string `json:"name"` Tag string `json:"tag"` Architecture string `json:"architecture"` FsLayers []blobSumItem `json:"fsLayers"` History []histroyItem `json:"history"` }
Manifest ...
type Project ¶
type Project struct { ProjectID int64 `orm:"column(project_id)" json:"ProjectId"` OwnerID int `orm:"column(owner_id)" json:"OwnerId"` Name string `orm:"column(name)"` CreationTime time.Time `orm:"column(creation_time)"` CreationTimeStr string Deleted int `orm:"column(deleted)"` UserID int `json:"UserId"` OwnerName string Public int `orm:"column(public)"` //This field does not have correspondent column in DB, this is just for UI to disable button Togglable bool UpdateTime time.Time `orm:"update_time" json:"update_time"` Role int `json:"role_id"` RepoCount int `json:"repo_count"` }
Project holds the details of a project.
type Repo ¶
type Repo struct {
Repositories []string `json:"repositories"`
}
Repo holds information about repositories.
type RepoItem ¶
type RepoItem struct { ID string `json:"Id"` Parent string `json:"Parent"` Created time.Time `json:"Created"` DurationDays string `json:"Duration Days"` Author string `json:"Author"` Architecture string `json:"Architecture"` DockerVersion string `json:"Docker Version"` Os string `json:"OS"` }
RepoItem holds manifest of an image.
type Role ¶
type Role struct { RoleID int `orm:"column(role_id)" json:"role_id"` RoleCode string `orm:"column(role_code)" json:"role_code"` Name string `orm:"column(name)" json:"role_name"` RoleMask int `orm:"role_mask" json:"role_mask"` }
Role holds the details of a role.
type Target ¶
type Target struct { MediaType string Digest string Repository string URL string `json:"Url"` Tag string }
Target holds information about the target of a event.
type User ¶
type User struct { UserID int `orm:"column(user_id)" json:"UserId"` Username string `orm:"column(username)" json:"username"` Email string `orm:"column(email)" json:"email"` Password string `orm:"column(password)" json:"password"` Realname string `orm:"column(realname)" json:"realname"` Comment string `orm:"column(comment)" json:"comment"` Deleted int `orm:"column(deleted)"` Rolename string RoleID int `json:"RoleId"` RoleList []Role HasAdminRole int `orm:"column(sysadmin_flag)"` ResetUUID string `orm:"column(reset_uuid)" json:"ResetUuid"` Salt string `orm:"column(salt)"` CreationTime time.Time `orm:"creation_time" json:"creation_time"` UpdateTime time.Time `orm:"update_time" json:"update_time"` }
User holds the details of a user.
Click to show internal directories.
Click to hide internal directories.