Severity
No response
Version
<= 2026.1
Latest Version
I could reproduce the problem in the latest build
What happened?
If you try to use a project variable or any other octostache expression in the commit to git repository url property, the step will fail when it attempts to parse the octostache expression as a git remote url as it doesn't evaluate the variable before doing so.
Reproduction
- Create a project with a repository url project variable
- Add commit to git step and bind the repository url property to the variable you created earlier
- Attempt to deploy
Error and Stacktrace
Cannot parse #{RepoUri} as a Git URL Octopus.Git.InvalidGitRemoteUrlException at Octopus.Git.GitRemoteUrl.Create(String input) in GitRemoteUrl.cs:line 17 at Octopus.Server.Orchestration.ServerTasks.Deploy.Steps.Git.CommitToGitActionPropertiesLoader.ResolveLibraryGitCredential(GitCredentialId credentialId, String repositoryUrl, CancellationToken cancellationToken) in CommitToGitActionPropertiesLoader.cs:line 103 at Octopus.Server.Orchestration.ServerTasks.Deploy.Steps.Git.CommitToGitActionPropertiesLoader.LoadLibraryCredential(DeploymentAction action, String repositoryUrl, CancellationToken cancellationToken) in CommitToGitActionPropertiesLoader.cs:line 91 at Octopus.Server.Orchestration.ServerTasks.Deploy.Steps.Git.CommitToGitActionPropertiesLoader.Load(DeploymentAction action, SpaceId spaceId, ProjectId projectId, DeploymentEnvironmentId environmentId, TenantId tenantId, CancellationToken cancellationToken) in CommitToGitActionPropertiesLoader.cs:line 65 at Octopus.Core.Orchestration.ServerTasks.Rules.WhenAServerTaskIsStarted.StartExecutionCommandFactory.Create(ServerTask serverTask, Instant startTime, ActivityTraceId activityTraceId, ActivitySpanId activitySpanId, CancellationToken cancellationToken, ProcessExecutionId processExecutionId) in StartExecutionCommandFactory.cs:line 107
More Information
No response
Workaround
Hard code the git repository url in the step's configuration
Severity
No response
Version
<= 2026.1
Latest Version
I could reproduce the problem in the latest build
What happened?
If you try to use a project variable or any other octostache expression in the commit to git repository url property, the step will fail when it attempts to parse the octostache expression as a git remote url as it doesn't evaluate the variable before doing so.
Reproduction
Error and Stacktrace
Cannot parse #{RepoUri} as a Git URL Octopus.Git.InvalidGitRemoteUrlException at Octopus.Git.GitRemoteUrl.Create(String input) in GitRemoteUrl.cs:line 17 at Octopus.Server.Orchestration.ServerTasks.Deploy.Steps.Git.CommitToGitActionPropertiesLoader.ResolveLibraryGitCredential(GitCredentialId credentialId, String repositoryUrl, CancellationToken cancellationToken) in CommitToGitActionPropertiesLoader.cs:line 103 at Octopus.Server.Orchestration.ServerTasks.Deploy.Steps.Git.CommitToGitActionPropertiesLoader.LoadLibraryCredential(DeploymentAction action, String repositoryUrl, CancellationToken cancellationToken) in CommitToGitActionPropertiesLoader.cs:line 91 at Octopus.Server.Orchestration.ServerTasks.Deploy.Steps.Git.CommitToGitActionPropertiesLoader.Load(DeploymentAction action, SpaceId spaceId, ProjectId projectId, DeploymentEnvironmentId environmentId, TenantId tenantId, CancellationToken cancellationToken) in CommitToGitActionPropertiesLoader.cs:line 65 at Octopus.Core.Orchestration.ServerTasks.Rules.WhenAServerTaskIsStarted.StartExecutionCommandFactory.Create(ServerTask serverTask, Instant startTime, ActivityTraceId activityTraceId, ActivitySpanId activitySpanId, CancellationToken cancellationToken, ProcessExecutionId processExecutionId) in StartExecutionCommandFactory.cs:line 107More Information
No response
Workaround
Hard code the git repository url in the step's configuration