Update community branch (#13208)

Co-authored-by: Hannah Cooper <hannah.cooper@portainer.io>
Co-authored-by: Chaim Lev-Ari <chiptus@users.noreply.github.com>
Co-authored-by: Claude <noreply@anthropic.com>
Co-authored-by: Ali <83188384+testA113@users.noreply.github.com>
Co-authored-by: Steven Kang <skan070@gmail.com>
Co-authored-by: Josiah Clumont <josiah.clumont@portainer.io>
Co-authored-by: nickl-portainer <nicholas.loomans@portainer.io>
Co-authored-by: andres-portainer <91705312+andres-portainer@users.noreply.github.com>
Co-authored-by: Oscar Zhou <100548325+oscarzhou-portainer@users.noreply.github.com>
Co-authored-by: ferreiraborgesaxel-design <ferreiraborgesaxel-design@users.noreply.github.com>
This commit is contained in:
Phil Calder
2026-06-09 16:11:47 +12:00
committed by GitHub
parent 580a9fdfcf
commit c60755fbc7
138 changed files with 7486 additions and 2811 deletions
+11 -11
View File
@@ -74,9 +74,9 @@ func (b *GitMethodStackBuilder) prepare(ctx context.Context, payload *StackPaylo
repoConfig.URL = gittypes.SanitizeURL(repoConfig.URL)
src, err := workflows.FindOrCreateGitSource(tx, &portainer.Source{
Name: gittypes.RepoName(repoConfig.URL),
Type: portainer.SourceTypeGit,
GitConfig: &repoConfig,
Name: gittypes.RepoName(repoConfig.URL),
Type: portainer.SourceTypeGit,
Git: &repoConfig,
})
if err != nil {
return fmt.Errorf("failed to find or create source: %w", err)
@@ -84,14 +84,14 @@ func (b *GitMethodStackBuilder) prepare(ctx context.Context, payload *StackPaylo
wf := &portainer.Workflow{
Name: b.stack.Name,
Artifacts: []portainer.ArtifactSources{{
Artifact: portainer.Artifact{
ReferenceName: repoConfig.ReferenceName,
ConfigFilePath: repoConfig.ConfigFilePath,
ConfigHash: repoConfig.ConfigHash,
StackID: b.stack.ID,
},
SourceIDs: []portainer.SourceID{src.ID},
Artifacts: []portainer.Artifact{{
StackID: b.stack.ID,
Files: []portainer.ArtifactFile{{
SourceID: src.ID,
Path: repoConfig.ConfigFilePath,
Ref: repoConfig.ReferenceName,
Hash: repoConfig.ConfigHash,
}},
}},
}
if err := tx.Workflow().Create(wf); err != nil {