Hi, Thanks for the reply,
----- Original Message ----- > From: "Aaron Weitekamp" <[email protected]> > To: "Tomas Kral" <[email protected]> > Cc: "dev" <[email protected]>, "Suraj Deshmukh" > <[email protected]> > Sent: Monday, March 14, 2016 9:16:17 PM > Subject: Re: oc export > > On Mon, Mar 14, 2016 at 11:13 AM, Tomas Kral <[email protected]> wrote: > > > Hi all, > > I'm working on project where we are basically using `oc export` for > > exporting project and importing it to another OpenShift instance. > > > > But it is not working as I would expect. > > > > My understanding of export feature is that it can be used to move > > objects between clusters or projects and I can use `oc export all` to > > move/copy whole project. > > > > I've deployed MLB Parks sample application > > (https://github.com/gshipley/openshift3mlbparks) > > > > Then I'm trying to move it to another project on same cluster using > > command: > > > > oc -n mlbparks export all | oc -n import create -f - > > > > I'm not sure export is what you want when migrating to another project but > I think you need to pass --as-template=<arbitrary_template_name>. It would > also be better to be more selective in your export. Use the label selector > so you just migrate the application and/or specify the objects you want. > > oc -l name=mlbparks -n mlbparks export --as-template=mlbparks > svc,dc,bc,is,route | oc -n import create -f - > Basically we want to use the exported configuration to be imported into Kubernetes and should work there. We are working on the tool called as openshift2nulecule [1] as a part of Project Atomic. > > > > > > > > But I get following errors: > > > > Error from server: replicationControllers "mongodb-1" already exists > > Error from server: Pod "mlbparks-1-build" is forbidden: unable to > > validate against any security context constraint: ...... > > > > Rest of the error and all steps that I'm doing are here: > > http://paste.fedoraproject.org/339618/96469114/ > > > > > > I'm running Origin v1.1.1 > > > > > > Is there something that is fundamentally wrong with my understanding of > > `oc export`? > > [1] https://github.com/projectatomic/openshift2nulecule -- - Suraj Deshmukh (surajd) @surajd_ http://deshmukhsuraj.wordpress.com/ _______________________________________________ dev mailing list [email protected] http://lists.openshift.redhat.com/openshiftmm/listinfo/dev
