Documentation
¶
Index ¶
- Variables
- func ArtifactsUseSaveLoad(cfg *config.Config) bool
- func DeployBuildRemote(cfg *config.Config, opts RunOpts) bool
- func EffectiveDeployPush(cfg *config.Config) bool
- func EffectiveSaveCompress(cfg *config.Config) bool
- func MergeExcludePatterns(cfg *config.Config) []string
- func MirrorProjectTree(c *sftp.Client, localRoot, remoteRoot string, patterns []string) error
- func ModeIsArtifacts(cfg *config.Config) bool
- func PathExcluded(rel string, patterns []string) bool
- func RemoteConfigCheckScript(cfg *config.Config, remoteRoot string) string
- func RemoteRelAppConfig(cfg *config.Config) string
- func Run(projectRoot string, cfg *config.Config) error
- func RunArtifacts(projectRoot string, cfg *config.Config, opts RunOpts) error
- func RunRemoteArtifactsFinish(client *ssh.Client, cfg *config.Config, composeFileOverride string, ...) error
- func RunRemoteReup(client *ssh.Client, cfg *config.Config) error
- func RunSource(projectRoot string, cfg *config.Config) error
- func RunWithOptions(projectRoot string, cfg *config.Config, opts RunOpts) error
- func SyncDeployIncludes(c *sftp.Client, projectRoot, remoteRoot string, cfg *config.Config) error
- func UploadAppConfig(c *sftp.Client, projectRoot, remoteRoot string, cfg *config.Config) error
- type RunOpts
Constants ¶
This section is empty.
Variables ¶
var DefaultExcludePatterns = []string{
".git/",
"data/",
"*.db",
"*.db-shm",
"*.db-wal",
".cursor/",
".env",
"dq.env",
}
DefaultExcludePatterns mirror the historical rsync/SFTP exclude list (readme §4.3).
Functions ¶
func ArtifactsUseSaveLoad ¶
ArtifactsUseSaveLoad matches the former bash deploy script’s registry vs save/load rules.
func DeployBuildRemote ¶ added in v1.1.1
DeployBuildRemote is true when deploy_build_remote is set and a build is requested (same condition as runArtifactBuilds: deploy_push or CLI --build).
func EffectiveDeployPush ¶
EffectiveDeployPush is true when deploy_push is explicitly true.
func EffectiveSaveCompress ¶
EffectiveSaveCompress defaults to true when unset (bash DEPLOY_SAVE_COMPRESS default 1).
func MergeExcludePatterns ¶
MergeExcludePatterns returns defaults plus cfg.Exclude (YAML / merged config).
func MirrorProjectTree ¶
MirrorProjectTree uploads the project tree to remoteRoot via SFTP, mirroring rsync --delete semantics using size + mtime comparison (readme §4.3). Excluded paths are not sent; extra remote files are removed.
func ModeIsArtifacts ¶
ModeIsArtifacts reports deploy_mode == artifacts (case-insensitive).
func PathExcluded ¶
PathExcluded reports whether rel (slash-separated, relative to project root, no leading "./") matches any pattern.
func RemoteConfigCheckScript ¶
RemoteConfigCheckScript returns a bash fragment: no-op if app_config unset, else test -f.
func RemoteRelAppConfig ¶
RemoteRelAppConfig is the path of the app config file relative to remote_path (for test -f on the server).
func RunArtifacts ¶
RunArtifacts builds/pushes or save-loads the image(s), syncs compose + config + includes, then remote pull+up or up (readme §5.3).
func RunRemoteArtifactsFinish ¶
func RunRemoteArtifactsFinish(client *ssh.Client, cfg *config.Config, composeFileOverride string, skipPull bool, exportDeployImage bool) error
RunRemoteArtifactsFinish runs config-check, then pull+up or up only (save/load), with optional compose file override. exportDeployImage adds export DEPLOY_IMAGE=... when true (compose file still references ${DEPLOY_IMAGE}).
func RunRemoteReup ¶
RunRemoteReup runs config-check (if app_config) then docker compose build --pull, up -d, ps on the remote host.
func RunWithOptions ¶
RunWithOptions is like Run but honors CLI flags in opts (e.g. Build).
func SyncDeployIncludes ¶
SyncDeployIncludes uploads extra paths from the project root (readme deploy_include).