SlideShare una empresa de Scribd logo
1 de 49
Descargar para leer sin conexión
Solving the Workflow
or how MODX.today is being managed
across 3 servers with Git & Gitify
Who am I?!
Mark Hamstra
Founder & CEA at modmore
Freelance MODX Developer
Not me
Turbo
Bommel
Solving the Workflow
Introducing the project: MODX.today
Introducing the tools: Gitify & Git
Putting it together: designing a Workflow
Setting up automatic deployments
What is MODX.today?
MODX.today
• Daily-ish posts about MODX
• Weekly newsletter / reading list
• Open source, looking for guest authors
• Launched April 22nd
• 5500+ pageviews, average time on site 2:25 min
github.com/modmore/MODX.today
Solving the Workflow
Introducing the project: MODX.today
Introducing the tools: Gitify & Git
Putting it together: designing a Workflow
Setting up automatic deployments
What is Gitify?
Gitify is not…
• A complete, all-in-one, drag-and-drop solution with
a fancy user interface with buttons and animations
• The only way to have a workflow in MODX
But, Gitify is…
• A useful addition to your toolkit
• Flexible to mix & match with other tools
• Built on top of Symfony2 Console
• Open source!
With Gitify, you can…
• easily create file representations of any object
• create a functional site from those files
• install MODX and packages
• create mysql backups (and restore them)
Installing Gitify
• Go to https://github.com/modmore/Gitify and follow the
instructions. Basically:
• $ git clone https://github.com/modmore/
Gitify.git Gitify
• $ cd Gitify
• $ composer install (or php composer.phar install)
• $ chmod +x Gitify
• Add Gitify to your $PATH - check the wiki
Running Gitify
$ Gitify init
• Sets up a new Gitify configuration
file interactively.
• --overwrite flag allows you to
create a new config file if one
already exists.
.gitify file
data_directory: _data/
backup_directory: _backup/
data:
contexts:
class: modContext
primary: key
content:
type: content
exclude_keys:
- editedby
- editedon
categories:
class: modCategory
primary: category
templates:
class: modTemplate
primary: templatename
template_variables:
class: modTemplateVar
primary: name
packages:
modx.com:
service_url: http://
rest.modx.com/extras/
packages:
- ace
- breadcrumbs
- collections
- getresources
- getcache
- seopro
- translit
- templateselect
- wayfinder
$ Gitify extract
• Looks at your .gitify configuration
to extract data from MODX,
which is written to files in your
data directory.
• Allows specifying any number of
partitions (directories/types) you
want extracted
Gitify Extract (#2)
id: 4
templatename: 'Empty Content'
description: 'Default Template with
empty Content Area'
properties: 'a:0:{}'
-----
[[$template.head]]
[[$template.header]]
<!-- #content -->
<div id="content" role="main">
[[*content]]
</div>
<!-- / #content -->
[[$template.footer]]
• Reads the gitify directory, and
builds it into the MODX install
• —force flag clears all data first
• —skip-clear-cache flag allows
building without clearing cache
• —no-backup allows skipping
creating a backup with —force
• —no-cleanup allows skipping
cleaning up orphaned objects
$ Gitify build
Build Magic
• Automatically resolves ID conflicts by analysing
existing and already built objects
• Cleans up orphaned objects from the database
• Still respects where conditions in .gitify
$ Gitify modx:install
• Downloads and installs a version
of MODX all from the command
line.
• [modx_version] argument lets
you define a version (e.g. 2.3.2-pl)
that will be installed.Without it,
the latest version will be grabbed.
$ Gitify package:install
• Downloads and installs a package
(extra) into the MODX installation.
• —all option will look at the .gitify file
and automatically install each of the
packages defined there.
• —interactive option allows to
interactively search and install packages
when used with —all.
• [package_name] argument accepts a
partial name of the package which it will
then try to find in the package provider.
$ Gitify backup
• Creates a backup of your MySQL
database using mysqldump
• [name] the filename for the
backup file
$ Gitify restore
• Restores a backup created with
Gitify backup.
• [file] If you know the filename,
you can pass it directly. Otherwise
you will get an interactive list of
the available backups that can be
restored.
Solving the Workflow
Introducing the project: MODX.today
Introducing the tools: Gitify & Git
Putting it together: designing a Workflow
Setting up automatic deployments
The Workflow
Git Repository
The Workflow
Git Repository
develop production
staging
The Workflow
site.com
Git Repository
site.dev
staging.site.com
develop production
staginggit push
git pull
gitpush
gitpull
git pull
The Workflow
site.com
Git Repository
site.dev
staging.site.com
develop production
staging
git merge git merge
The Workflow
site.com
Git Repository
staging.site.com
develop production
staging
site.dev
Commit Changes to Git
Synchronise with Git Repository
Gitify extract
Build stuff in MODX
Gitify build
The Workflow
site.com
Git Repository
staging.site.com
develop production
staging
Commit Changes to Git
Synchronise with Git Repository
(Gitify extract)
Make a Change
in Gitify Files
Gitify build
Test changes
site.dev
The Workflow
site.com
Git Repository
site.dev
staging.site.com
develop production
staging
The Workflow
site.com
Git Repository
site.dev
develop production
staging
Gitify Watch
Schedules Extract
Make change in MODX
staging.site.com
Gitify extract
git add -a
git commit
gitpush
The Workflow
site.com
Git Repository
site.dev
staging.site.com
develop production
staging
The Workflow
site.com
Git Repository
site.dev
staging.site.com
develop production
staging deploy
Solving the Workflow
Introducing the project: MODX.today
Introducing the tools: Gitify & Git
Putting it together: designing a Workflow
Setting up automatic deployments
Setting up a Site from Gitify
1. Clone the Repository, checkout proper branch
2. Install MODX (Gitify modx:install
[version])
3. Install defined packages (Gitify
package:install —all)
4. Build from files (Gitify build)
Updating a Site from Gitify
1. Pull in the latest version of the repository
2. Install defined packages (Gitify
install:package —all)
3. Build from files (Gitify build)
Handling Automatic Deploys (#1)
• Use a Github/Gitlab/Bitbucket webhook that requests
a PHP script like this:

<?php
`git fetch origin`;
`git reset --hard origin/production`;
`git pull origin production`;
`Gitify install:package —all`;
`Gitify build —force`;
Handling Automatic Deploys (#2)
• Use a CI / Deployment service / tool: dploy.io
The End
Useful links:

• MODX.today
• MODX.today/submit
• github.com/modmore/Gitify
• github.com/modmore/Gitify/wiki/Home
• github.com/modmore/MODX.today

Más contenido relacionado

La actualidad más candente

Git and GitHub
Git and GitHubGit and GitHub
Git and GitHubRick Umali
 
Workflows using Git GitHub | Edureka
Workflows using Git GitHub | EdurekaWorkflows using Git GitHub | Edureka
Workflows using Git GitHub | EdurekaEdureka!
 
GitLab as an Alternative Development Platform for Github.com
GitLab as an Alternative Development Platform for Github.comGitLab as an Alternative Development Platform for Github.com
GitLab as an Alternative Development Platform for Github.comB1 Systems GmbH
 
Introduction to git and github
Introduction to git and githubIntroduction to git and github
Introduction to git and githubAderemi Dadepo
 
Introduction to Git and Github
Introduction to Git and Github Introduction to Git and Github
Introduction to Git and Github Max Claus Nunes
 
Whats new in VSTS and TFS 2018 Build and release
Whats new in VSTS and TFS 2018 Build and releaseWhats new in VSTS and TFS 2018 Build and release
Whats new in VSTS and TFS 2018 Build and releaseJeff Przylucki
 
Introduction to git administration
Introduction to git administrationIntroduction to git administration
Introduction to git administrationShawn Doyle
 
Enterprise git
Enterprise gitEnterprise git
Enterprise gitPedro Melo
 
Gerrit Code Review with GitHub plugin
Gerrit Code Review with GitHub pluginGerrit Code Review with GitHub plugin
Gerrit Code Review with GitHub pluginLuca Milanesio
 
Building a dev pipeline using GitHub Actions, Node.js, and AWS ECS Fargate
Building a dev pipeline using GitHub Actions, Node.js, and AWS ECS FargateBuilding a dev pipeline using GitHub Actions, Node.js, and AWS ECS Fargate
Building a dev pipeline using GitHub Actions, Node.js, and AWS ECS Fargatedatree
 
JHipster overview and roadmap (August 2017)
JHipster overview and roadmap (August 2017)JHipster overview and roadmap (August 2017)
JHipster overview and roadmap (August 2017)Julien Dubois
 
Git & GitHub
Git & GitHubGit & GitHub
Git & GitHubCuong Ngo
 
Git presentation
Git presentationGit presentation
Git presentationEdson Celio
 
Webkit Chromium Contribution Process
Webkit Chromium Contribution ProcessWebkit Chromium Contribution Process
Webkit Chromium Contribution ProcessGyuyoung Kim
 

La actualidad más candente (20)

Git and GitHub
Git and GitHubGit and GitHub
Git and GitHub
 
Workflows using Git GitHub | Edureka
Workflows using Git GitHub | EdurekaWorkflows using Git GitHub | Edureka
Workflows using Git GitHub | Edureka
 
Bitbucket
BitbucketBitbucket
Bitbucket
 
GitLab as an Alternative Development Platform for Github.com
GitLab as an Alternative Development Platform for Github.comGitLab as an Alternative Development Platform for Github.com
GitLab as an Alternative Development Platform for Github.com
 
Intro to Git, GitHub, and BitBucket
Intro to Git, GitHub, and BitBucketIntro to Git, GitHub, and BitBucket
Intro to Git, GitHub, and BitBucket
 
Introduction to git and github
Introduction to git and githubIntroduction to git and github
Introduction to git and github
 
Introduction to Git and Github
Introduction to Git and Github Introduction to Git and Github
Introduction to Git and Github
 
Whats new in VSTS and TFS 2018 Build and release
Whats new in VSTS and TFS 2018 Build and releaseWhats new in VSTS and TFS 2018 Build and release
Whats new in VSTS and TFS 2018 Build and release
 
Introduction to git administration
Introduction to git administrationIntroduction to git administration
Introduction to git administration
 
BitBucket presentation
BitBucket presentationBitBucket presentation
BitBucket presentation
 
Enterprise git
Enterprise gitEnterprise git
Enterprise git
 
Gerrit Code Review with GitHub plugin
Gerrit Code Review with GitHub pluginGerrit Code Review with GitHub plugin
Gerrit Code Review with GitHub plugin
 
Github
GithubGithub
Github
 
Building a dev pipeline using GitHub Actions, Node.js, and AWS ECS Fargate
Building a dev pipeline using GitHub Actions, Node.js, and AWS ECS FargateBuilding a dev pipeline using GitHub Actions, Node.js, and AWS ECS Fargate
Building a dev pipeline using GitHub Actions, Node.js, and AWS ECS Fargate
 
JHipster overview and roadmap (August 2017)
JHipster overview and roadmap (August 2017)JHipster overview and roadmap (August 2017)
JHipster overview and roadmap (August 2017)
 
Git n git hub
Git n git hubGit n git hub
Git n git hub
 
Git & Github
Git & GithubGit & Github
Git & Github
 
Git & GitHub
Git & GitHubGit & GitHub
Git & GitHub
 
Git presentation
Git presentationGit presentation
Git presentation
 
Webkit Chromium Contribution Process
Webkit Chromium Contribution ProcessWebkit Chromium Contribution Process
Webkit Chromium Contribution Process
 

Similar a Solving the Workflow - Building MODX.today with Gitify (2015-05-21, Alkmaar)

Building Your First App with Shawn Mcarthy
Building Your First App with Shawn Mcarthy Building Your First App with Shawn Mcarthy
Building Your First App with Shawn Mcarthy MongoDB
 
Using Git to Organize Your Project
Using Git to Organize Your ProjectUsing Git to Organize Your Project
Using Git to Organize Your ProjectManish Suwal 'Enwil'
 
Introduction to git and Github
Introduction to git and GithubIntroduction to git and Github
Introduction to git and GithubWycliff1
 
Git interview questions | Edureka
Git interview questions | EdurekaGit interview questions | Edureka
Git interview questions | EdurekaEdureka!
 
The Basics of Open Source Collaboration With Git and GitHub
The Basics of Open Source Collaboration With Git and GitHubThe Basics of Open Source Collaboration With Git and GitHub
The Basics of Open Source Collaboration With Git and GitHubBigBlueHat
 
.Git for WordPress Developers
.Git for WordPress Developers.Git for WordPress Developers
.Git for WordPress Developersmpvanwinkle
 
Version control git day02
Version control   git day02Version control   git day02
Version control git day02Gourav Varma
 
Improving your responsive workflow with style guides
Improving your responsive workflow with style guidesImproving your responsive workflow with style guides
Improving your responsive workflow with style guidesLuke Brooker
 
Effective Collaboration & Delivery with GitHub and AWS Code Deploy – GitHub
Effective Collaboration & Delivery with GitHub and AWS Code Deploy – GitHubEffective Collaboration & Delivery with GitHub and AWS Code Deploy – GitHub
Effective Collaboration & Delivery with GitHub and AWS Code Deploy – GitHubAmazon Web Services
 
Version control git day03(amarnath dada)
Version control   git day03(amarnath dada)Version control   git day03(amarnath dada)
Version control git day03(amarnath dada)Gourav Varma
 
Open up your platform with Open Source and GitHub
Open up your platform with Open Source and GitHubOpen up your platform with Open Source and GitHub
Open up your platform with Open Source and GitHubScott Graham
 
Git for folk who like GUIs
Git for folk who like GUIsGit for folk who like GUIs
Git for folk who like GUIsTim Osborn
 
Version control git day03
Version control   git day03Version control   git day03
Version control git day03Gourav Varma
 
Git 101: Git and GitHub for Beginners
Git 101: Git and GitHub for Beginners Git 101: Git and GitHub for Beginners
Git 101: Git and GitHub for Beginners HubSpot
 
Introduction to Git
Introduction to GitIntroduction to Git
Introduction to Gitatishgoswami
 

Similar a Solving the Workflow - Building MODX.today with Gitify (2015-05-21, Alkmaar) (20)

Building Your First App with Shawn Mcarthy
Building Your First App with Shawn Mcarthy Building Your First App with Shawn Mcarthy
Building Your First App with Shawn Mcarthy
 
Using Git to Organize Your Project
Using Git to Organize Your ProjectUsing Git to Organize Your Project
Using Git to Organize Your Project
 
Introduction to git and Github
Introduction to git and GithubIntroduction to git and Github
Introduction to git and Github
 
Advance workshop on git
Advance workshop on gitAdvance workshop on git
Advance workshop on git
 
Git interview questions | Edureka
Git interview questions | EdurekaGit interview questions | Edureka
Git interview questions | Edureka
 
The Basics of Open Source Collaboration With Git and GitHub
The Basics of Open Source Collaboration With Git and GitHubThe Basics of Open Source Collaboration With Git and GitHub
The Basics of Open Source Collaboration With Git and GitHub
 
Git hub visualstudiocode
Git hub visualstudiocodeGit hub visualstudiocode
Git hub visualstudiocode
 
.Git for WordPress Developers
.Git for WordPress Developers.Git for WordPress Developers
.Git for WordPress Developers
 
Version control git day02
Version control   git day02Version control   git day02
Version control git day02
 
Improving your responsive workflow with style guides
Improving your responsive workflow with style guidesImproving your responsive workflow with style guides
Improving your responsive workflow with style guides
 
Effective Collaboration & Delivery with GitHub and AWS Code Deploy – GitHub
Effective Collaboration & Delivery with GitHub and AWS Code Deploy – GitHubEffective Collaboration & Delivery with GitHub and AWS Code Deploy – GitHub
Effective Collaboration & Delivery with GitHub and AWS Code Deploy – GitHub
 
Version control git day03(amarnath dada)
Version control   git day03(amarnath dada)Version control   git day03(amarnath dada)
Version control git day03(amarnath dada)
 
Open up your platform with Open Source and GitHub
Open up your platform with Open Source and GitHubOpen up your platform with Open Source and GitHub
Open up your platform with Open Source and GitHub
 
Git for folk who like GUIs
Git for folk who like GUIsGit for folk who like GUIs
Git for folk who like GUIs
 
GitHub Workflows for Technical Communication
GitHub Workflows for Technical CommunicationGitHub Workflows for Technical Communication
GitHub Workflows for Technical Communication
 
Version control git day03
Version control   git day03Version control   git day03
Version control git day03
 
Demo
DemoDemo
Demo
 
Git 101: Git and GitHub for Beginners
Git 101: Git and GitHub for Beginners Git 101: Git and GitHub for Beginners
Git 101: Git and GitHub for Beginners
 
Git & GitLab
Git & GitLabGit & GitLab
Git & GitLab
 
Introduction to Git
Introduction to GitIntroduction to Git
Introduction to Git
 

Más de Mark Hamstra

The (Long) Road to Commerce 1.0
The (Long) Road to Commerce 1.0The (Long) Road to Commerce 1.0
The (Long) Road to Commerce 1.0Mark Hamstra
 
Improving the MODX Documentation - March 29, 2019
Improving the MODX Documentation - March 29, 2019Improving the MODX Documentation - March 29, 2019
Improving the MODX Documentation - March 29, 2019Mark Hamstra
 
Commerce in 30 minutes (November 15, 2018 at MODX Meetup Maastricht)
Commerce in 30 minutes (November 15, 2018 at MODX Meetup Maastricht)Commerce in 30 minutes (November 15, 2018 at MODX Meetup Maastricht)
Commerce in 30 minutes (November 15, 2018 at MODX Meetup Maastricht)Mark Hamstra
 
MODX Meetup 2018-03-07 - Introduction talk
MODX Meetup 2018-03-07 - Introduction talk MODX Meetup 2018-03-07 - Introduction talk
MODX Meetup 2018-03-07 - Introduction talk Mark Hamstra
 
Unleashing Creative Freedom with MODX (2015-09-08 at PHPAmersfoort)
Unleashing Creative Freedom with MODX (2015-09-08 at PHPAmersfoort)Unleashing Creative Freedom with MODX (2015-09-08 at PHPAmersfoort)
Unleashing Creative Freedom with MODX (2015-09-08 at PHPAmersfoort)Mark Hamstra
 
Unleashing Creative Freedom with MODX (2015-09-03 at GroningenPHP)
Unleashing Creative Freedom with MODX (2015-09-03 at GroningenPHP)Unleashing Creative Freedom with MODX (2015-09-03 at GroningenPHP)
Unleashing Creative Freedom with MODX (2015-09-03 at GroningenPHP)Mark Hamstra
 
Unleashing Creative Freedom with MODX - 2015-08-26 at PHP Zwolle
Unleashing Creative Freedom with MODX - 2015-08-26 at PHP Zwolle Unleashing Creative Freedom with MODX - 2015-08-26 at PHP Zwolle
Unleashing Creative Freedom with MODX - 2015-08-26 at PHP Zwolle Mark Hamstra
 
Unleashing Creative Freedom with MODX (2015-07-21 @ PHP FRL)
Unleashing Creative Freedom with MODX (2015-07-21 @ PHP FRL)Unleashing Creative Freedom with MODX (2015-07-21 @ PHP FRL)
Unleashing Creative Freedom with MODX (2015-07-21 @ PHP FRL)Mark Hamstra
 
MODX Weekend 2014 - Welcome Slides
MODX Weekend 2014 - Welcome SlidesMODX Weekend 2014 - Welcome Slides
MODX Weekend 2014 - Welcome SlidesMark Hamstra
 
MODXpo 2013 - The Business of Premium - Day 2, 14:30
MODXpo 2013 - The Business of Premium - Day 2, 14:30MODXpo 2013 - The Business of Premium - Day 2, 14:30
MODXpo 2013 - The Business of Premium - Day 2, 14:30Mark Hamstra
 

Más de Mark Hamstra (10)

The (Long) Road to Commerce 1.0
The (Long) Road to Commerce 1.0The (Long) Road to Commerce 1.0
The (Long) Road to Commerce 1.0
 
Improving the MODX Documentation - March 29, 2019
Improving the MODX Documentation - March 29, 2019Improving the MODX Documentation - March 29, 2019
Improving the MODX Documentation - March 29, 2019
 
Commerce in 30 minutes (November 15, 2018 at MODX Meetup Maastricht)
Commerce in 30 minutes (November 15, 2018 at MODX Meetup Maastricht)Commerce in 30 minutes (November 15, 2018 at MODX Meetup Maastricht)
Commerce in 30 minutes (November 15, 2018 at MODX Meetup Maastricht)
 
MODX Meetup 2018-03-07 - Introduction talk
MODX Meetup 2018-03-07 - Introduction talk MODX Meetup 2018-03-07 - Introduction talk
MODX Meetup 2018-03-07 - Introduction talk
 
Unleashing Creative Freedom with MODX (2015-09-08 at PHPAmersfoort)
Unleashing Creative Freedom with MODX (2015-09-08 at PHPAmersfoort)Unleashing Creative Freedom with MODX (2015-09-08 at PHPAmersfoort)
Unleashing Creative Freedom with MODX (2015-09-08 at PHPAmersfoort)
 
Unleashing Creative Freedom with MODX (2015-09-03 at GroningenPHP)
Unleashing Creative Freedom with MODX (2015-09-03 at GroningenPHP)Unleashing Creative Freedom with MODX (2015-09-03 at GroningenPHP)
Unleashing Creative Freedom with MODX (2015-09-03 at GroningenPHP)
 
Unleashing Creative Freedom with MODX - 2015-08-26 at PHP Zwolle
Unleashing Creative Freedom with MODX - 2015-08-26 at PHP Zwolle Unleashing Creative Freedom with MODX - 2015-08-26 at PHP Zwolle
Unleashing Creative Freedom with MODX - 2015-08-26 at PHP Zwolle
 
Unleashing Creative Freedom with MODX (2015-07-21 @ PHP FRL)
Unleashing Creative Freedom with MODX (2015-07-21 @ PHP FRL)Unleashing Creative Freedom with MODX (2015-07-21 @ PHP FRL)
Unleashing Creative Freedom with MODX (2015-07-21 @ PHP FRL)
 
MODX Weekend 2014 - Welcome Slides
MODX Weekend 2014 - Welcome SlidesMODX Weekend 2014 - Welcome Slides
MODX Weekend 2014 - Welcome Slides
 
MODXpo 2013 - The Business of Premium - Day 2, 14:30
MODXpo 2013 - The Business of Premium - Day 2, 14:30MODXpo 2013 - The Business of Premium - Day 2, 14:30
MODXpo 2013 - The Business of Premium - Day 2, 14:30
 

Último

Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Enterprise Knowledge
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slidevu2urc
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)wesley chun
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?Antenna Manufacturer Coco
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 

Último (20)

Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 

Solving the Workflow - Building MODX.today with Gitify (2015-05-21, Alkmaar)

  • 1. Solving the Workflow or how MODX.today is being managed across 3 servers with Git & Gitify
  • 2. Who am I?! Mark Hamstra Founder & CEA at modmore Freelance MODX Developer Not me Turbo Bommel
  • 3. Solving the Workflow Introducing the project: MODX.today Introducing the tools: Gitify & Git Putting it together: designing a Workflow Setting up automatic deployments
  • 5. MODX.today • Daily-ish posts about MODX • Weekly newsletter / reading list • Open source, looking for guest authors • Launched April 22nd • 5500+ pageviews, average time on site 2:25 min
  • 6.
  • 7.
  • 8.
  • 9.
  • 10.
  • 11.
  • 12.
  • 13.
  • 15. Solving the Workflow Introducing the project: MODX.today Introducing the tools: Gitify & Git Putting it together: designing a Workflow Setting up automatic deployments
  • 17. Gitify is not… • A complete, all-in-one, drag-and-drop solution with a fancy user interface with buttons and animations • The only way to have a workflow in MODX
  • 18. But, Gitify is… • A useful addition to your toolkit • Flexible to mix & match with other tools • Built on top of Symfony2 Console • Open source!
  • 19. With Gitify, you can… • easily create file representations of any object • create a functional site from those files • install MODX and packages • create mysql backups (and restore them)
  • 20. Installing Gitify • Go to https://github.com/modmore/Gitify and follow the instructions. Basically: • $ git clone https://github.com/modmore/ Gitify.git Gitify • $ cd Gitify • $ composer install (or php composer.phar install) • $ chmod +x Gitify • Add Gitify to your $PATH - check the wiki
  • 22. $ Gitify init • Sets up a new Gitify configuration file interactively. • --overwrite flag allows you to create a new config file if one already exists.
  • 23. .gitify file data_directory: _data/ backup_directory: _backup/ data: contexts: class: modContext primary: key content: type: content exclude_keys: - editedby - editedon categories: class: modCategory primary: category templates: class: modTemplate primary: templatename template_variables: class: modTemplateVar primary: name packages: modx.com: service_url: http:// rest.modx.com/extras/ packages: - ace - breadcrumbs - collections - getresources - getcache - seopro - translit - templateselect - wayfinder
  • 24. $ Gitify extract • Looks at your .gitify configuration to extract data from MODX, which is written to files in your data directory. • Allows specifying any number of partitions (directories/types) you want extracted
  • 25. Gitify Extract (#2) id: 4 templatename: 'Empty Content' description: 'Default Template with empty Content Area' properties: 'a:0:{}' ----- [[$template.head]] [[$template.header]] <!-- #content --> <div id="content" role="main"> [[*content]] </div> <!-- / #content --> [[$template.footer]]
  • 26. • Reads the gitify directory, and builds it into the MODX install • —force flag clears all data first • —skip-clear-cache flag allows building without clearing cache • —no-backup allows skipping creating a backup with —force • —no-cleanup allows skipping cleaning up orphaned objects $ Gitify build
  • 27.
  • 28. Build Magic • Automatically resolves ID conflicts by analysing existing and already built objects • Cleans up orphaned objects from the database • Still respects where conditions in .gitify
  • 29. $ Gitify modx:install • Downloads and installs a version of MODX all from the command line. • [modx_version] argument lets you define a version (e.g. 2.3.2-pl) that will be installed.Without it, the latest version will be grabbed.
  • 30. $ Gitify package:install • Downloads and installs a package (extra) into the MODX installation. • —all option will look at the .gitify file and automatically install each of the packages defined there. • —interactive option allows to interactively search and install packages when used with —all. • [package_name] argument accepts a partial name of the package which it will then try to find in the package provider.
  • 31. $ Gitify backup • Creates a backup of your MySQL database using mysqldump • [name] the filename for the backup file
  • 32. $ Gitify restore • Restores a backup created with Gitify backup. • [file] If you know the filename, you can pass it directly. Otherwise you will get an interactive list of the available backups that can be restored.
  • 33. Solving the Workflow Introducing the project: MODX.today Introducing the tools: Gitify & Git Putting it together: designing a Workflow Setting up automatic deployments
  • 36. The Workflow site.com Git Repository site.dev staging.site.com develop production staginggit push git pull gitpush gitpull git pull
  • 38. The Workflow site.com Git Repository staging.site.com develop production staging site.dev Commit Changes to Git Synchronise with Git Repository Gitify extract Build stuff in MODX Gitify build
  • 39. The Workflow site.com Git Repository staging.site.com develop production staging Commit Changes to Git Synchronise with Git Repository (Gitify extract) Make a Change in Gitify Files Gitify build Test changes site.dev
  • 41. The Workflow site.com Git Repository site.dev develop production staging Gitify Watch Schedules Extract Make change in MODX staging.site.com Gitify extract git add -a git commit gitpush
  • 44. Solving the Workflow Introducing the project: MODX.today Introducing the tools: Gitify & Git Putting it together: designing a Workflow Setting up automatic deployments
  • 45. Setting up a Site from Gitify 1. Clone the Repository, checkout proper branch 2. Install MODX (Gitify modx:install [version]) 3. Install defined packages (Gitify package:install —all) 4. Build from files (Gitify build)
  • 46. Updating a Site from Gitify 1. Pull in the latest version of the repository 2. Install defined packages (Gitify install:package —all) 3. Build from files (Gitify build)
  • 47. Handling Automatic Deploys (#1) • Use a Github/Gitlab/Bitbucket webhook that requests a PHP script like this:
 <?php `git fetch origin`; `git reset --hard origin/production`; `git pull origin production`; `Gitify install:package —all`; `Gitify build —force`;
  • 48. Handling Automatic Deploys (#2) • Use a CI / Deployment service / tool: dploy.io
  • 49. The End Useful links:
 • MODX.today • MODX.today/submit • github.com/modmore/Gitify • github.com/modmore/Gitify/wiki/Home • github.com/modmore/MODX.today