Documentation ¶
Index ¶
- Constants
- Variables
- func BootstrapCommand(ctx context.Context, client client.Client, command string) error
- func BootstrapList(ctx context.Context, client client.Client) error
- func ComposeDown(ctx context.Context, client client.Client) (client.ETag, error)
- func ComposeRestart(ctx context.Context, client client.Client, project *composeTypes.Project) error
- func ComposeStart(ctx context.Context, c client.Client, project *compose.Project, force bool) (*defangv1.DeployResponse, error)
- func ComposeStop(ctx context.Context, client client.Client, project *composeTypes.Project) (client.ETag, error)
- func Connect(cluster string) (*client.GrpcClient, types.TenantID)
- func Delete(ctx context.Context, client client.Client, names ...string) (client.ETag, error)deprecated
- func Generate(ctx context.Context, client client.Client, language string, description string) ([]string, error)
- func GenerateLetsEncryptCert(ctx context.Context, client cliClient.Client) error
- func GetExistingToken(fabric string) string
- func GetServices(ctx context.Context, client client.Client, long bool) error
- func GetTenantID(cluster string) types.TenantIDdeprecated
- func GetVersion(ctx context.Context, client client.Client) (string, error)
- func InteractiveAgreeToS(ctx context.Context, client client.Client) error
- func InteractiveLogin(ctx context.Context, client client.Client, gitHubClientId, fabric string) error
- func LoadCompose(filePath string, tenantID types.TenantID) (*compose.Project, error)
- func LoadComposeWithProjectName(filePath string, projectName string) (*compose.Project, error)
- func Logout(ctx context.Context, client client.Client) error
- func MarshalPretty(root string, data proto.Message) ([]byte, error)
- func NewClient(cluster string, projectName string, provider client.Provider) client.Client
- func NonInteractiveAgreeToS(ctx context.Context, client client.Client) error
- func NonInteractiveLogin(ctx context.Context, client client.Client, fabric string) error
- func NormalizeServiceName(s string) string
- func ParseTimeOrDuration(str string) (time.Time, error)
- func PrintObject(root string, data proto.Message) error
- func Restart(ctx context.Context, client client.Client, names ...string) error
- func SecretsDelete(ctx context.Context, client client.Client, names ...string) error
- func SecretsList(ctx context.Context, client client.Client) error
- func SecretsSet(ctx context.Context, client client.Client, name string, value string) error
- func SendMsg(ctx context.Context, client client.Client, subject, _type, id string, ...) error
- func SplitTenantHost(cluster string) (types.TenantID, string)
- func Tail(ctx context.Context, client client.Client, service, etag string, ...) error
- func TearDown(ctx context.Context, client client.Client) error
- func Token(ctx context.Context, client client.Client, clientId string, ...) error
- func Whoami(ctx context.Context, client client.Client) error
- type CancelError
- type ComposeError
- type P
Constants ¶
View Source
const DefaultCluster = "fabric-prod1.defang.dev"
View Source
const (
MiB = 1024 * 1024
)
View Source
const (
RFC3339Micro = "2006-01-02T15:04:05.000000Z07:00" // like RFC3339Nano but with 6 digits of precision
)
Variables ¶
View Source
var ( DoDryRun = false ErrDryRun = errors.New("dry run") )
View Source
var (
DoVerbose = false
)
View Source
var ErrTermsNotAgreed = errors.New("You must agree to the Defang terms of service to use this tool")
Functions ¶
func BootstrapCommand ¶
func ComposeRestart ¶
func ComposeStart ¶
func ComposeStart(ctx context.Context, c client.Client, project *compose.Project, force bool) (*defangv1.DeployResponse, error)
ComposeStart validates a compose project and uploads the services using the client
func ComposeStop ¶
func GenerateLetsEncryptCert ¶
func GetExistingToken ¶
func GetTenantID
deprecated
func InteractiveAgreeToS ¶
func InteractiveLogin ¶
func LoadCompose ¶
func NonInteractiveAgreeToS ¶
func NonInteractiveLogin ¶
func NormalizeServiceName ¶
func ParseTimeOrDuration ¶
ParseTimeOrDuration parses a time string or duration string (e.g. 1h30m) and returns a time.Time. At a minimum, this function supports RFC3339Nano, Go durations, and our own TimestampFormat (local).
func SecretsDelete ¶
func SecretsSet ¶
Types ¶
type CancelError ¶
type CancelError struct { Service string Etag string Last time.Time // contains filtered or unexported fields }
func (*CancelError) Error ¶
func (cerr *CancelError) Error() string
func (*CancelError) Unwrap ¶
func (cerr *CancelError) Unwrap() error
type ComposeError ¶
type ComposeError struct {
// contains filtered or unexported fields
}
func (ComposeError) Unwrap ¶
func (e ComposeError) Unwrap() error
Source Files ¶
- agree_tos.go
- bootstrap.go
- cert.go
- common.go
- compose.go
- composeDown.go
- composeRestart.go
- composeStart.go
- composeStop.go
- compose_validation.go
- connect.go
- delete.go
- generate.go
- getServices.go
- getVersion.go
- login.go
- logout.go
- restart.go
- secretsDelete.go
- secretsList.go
- secretsSet.go
- sendMsg.go
- tail.go
- teardown.go
- token.go
- whoami.go
Click to show internal directories.
Click to hide internal directories.