django - Use an git repo from an existing app with a new app in openshift -
django - Use an git repo from an existing app with a new app in openshift -
i have created app in openshift uses code of mine. django project. want able create new app using rest api create new app utilize existing repo source code. possible? in openshift web console, in existing app section gives url , asks me re-create git clone. url of form
ssh://a_very_large_string@appname-domain.rhcloud.com/~/git/appname.git/
i utilize rest api phone call this
curl -k -x post https://openshift.redhat.com/broker/rest/domains/rhombus/applications --user "username:password" --data "name=client1&cartridge=python-2.7&scale=false&gear_profile=small&initial_git_url=ssh://a_ver_large_string@appname-domain.rhcloud.com/~/git/appname.git/"
but response following:
{"api_version":1.7, "data":null, "messages":[{"exit_code":216,"field":"initial_git_url", "index":null, "severity":"error", "text":"invalid initial git url"} ], "status":"unprocessable_entity", "supported_api_versions":[1.0,1.1,1.2,1.3,1.4,1.5,1.6,1.7], "type":null, "version":"1.7"}
how can obtain git repo url utilize in new application?
from command line, can type in rhc apps
info existing apps - including git url.
here page in documentation if want see it: https://access.redhat.com/site/documentation/en-us/openshift_online/2.0/html/user_guide/viewing_applications_for_a_user.html
you might interested in article on cloning existing application.
this stackoverflow post includes instructions using existing git repo new app on openshift. haven't tried myself yet, looks promising. (the relevant info in first answer, it's downwards little ways, you'll need skim find it.)
django git openshift
Comments
Post a Comment