feat: start on a blank container — spawn with empty:true and no repo (skip clone, default worker image); Spawn UI enables blank spawn without repo selection
This commit is contained in:
+6
-3
@@ -298,9 +298,12 @@ func (s *Spawner) runJob(repo, branch, model string, empty bool, sessionID strin
|
||||
lock.Lock()
|
||||
defer lock.Unlock()
|
||||
|
||||
if err := s.cloneOrUpdate(s.ctx, repo, branch, slug); err != nil {
|
||||
s.setJob(sessionID, repo, stateError, "", err.Error())
|
||||
return
|
||||
// blank-container spawn: nothing to clone or update
|
||||
if repo != "" {
|
||||
if err := s.cloneOrUpdate(s.ctx, repo, branch, slug); err != nil {
|
||||
s.setJob(sessionID, repo, stateError, "", err.Error())
|
||||
return
|
||||
}
|
||||
}
|
||||
s.setJob(sessionID, repo, stateBuilding, "", "")
|
||||
if err := s.ensureImage(s.ctx); err != nil {
|
||||
|
||||
Reference in New Issue
Block a user