diff --git a/hopsworks-IT/src/test/ruby/spec/git_spec.rb b/hopsworks-IT/src/test/ruby/spec/git_spec.rb index 4b9c93a8a2..90c0f91e16 100644 --- a/hopsworks-IT/src/test/ruby/spec/git_spec.rb +++ b/hopsworks-IT/src/test/ruby/spec/git_spec.rb @@ -214,6 +214,14 @@ end end describe "Perform operations on the cloned repositories" do + before(:all) do + setVar("enable_read_only_git_repositories", "false") + create_session(@project[:username], "Pass123") + end + after(:all) do + setVar("enable_read_only_git_repositories", "true") + create_session(@project[:username], "Pass123") + end after :each do get_project_git_repositories(@project[:id]) if json_body[:count] > 0 diff --git a/hopsworks-common/src/main/java/io/hops/hopsworks/common/git/GitExecutionController.java b/hopsworks-common/src/main/java/io/hops/hopsworks/common/git/GitExecutionController.java index 49d847f7d3..883cfbbf44 100644 --- a/hopsworks-common/src/main/java/io/hops/hopsworks/common/git/GitExecutionController.java +++ b/hopsworks-common/src/main/java/io/hops/hopsworks/common/git/GitExecutionController.java @@ -227,8 +227,8 @@ private GitRepository finalizeSuccessfulExecution(GitOpExecution execution, } if (executedCommandConfig.getCommandType() == GitCommandType.ADD_REMOTE || executedCommandConfig.getCommandType() == GitCommandType.DELETE_REMOTE) { - //Update the remotes which are in the execution final message - String remotesJson = execution.getCommandResultMessage(); + //Update the remotes which are in the stateDTO final message + String remotesJson = stateDTO.getMessage(); if (!Strings.isNullOrEmpty(remotesJson)) { gitRepositoryRemotesFacade.updateRepositoryRemotes(gitCommandOperationUtil.convertToRemote(repository, remotesJson), repository);