constants

package
v0.5.0-rc1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 31, 2020 License: Apache-2.0 Imports: 0 Imported by: 13

Documentation

Overview

Package constants provides the defined constant types for Vela.

Usage:

import "github.com/go-vela/types/constants"

Index

Constants

View Source
const (
	// Badge for unknown state
	// <svg xmlns="http://www.w3.org/2000/svg" width="92" height="20">
	//     <linearGradient id="b" x2="0" y2="100%">
	//         <stop offset="0" stop-color="#bbb" stop-opacity=".1"/>
	//         <stop offset="1" stop-opacity=".1"/>
	//     </linearGradient>
	//     <path d="M0 3 a3 3 0 014-3h28v20H3 a3 3 0 01-3-3V3z" fill="#555555"/>
	//     <path d="M92 17 a3 3 0 01-3 3H32V0h56 a3 3 0 014 3v12z" fill="#9f9f9f"/>
	//     <rect width="100%" height="100%" rx="3" fill="url(#b)"/>
	//     <g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="11">
	//         <text x="16" y="14" fill="#010101" fill-opacity=".3" textLength="24" lengthAdjust="spacing">vela</text>
	//         <text x="16" y="13" textLength="24" lengthAdjust="spacing">vela</text>
	//         <text x="62" y="14" fill="#010101" fill-opacity=".3" textLength="52" lengthAdjust="spacing">unknown</text>
	//         <text x="62" y="13" textLength="52" lengthAdjust="spacing">unknown</text>
	//     </g>
	// </svg>
	BadgeUnknown = `` /* 872-byte string literal not displayed */

	// Badge for success state
	// <svg xmlns="http://www.w3.org/2000/svg" width="85" height="20">
	//     <linearGradient id="a" x2="0" y2="100%">
	//         <stop offset="0" stop-color="#bbb" stop-opacity=".1"/>
	//         <stop offset="1" stop-opacity=".1"/>
	//     </linearGradient>
	//     <path d="M0 3 a3 3 0 014-3h30v20H3 a3 3 0 01-3-3V3z" fill="#555555"/>
	//     <path d="M85 17 a3 3 0 01-3 3H32V0h49 a3 3 0 014 3v12z" fill="#44cc11"/>
	//     <rect width="100%" height="100%" rx="3" fill="url(#a)"/>
	//     <g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="11">
	//         <text x="16" y="14" fill="#010101" fill-opacity=".3" textLength="24" lengthAdjust="spacing">vela</text>
	//         <text x="16" y="13" textlength="24" lengthadjust="spacing">vela</text>
	//         <text x="58" y="14" fill="#010101" fill-opacity=".3" textlength="46" lengthadjust="spacing">success</text>
	//         <text x="58" y="13" textlength="46" lengthadjust="spacing">success</text>
	//     </g>
	// </svg>
	BadgeSuccess = `` /* 872-byte string literal not displayed */

	// Badge for failed state
	// <svg xmlns="http://www.w3.org/2000/svg" width="73" height="20">
	//     <linearGradient id="a" x2="0" y2="100%">
	//         <stop offset="0" stop-color="#bbb" stop-opacity=".1"/>
	//         <stop offset="1" stop-opacity=".1"/>
	//     </linearGradient>
	//     <path d="M0 3 a3 3 0 014-3h30v20H3 a3 3 0 01-3-3V3z" fill="#555555"/>
	//     <path d="M73 17 a3 3 0 01-3 3H32V0h37 a3 3 0 014 3v12z" fill="#fe7d37"/>
	//     <rect width="100%" height="100%" rx="3" fill="url(#a)"/>
	//     <g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="11">
	//         <text x="16" y="14" fill="#010101" fill-opacity=".3" textLength="24" lengthAdjust="spacing">vela</text>
	//         <text x="16" y="13" textlength="24" lengthadjust="spacing">vela</text>
	//         <text x="52" y="14" fill="#010101" fill-opacity=".3" textlength="46" lengthadjust="spacing">failed</text>
	//         <text x="52" y="13" textlength="46" lengthadjust="spacing">failed</text>
	//     </g>
	// </svg>
	BadgeFailed = `` /* 870-byte string literal not displayed */

	// Badge for error state
	// <svg xmlns="http://www.w3.org/2000/svg" width="69" height="20">
	//     <linearGradient id="a" x2="0" y2="100%">
	//         <stop offset="0" stop-color="#bbb" stop-opacity=".1"/>
	//         <stop offset="1" stop-opacity=".1"/>
	//     </linearGradient>
	//     <path d="M0 3 a3 3 0 014-3h30v20H3 a3 3 0 01-3-3V3z" fill="#555555"/>
	//     <path d="M69 17 a3 3 0 01-3 3H32V0h33 a3 3 0 014 3v12z" fill="#e05d44"/>
	//     <rect width="100%" height="100%" rx="3" fill="url(#a)"/>
	//     <g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="11">
	//         <text x="16" y="14" fill="#010101" fill-opacity=".3" textLength="24" lengthAdjust="spacing">vela</text>
	//         <text x="16" y="13" textlength="24" lengthadjust="spacing">vela</text>
	//         <text x="50" y="14" fill="#010101" fill-opacity=".3" textlength="46" lengthadjust="spacing">error</text>
	//         <text x="50" y="13" textlength="46" lengthadjust="spacing">error</text>
	//     </g>
	// </svg>
	BadgeError = `` /* 868-byte string literal not displayed */

	// Badge for running status
	// <svg xmlns="http://www.w3.org/2000/svg" width="88" height="20">
	//     <linearGradient id="b" x2="0" y2="100%">
	//         <stop offset="0" stop-color="#bbb" stop-opacity=".1"/>
	//         <stop offset="1" stop-opacity=".1"/>
	//     </linearGradient>
	//     <path d="M0 3 a3 3 0 014-3h28v20H3 a3 3 0 01-3-3V3z" fill="#555555"/>
	//     <path d="M88 17 a3 3 0 01-3 3H32V0h52 a3 3 0 014 3v12z" fill="#dfb317"/>
	//     <rect width="100%" height="100%" rx="3" fill="url(#b)"/>
	//     <g fill="#fff" text-anchor="middle" font-family="DejaVu Sans,Verdana,Geneva,sans-serif" font-size="11">
	//         <text x="16" y="14" fill="#010101" fill-opacity=".3" textLength="24" lengthAdjust="spacing">vela</text>
	//         <text x="16" y="13" textLength="24" lengthAdjust="spacing">vela</text>
	//         <text x="59" y="14" fill="#010101" fill-opacity=".3" textLength="46" lengthAdjust="spacing">running</text>
	//         <text x="59" y="13" textLength="46" lengthAdjust="spacing">running</text>
	//     </g>
	// </svg>
	BadgeRunning = `` /* 872-byte string literal not displayed */
)

build status badges

View Source
const (
	// DriverPostgres defines the driver type when integrating with a PostgreSQL database.
	DriverPostgres = "postgres"

	// DriverSqlite defines the driver type when integrating with a SQLite database.
	DriverSqlite = "sqlite3"
)

server database drivers

View Source
const (
	// DriverLinux defines the driver type when integrating with a linux distribution.
	DriverLinux = "linux"

	// DriverWindows defines the driver type when integrating with a windows distribution.
	DriverWindows = "windows"

	// DriverDarwin defines the driver type when integrating with a darwin distribution.
	DriverDarwin = "darwin"
)

agent executor drivers

View Source
const (

	// DriverKafka defines the driver type when integrating with a Kafka queue.
	DriverKafka = "kafka"

	// DriverRedis defines the driver type when integrating with a Redis queue.
	DriverRedis = "redis"
)

server and agent queue drivers

View Source
const (
	// DriverDocker defines the driver type when integrating with a Docker runtime.
	DriverDocker = "docker"

	// DriverKubernetes defines the driver type when integrating with a Kubernetes runtime.
	DriverKubernetes = "kubernetes"
)

agent runtime drivers

View Source
const (
	// DriverNative defines the driver type when integrating with a Vela secret service.
	DriverNative = "native"

	// DriverVault defines the driver type when integrating with a Vault secret service.
	DriverVault = "vault"
)

server and agent secret drivers

View Source
const (
	// DriverGitHub defines the driver type when integrating with a Github source code system.
	DriverGithub = "github"

	// DriverGitLab defines the driver type when integrating with a Gitlab source code system.
	DriverGitlab = "gitlab"
)

server source drivers

View Source
const (
	// EventPush defines the event type for build and repo push events.
	EventPush = "push"

	// EventPull defines the event type for build and repo pull_request events.
	EventPull = "pull_request"

	// EventTag defines the event type for build and repo tag events.
	EventTag = "tag"

	// EventDeploy defines the event type for build and repo deployment events.
	EventDeploy = "deployment"

	// EventComment defines the event type for comments added to a pull request.
	EventComment = "comment"
)

build and repo events

View Source
const (
	// BuildTimeoutMin defines the minimum value in minutes for repo build timeout.
	BuildTimeoutMin = 30

	// BuildTimeoutMax defines the maximum value in minutes for repo build timeout.
	BuildTimeoutMax = 90

	// FavoritesMaxSize defines the maximum size in characters for user favorites.
	FavoritesMaxSize = 5000
)

limits and constraints

View Source
const (
	// MatcherFilepath defines the ruleset type for the filepath matcher.
	MatcherFilepath = "filepath"

	// MatcherRegex defines the ruleset type for the regex matcher.
	MatcherRegex = "regexp"
)

ruleset matchers

View Source
const (
	// OperatorAnd defines the ruleset type for the and operator.
	OperatorAnd = "and"

	// OperatorOr defines the ruleset type for the or operator.
	OperatorOr = "or"
)

ruleset operators

View Source
const (
	// PipelineStages defines the type for a pipeline with stages.
	PipelineStage = "stages"

	// PipelineStep defines the type for a pipeline with steps.
	PipelineStep = "steps"

	// PipelineTemplate defines the type for a pipeline as a template.
	PipelineTemplate = "template"
)

pipeline types

View Source
const (
	// SecretOrg defines the secret type for a secret scoped to a specific org.
	SecretOrg = "org"

	// SecretRepo defines the secret type for a secret scoped to a specific repo.
	SecretRepo = "repo"

	// SecretShared defines the secret type for a secret shared across the installation.
	SecretShared = "shared"

	// SecretMask defines the secret mask to be used in place of secret values returned to users.
	SecretMask = "[secure]"
)

secret types

View Source
const (
	// StatusError defines the status type for build and step error statuses.
	StatusError = "error"

	// StatusFailure defines the status type for build and step failure statuses.
	StatusFailure = "failure"

	// StatusKilled defines the status type for build and step killed statuses.
	StatusKilled = "killed"

	// StatusPending defines the status type for build and step pending statuses.
	StatusPending = "pending"

	// StatusRunning defines the status type for build and step running statuses.
	StatusRunning = "running"

	// StatusSuccess defines the status type for build and step success statuses.
	StatusSuccess = "success"
)

build and step statuses

View Source
const (
	// TableBuild defines the table type for the database builds table.
	TableBuild = "builds"

	// TableHook defines the table type for the database hooks table.
	TableHook = "hooks"

	// TableLog defines the table type for the database logs table.
	TableLog = "logs"

	// TableRepo defines the table type for the database repos table.
	TableRepo = "repos"

	// TableSecret defines the table type for the database secrets table.
	TableSecret = "secrets"

	// TableService defines the table type for the database services table.
	TableService = "services"

	// TableStep defines the table type for the database steps table.
	TableStep = "steps"

	// TableUser defines the table type for the database users table.
	TableUser = "users"
)

database tables

View Source
const (
	// VisibilityPublic defines the visibility type for allowing any
	// users in Vela to access their repo regardless of the access
	// defined in the source control system.
	VisibilityPublic = "public"

	// VisibilityPrivate defines the visibility type for only allowing
	// users in Vela with pre-defined access in the source control
	// system to access their repo.
	VisibilityPrivate = "private"
)

repo visibility types

View Source
const (
	// DefaultRoute defines the default route all workers listen on.
	DefaultRoute = "vela"
)

queue types

Variables

This section is empty.

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL