Content Type in source control - best practice

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

Content Type in source control - best practice

Arjen
Hi all,

I've got a number of content types that I defined manually in the web portal during development/testing.
Now I've trying to find a way of getting the content type definitions into source control as well as deploying the content types to a staging server.

I looked at the Content Type REST API and I guess I can write a plugin that calls this REST API when it's deployed and by doing so makes sure my custom content types get created etc, but this approach feel a bit rough to me.

So, is there an 'official'/best practice way of deploying and managing content types and relationships?

Thanks
Arjen

--
http://dotcms.com - Open Source Java Content Management
---
You received this message because you are subscribed to the Google Groups "dotCMS User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/dotcms/d7db1691-5e56-4249-80b1-e5f78a5265ea%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Content Type in source control - best practice

Xander
There is currently no easy way to add Content Types (and many other things) to source control. You'd need to create your own way to export/import them to source control. We try to add all code in templates, containers, widgets and custom code fields to VTL files which can be exported to source control.

For deploying to another server you can use push publishing.

Kind regards,

Xander

--
http://dotcms.com - Open Source Java Content Management
---
You received this message because you are subscribed to the Google Groups "dotCMS User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/dotcms/9ce2d73b-f856-4857-b363-be059c63c7aa%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Content Type in source control - best practice

Arjen
Ah ok, thanks Xander.
I'll have to read up on that though but will give it a try.

Arjen


On Monday, August 14, 2017 at 11:04:23 AM UTC+1, Xander Steinmann wrote:
There is currently no easy way to add Content Types (and many other things) to source control. You'd need to create your own way to export/import them to source control. We try to add all code in templates, containers, widgets and custom code fields to VTL files which can be exported to source control.

For deploying to another server you can use push publishing.

Kind regards,

Xander

--
http://dotcms.com - Open Source Java Content Management
---
You received this message because you are subscribed to the Google Groups "dotCMS User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/dotcms/d2956e61-b58d-490b-b911-40b8bf39e106%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Content Type in source control - best practice

Pete DeGraw
In reply to this post by Arjen
We have been wrestling with this since day one with our three environments. Our environments get out of sync regularly with our team of 6 developers. It's a major frustration with dotCMS' strange approach to Content Types. A JSON or YAML file would be much better in defining content types.

On Monday, August 14, 2017 at 2:31:53 AM UTC-7, Arjen wrote:
Hi all,

I've got a number of content types that I defined manually in the web portal during development/testing.
Now I've trying to find a way of getting the content type definitions into source control as well as deploying the content types to a staging server.

I looked at the Content Type REST API and I guess I can write a plugin that calls this REST API when it's deployed and by doing so makes sure my custom content types get created etc, but this approach feel a bit rough to me.

So, is there an 'official'/best practice way of deploying and managing content types and relationships?

Thanks
Arjen

--
http://dotcms.com - Open Source Java Content Management
---
You received this message because you are subscribed to the Google Groups "dotCMS User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/dotcms/0c7ce872-3d63-43d7-9cec-89f12de0c600%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Content Type in source control - best practice

Pete DeGraw
In reply to this post by Arjen
We have been wrestling with this since day one with our three environments. Our environments get out of sync regularly with our team of 6 developers. It's a major frustration with dotCMS' strange approach to Content Types. A JSON or YAML file would be much better in defining content types.

--
http://dotcms.com - Open Source Java Content Management
---
You received this message because you are subscribed to the Google Groups "dotCMS User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/dotcms/28787468-1d5e-414e-abe1-d17ed8c1af62%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Content Type in source control - best practice

wezell1
Well, good news is that content types can be defined and managed in JSON in dotCMS 4.1:


On Thu, Aug 17, 2017 at 5:58 PM, Pete DeGraw <[hidden email]> wrote:
We have been wrestling with this since day one with our three environments. Our environments get out of sync regularly with our team of 6 developers. It's a major frustration with dotCMS' strange approach to Content Types. A JSON or YAML file would be much better in defining content types.

--
http://dotcms.com - Open Source Java Content Management
---
You received this message because you are subscribed to the Google Groups "dotCMS User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/dotcms/28787468-1d5e-414e-abe1-d17ed8c1af62%40googlegroups.com.

For more options, visit https://groups.google.com/d/optout.



--






3059 Grand Avenue
Suite 410-B
Miami FL 33133
Main: 
305-900-2001 | Direct: 978.294.9429

   

--
http://dotcms.com - Open Source Java Content Management
---
You received this message because you are subscribed to the Google Groups "dotCMS User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/dotcms/CAPL0VyHKgCQ7g%2Bow_p-qp2oztBN6rpWJgJaQXWTR3NrXkHOb_g%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.