3

Trying to access RHDM7 git repository hosted in an OCP environment. This is what I have tryied so far:

  1. Create a project in my OCP instance with :

    oc new-project demo-rhdm7-dtf
    oc create -f https://raw.githubusercontent.com/gpe-mw-training/bxms_decision_mgmt_foundations_lab/master/resources/rhdm7-only.yaml
    oc new-app --name=dm-demo -n demo-rhdm7-dtf --template=rhdm7-only -p RHT_IMAGE_STREAM_NAMESPACE=openshift -p KIE_ADMIN_PWD=test1234! -p MAVEN_REPO_PASSWORD=test1234! -p APPLICATION_NAME=demo
    

    Notes:

  2. Create an space using Decision Central. In my case I am creating the Acme space.

  3. In the created space create a new project, in my case demoinsurance project.
  4. Do a port-forward for the nio git ssh port: 8001. I am following this tutorial example: http://www.schabell.org/2017/03/how-to-access-jboss-brms-internal-git-repo-in-container.html

    oc new-project demo-rhdm7-dtf
    oc port-forward $(oc get pod -l=deploymentconfig=gpte-rhdmcentr --template='{{ range .items }} {{ .metadata.name }} {{ end }}') 8001:8001
    
  5. Try to use your favorite git client and clone:

When trying to clone as in the example (using git protocol through the ssh port) I get:

git clone git://127.0.0.1:8001/Acme-myrepo
...
fatal: protocol error: bad line length character: SSH-

When trying with ssh protocol:

git clone ssh://adminUser@127.0.0.1:8001/Acme-myrepo
...
ssh_dispatch_run_fatal: Connection to 127.0.0.1 port 8001: incorrect signature

fatal: Could not read from remote repository.

When forwarding and using git port (9418)

git clone git://127.0.0.1:9418/Acme-myrepo
fatal: Could not read from remote repository.

Please make sure you have the correct access rights

and the repository exists.

And by the way, by checking the pod's .niogit repository you can see Acme-myrepo.git repository:

$ oc rsh $(oc get pod -l=deploymentconfig=gpte-rhdmcentr --template='{{ range .items }} {{ .metadata.name }} {{ end }}')
$ ls $JBOSS_HOME/standalone/data/bpmsuite/.niogit
Acme-myrepo.git  datasets.git  datasources.git  myrepo.git  plugins.git  preferences.git  security.git  system.git  system_ou

1 Answers1

0

Please Close. After further review:

https://github.com/jboss-container-images/rhdm-7-openshift-image/blob/rhdm70-dev/decisioncentral/image.yaml#L67

allows the use of the following environment variable in the template configuration:

JAVA_OPTS_APPEND = "-Dorg.uberfire.nio.git.ssh.algorithm=RSA"

which allows to use ssh protocol: git clone ssh://@localhost:8001/

and the ssh protocol will request the password for the decision central user.

Note that there is a port-forward from OCP pod to localhost: oc port-forward $(oc get pod -l=deploymeconfig=gpte-rhdmcentr --template='{{ range .items }} {{ .metadata.name }} {{ end }}') 8001:8001

  • Hi Diego, Is there a way to export a project created within Decision Manager 7 to Git or maybe download the project src to local? I don't see the src anywhere in the pod terminal either. Someone asked this a couple months back without any response: https://stackoverflow.com/q/50938708/2986579 Could you help? – Rupesh Sep 17 '18 at 15:24
  • I have added instructions to the ones presented here: stackoverflow.com/q/50938708/2986579 – Diego Torres Fuerte Sep 18 '18 at 16:49