SlideShare a Scribd company logo
1 of 47
Sharing is Caring
Who Am I?
• Selling Source Direct Lead
Developer

• Coupla CTO
• Founder/Organizer of Las
Vegas PHP Users Group

• Co-Organizer of Las Vegas
Developers Users Group
• PHP Machinist Maintainer

• #VegasTech Enthusiast

Adam Englander
adamenglander@yahoo.com
@adam_englander
http://adamknowsstuff.com
https://github.com/derptest
What is Dependency
Management?
Dependency management for this context
is best described as the resolution and
installation of library dependencies for a
software project. This includes resolving
potential conflicts between libraries and
providing the dependencies for all libraries
on the dependency tree.
Simple Example of
Dependencies


My Project
 PHP >= 5.5.0
 Monolog >= 1.3.0, < 2.0
○ PHP >= 5.3.0
○ PSR Log >= 1.0, < 2.0
Sharing used to be hard
Legacy Solutions
PEAR
 PECL
 Version Control System Sub-repositories
(SVN, Git, Mercurial)
 Directly adding dependencies to your
codebase
 Custom dependency manager
 Write monolithic code bases

PEAR – PHP Extension and
Application Library






Multiple
Repositories
Private Repositories
Sub-dependency
version resolution
Hundreds of libraries









One package install
per server
No common format
for defining project
dependencies
Not extensible
Each server had to
be aware of
repositories
Publishing required
PECL– PHP Extension
Community Library




Highly trusted
libraries
Hundreds of libraries
Sub-dependency
version resolution









One package install
per server
No common format
for defining project
dependencies
No private repos
Each server had to
be aware of
repositories
Publishing required
VCS Sub-Repositories




Project based
dependencies
Private Repositories
Potentially millions
of libraries







Normally requires
using the external
library’s VCS
No deep
dependency
management
Need to monitor
patches and
updates to external
libraries
Directly adding dependencies
to your codebase




Project based
dependencies
Private Repositories
Potentially millions
of libraries







Project codebases
have dependency
code making them
large and unwieldy
You have to
manually resolve all
dependencies
You have to test
interoperability of all
dependent libraries
Custom Repository
Manager


If you can dream it,
you can do it.




Difficult to write
You must implement
every feature and fix
every bug
Monolithic Code Base




No need for
dependency
management
Private Repositories









Harder to manage
Harder to test
Re-writing the same
code in multiple
projects.
Maintaining the the
same bug fixes in
multiple projects.
No leveraging of
community code
DRY – Don’t repeat yourself or anyone else for that
matter.
The Platform
Composer – The fully self-contained and
completely extensible client
 Satis – The app for generating static
servable repository data.
 Packagist – The server for managing
and maintaining dynamic repository
data.
 Packagist.org – The public Packagist
server for open source libraries and
projects. 21K+ packages.

The alpha and the omega
Composer Overview


Command line client application for:






Searching repositories for packages
Installing project skeletons
Executing install/update hooks
Managing project dependencies
Managing project metadata

Base code for servers
 The only product on the platform
necessary for managing dependencies
in a project

Installation
There
 Download the composer.phar from
http://getcomposer.org/download/
 Use the installer script from
http://getcomposer.org/download/
 Install from your *nix distro package
manager (yum/apt/pkgsrc/homebrew)
Search the repositories
vagrant:/$ composer search monolog
monolog/monolog Sends your logs to files, sockets, inboxes, databases and
various web services
symfony/monolog-bundle Symfony MonologBundle
symfony/monolog-bridge Symfony Monolog Bridge
flynsarmy/slim-monolog Monolog logging support Slim Framework
logentries/logentries-monolog-handler A handler for Monolog that sends
messages to Logentries.com.
kamisama/monolog-init Very basic and light Dependency Injector Container for
Monolog
ddtraceweb/monolog-parser A parser for monolog log entries
lexik/monolog-browser-bundle This Symfony2 bundle provides a Doctrine DBAL
handler for Monolog and a web UI to display log entries
graze/monolog-extensions Monolog extensions for use within Graze
bazo/nette-monolog-extension Nette monolog compiler extension
fancyguy/wordpress-monolog WordPress Monolog Integration
kmelia/monolog-stdout-handler A handler for Monolog that sends messages to
stdout (with color).
support
Installing Project Skeletons
vagrant:/$ composer create-project laravel/laravel --preferdist

Installing laravel/laravel (v4.1.0)
- Installing laravel/laravel (v4.1.0)
Downloading: 100%
Created project in /tmp/laravel
Loading composer repositories with package information
Installing dependencies (including require-dev)
- Installing filp/whoops (1.0.10)
Downloading: 100%
- Installing psr/log (dev-master 65f363a)
Downloading: 100%
…
Executing install/update hooks
vagrant:/$ composer create-project
laravel/laravel --prefer-dist
Installing laravel/laravel (v4.1.0)
- Installing laravel/laravel (v4.1.0)
Downloading: 100%
…
Writing lock file
Generating autoload files
Generating optimized class loader
Application key
[TzvXWZSq0MTEuqAEhzO0Vsq3yMbJZHP0] set
successfully.
How to Setup Install/Update
Hooks
{
"scripts": {
"post-install-cmd": [
"php artisan optimize"
],
"post-update-cmd": [
"php artisan clear-compiled",
"php artisan optimize"
],
"post-create-project-cmd": [
"php artisan key:generate"
]
}
}
Managing Project
Dependencies:
Overview

A project can be initialized with the init
command
 Project dependencies can be configured by
the command line or directly in the
composer.json file.
 The validate command will validate the
composer.json file.
 The composer.lock file will lock the
revision/change number of the
dependencies.

Managing Project
Dependencies:
Overview (continued)

The install command will install locked
versions if composer.lock is present or act
like the update command if not.
 The update command will update the
library versions and the composer.lock file.
 Running the Composer binary without any
commands will list the available
commands.
 Running the help command will provide
help

Managing Project Metadata:
Overview


The composer specification allows for
the following metadata:








Description – package description
Type – I.E. project or library
Keywords – Aid in searching repositories
Homepage – Project homepage
License – License type for the package
Authors – Information about the authors
Support – Information for obtaining support
regarding the library
Managing Project Metadata:
Example
{
"name": "composer/composer",
"description": "Dependency Manager",
"keywords": ["package", "dependency", "autoload"],
"homepage": "http://getcomposer.org/",
"type": "library",
"license": "MIT",
"authors": [
{
"name": "Nils Adermann",
"email": "naderman@naderman.de",
"homepage": "http://www.naderman.de"
}
],
"support": {
"irc": "irc://irc.freenode.org/composer",
"issues": "https://github.com/composer/composer/issues"
}
}
Managing Dependency
Conflicts


You can manually resolve conflicts
between in dependencies when:
 Changing the version of one of the

dependent packages that causes the conflict
is not an option
 The version you choose will not negatively
effect either dependent package.
"monolog/monolog": "1.7.0 as 1.6.0"
Applying Forks as
Dependencies
Alternate repositories can be used to
provide versions with aliases
 One of the following must be true for
Composer to use an alternate repository:


 The repository specifying the alias is listed

before the repository containing original
package in the composer.json file.
 The repository containing original package does
not have a version specified by the alias (risky)
Applying Forks as
Dependencies: Example
{
"repositories": [
{
"type": "vcs",
"url": "https://github.com/my/monolog"
}
],
"require": {
"symfony/monolog-bundle": "2.0",
"monolog/monolog": "dev-myfix as 1.0.x-dev”
}
}
Managing Repositories


Repositories hold package information in
multiple types:







Packagist.org – Default repository
Composer (Packagist/Satis/Manual)
VCS (git/mercurial/subversion)
PEAR – Using PEAR channels
Artifact – Pre-built artifacts
Package – Using libraries that

All repositories except “Package” require a
composer.json file.
 Repository additions must be on the root
package.

Packagist.org Repository
Will be the final repository searched
 Enabled by default but can be disabled:


{
"repositories": [
{
"packagist": false
}
]
}
Composer Repository
Provides a packages.json file.
 Defined by URL. Path contains file.
 Example inclusion:


{
"repositories": [
{
"type": "composer",
"url": http://packages.example.com
}
]
}
VCS Repository
Composer client will scan VCS
repositories to find branches and tags
with a composer.json file in the root.
 Package name from the composer.json
file.
 Version is from the branch/tag name.
Branch versions will be prefixed with
dev-.

Pear Repository


Composer access to existing PEAR channels.

{

repositories: [
{
"type": "pear",
"url": “pear.phpunit.de”,
“vendor-alias”: “phpunit”
}
]
}


Access repository packages via channel or alias
 “pear.phpunit.de/PHPUnit”: “>=3.7.0”
 “phpunit/PHPUnit”: “>=3.7.0”
Artifact Repository



Scans directory of zip files with composer.json files in
the root of the zip.
Uses package and version in composer.json file.

{
"repositories": [
{
"type": "artifact",
"url": "path/to/zips/dir”
}
]
}
Package Repository
Defines the package and versions in the
composer.json file.
 Uses the same format as packages.json
file from Composer repository.
 Allows for providing shared code that is
not available by any of the other means.

Package Repository
Example
{“packages”: [
{
"type": "package",
"package": {
"name": ”smarty/smarty",
"version": ”3.1.7",
"dist": {
"url": "http://www.smarty.net/files/Smarty3.1.7.zip",
"type": "zip”
}
}
}
]}
Simple repository management for small organizations
Satis: Easy as Pie
Maintain a JSON based meta-data file
with the list of repositories to scour.
 Execute the command and it will
provide:


 Composer compliant packages.json file
 HTML file with instructions on adding the

repository to a composer.json file as well as
a filterable list.
Satis: Repository Cache
If the archive section is configured in the
Satis meta-data file, Satis will scan all
repositories defined and create local
archives
 If options require-dependencies is set to
true, it will also cache dependencies. This
only works on known packages in the
defined repositories.
 Here’s a link to an excellent article on how
to affectively cache packagist.org:
http://tech.m6web.fr/composer-installationwithout-github.html

Satis Metadata Example
{
"name": "My Repository",
"homepage": "http://satis.my.org",
"repositories": [
{
"type": "vcs",
"url": "http://github.com/my/repo"
}
],
"require-all": true

}
Satis Conclusions






Simple to use
Easy to deploy
Full PHP
implementation
Uses static files for
hosting
Can cache
repositories from
VCS and Packagist








Requires
management of a
config file
Becomes unwieldy
for large numbers of
packages
Limited search and
package information
Requires shared
disk for HA
The enterprise repository manager
Packagist…and a bag of
chips
Web based package management
 Optimized search via Solr
 Allows for high availability via MySQL
 API for remotely triggering package
scans
 Package statistics

Packagist Conclusions







Web based
management
interface
Solr based search
HA capable
Virtually unlimited
package
management









No archives for non
Github/BitBucket
VCS repositories
Complex
architecture
Requires MySQL
and Solr knowledge
and management
Only VCS packages
Your one stop shop for open source projects and libraries
One Repository to Rule Them
All
21,762 packages (1/7/2014)
 Default package manager for Composer
 Free accounts to register/maintain
packages
 Contains nearly every widely used open
source PHP package
 Just use it!

Registering a package







Get a user
Log in
Click “Submit a Package”
Enter the URL for your public repository
Click “Check”
Optionally but suggested: Register a
commit hook to scan for updates on
commit.
 Github has a pre-configured hook
 BitBucket can use a POST hook

More Related Content

What's hot

Developing and Deploying PHP with Docker
Developing and Deploying PHP with DockerDeveloping and Deploying PHP with Docker
Developing and Deploying PHP with DockerPatrick Mizer
 
Installing and running Postfix within a docker container from the command line
Installing and running Postfix within a docker container from the command lineInstalling and running Postfix within a docker container from the command line
Installing and running Postfix within a docker container from the command linedotCloud
 
How to deploy PHP projects with docker
How to deploy PHP projects with dockerHow to deploy PHP projects with docker
How to deploy PHP projects with dockerRuoshi Ling
 
Vagrant move over, here is Docker
Vagrant move over, here is DockerVagrant move over, here is Docker
Vagrant move over, here is DockerNick Belhomme
 
Deploying Symfony | symfony.cat
Deploying Symfony | symfony.catDeploying Symfony | symfony.cat
Deploying Symfony | symfony.catPablo Godel
 
Composer the Right Way - PHPBNL16
Composer the Right Way - PHPBNL16Composer the Right Way - PHPBNL16
Composer the Right Way - PHPBNL16Rafael Dohms
 
FITC - Node.js 101
FITC - Node.js 101FITC - Node.js 101
FITC - Node.js 101Rami Sayar
 
Php psr standard 2014 01-22
Php psr standard 2014 01-22Php psr standard 2014 01-22
Php psr standard 2014 01-22Võ Duy Tuấn
 
Composer The Right Way - 010PHP
Composer The Right Way - 010PHPComposer The Right Way - 010PHP
Composer The Right Way - 010PHPRafael Dohms
 
Conan a C/C++ Package Manager
Conan a C/C++ Package ManagerConan a C/C++ Package Manager
Conan a C/C++ Package ManagerUilian Ries
 
Docker + Microservices in Production
Docker + Microservices in ProductionDocker + Microservices in Production
Docker + Microservices in ProductionPatrick Mizer
 
Conan.io - The C/C++ package manager for Developers
Conan.io - The C/C++ package manager for DevelopersConan.io - The C/C++ package manager for Developers
Conan.io - The C/C++ package manager for DevelopersUilian Ries
 
DevOps hackathon Session 2: Basics of Chef
DevOps hackathon Session 2: Basics of ChefDevOps hackathon Session 2: Basics of Chef
DevOps hackathon Session 2: Basics of ChefAntons Kranga
 
Performance tips for Symfony2 & PHP
Performance tips for Symfony2 & PHPPerformance tips for Symfony2 & PHP
Performance tips for Symfony2 & PHPMax Romanovsky
 
The Modern Developer Toolbox
The Modern Developer ToolboxThe Modern Developer Toolbox
The Modern Developer ToolboxPablo Godel
 
Composer The Right Way #PHPjhb15
Composer The Right Way #PHPjhb15Composer The Right Way #PHPjhb15
Composer The Right Way #PHPjhb15Rafael Dohms
 
Composer the Right Way - MM16NL
Composer the Right Way - MM16NLComposer the Right Way - MM16NL
Composer the Right Way - MM16NLRafael Dohms
 
Developing MIPS Exploits to Hack Routers
Developing MIPS Exploits to Hack RoutersDeveloping MIPS Exploits to Hack Routers
Developing MIPS Exploits to Hack RoutersOnur Alanbel
 

What's hot (20)

Developing and Deploying PHP with Docker
Developing and Deploying PHP with DockerDeveloping and Deploying PHP with Docker
Developing and Deploying PHP with Docker
 
Installing and running Postfix within a docker container from the command line
Installing and running Postfix within a docker container from the command lineInstalling and running Postfix within a docker container from the command line
Installing and running Postfix within a docker container from the command line
 
How to deploy PHP projects with docker
How to deploy PHP projects with dockerHow to deploy PHP projects with docker
How to deploy PHP projects with docker
 
Vagrant move over, here is Docker
Vagrant move over, here is DockerVagrant move over, here is Docker
Vagrant move over, here is Docker
 
Deploying Symfony | symfony.cat
Deploying Symfony | symfony.catDeploying Symfony | symfony.cat
Deploying Symfony | symfony.cat
 
Composer the Right Way - PHPBNL16
Composer the Right Way - PHPBNL16Composer the Right Way - PHPBNL16
Composer the Right Way - PHPBNL16
 
FITC - Node.js 101
FITC - Node.js 101FITC - Node.js 101
FITC - Node.js 101
 
Php psr standard 2014 01-22
Php psr standard 2014 01-22Php psr standard 2014 01-22
Php psr standard 2014 01-22
 
Composer The Right Way - 010PHP
Composer The Right Way - 010PHPComposer The Right Way - 010PHP
Composer The Right Way - 010PHP
 
Conan a C/C++ Package Manager
Conan a C/C++ Package ManagerConan a C/C++ Package Manager
Conan a C/C++ Package Manager
 
Docker + Microservices in Production
Docker + Microservices in ProductionDocker + Microservices in Production
Docker + Microservices in Production
 
Phalcon 2 - PHP Brazil Conference
Phalcon 2 - PHP Brazil ConferencePhalcon 2 - PHP Brazil Conference
Phalcon 2 - PHP Brazil Conference
 
Conan.io - The C/C++ package manager for Developers
Conan.io - The C/C++ package manager for DevelopersConan.io - The C/C++ package manager for Developers
Conan.io - The C/C++ package manager for Developers
 
DevOps hackathon Session 2: Basics of Chef
DevOps hackathon Session 2: Basics of ChefDevOps hackathon Session 2: Basics of Chef
DevOps hackathon Session 2: Basics of Chef
 
Performance tips for Symfony2 & PHP
Performance tips for Symfony2 & PHPPerformance tips for Symfony2 & PHP
Performance tips for Symfony2 & PHP
 
Perlbrew
PerlbrewPerlbrew
Perlbrew
 
The Modern Developer Toolbox
The Modern Developer ToolboxThe Modern Developer Toolbox
The Modern Developer Toolbox
 
Composer The Right Way #PHPjhb15
Composer The Right Way #PHPjhb15Composer The Right Way #PHPjhb15
Composer The Right Way #PHPjhb15
 
Composer the Right Way - MM16NL
Composer the Right Way - MM16NLComposer the Right Way - MM16NL
Composer the Right Way - MM16NL
 
Developing MIPS Exploits to Hack Routers
Developing MIPS Exploits to Hack RoutersDeveloping MIPS Exploits to Hack Routers
Developing MIPS Exploits to Hack Routers
 

Viewers also liked

Homepage i TOS - #Moja Srbija
Homepage i TOS - #Moja SrbijaHomepage i TOS - #Moja Srbija
Homepage i TOS - #Moja SrbijaMarketing mreža
 
Android tv market - March 2017 - analysis and commentary
Android tv market -  March 2017 - analysis and commentaryAndroid tv market -  March 2017 - analysis and commentary
Android tv market - March 2017 - analysis and commentarypaul young cpa, cga
 
Efficient development workflows with composer
Efficient development workflows with composerEfficient development workflows with composer
Efficient development workflows with composernuppla
 
Ko konkuriše za nagradu EY Preduzetnik godine 2016?
Ko konkuriše za nagradu EY Preduzetnik godine 2016?Ko konkuriše za nagradu EY Preduzetnik godine 2016?
Ko konkuriše za nagradu EY Preduzetnik godine 2016?Mila Dimitrijević
 
Design Patterns in Swift ch0 Introduction
Design Patterns in Swift ch0 IntroductionDesign Patterns in Swift ch0 Introduction
Design Patterns in Swift ch0 IntroductionChihyang Li
 
Custom Android App Development – Web Animation India
Custom Android App Development – Web Animation IndiaCustom Android App Development – Web Animation India
Custom Android App Development – Web Animation IndiaMarion Welch
 
Android coding guidlines
Android coding guidlinesAndroid coding guidlines
Android coding guidlinesKrunal Doshi
 
How Much Does it Cost to Build a Mobile App for iPhone & Android?
How Much Does it Cost to Build a Mobile App for iPhone & Android?How Much Does it Cost to Build a Mobile App for iPhone & Android?
How Much Does it Cost to Build a Mobile App for iPhone & Android?Alex Sam
 
Introduction to PHP
Introduction to PHPIntroduction to PHP
Introduction to PHPBradley Holt
 
Ascent of pikes peak
Ascent of pikes peakAscent of pikes peak
Ascent of pikes peaktomousman
 
Design persuasivo: alcuni esempi
Design persuasivo: alcuni esempiDesign persuasivo: alcuni esempi
Design persuasivo: alcuni esempiAlberto Mucignat
 
SHERRI GOODWIN Resume 1 (2)
SHERRI GOODWIN Resume 1 (2)SHERRI GOODWIN Resume 1 (2)
SHERRI GOODWIN Resume 1 (2)Sherri Goodwin
 
Valsts pārvaldes institūciju pasūtīto pētījumu koordinācijas sistēma
Valsts pārvaldes institūciju pasūtīto pētījumu koordinācijas sistēmaValsts pārvaldes institūciju pasūtīto pētījumu koordinācijas sistēma
Valsts pārvaldes institūciju pasūtīto pētījumu koordinācijas sistēmaPārresoru kordinācijas centrs (PKC)
 
AWS Roadshow Herbst 2013: Beschleunigen Sie Entwicklungs- und Test-Szenarien ...
AWS Roadshow Herbst 2013: Beschleunigen Sie Entwicklungs- und Test-Szenarien ...AWS Roadshow Herbst 2013: Beschleunigen Sie Entwicklungs- und Test-Szenarien ...
AWS Roadshow Herbst 2013: Beschleunigen Sie Entwicklungs- und Test-Szenarien ...AWS Germany
 
Buyer Persona - Key to B2B online marketing success
Buyer Persona - Key to B2B online marketing successBuyer Persona - Key to B2B online marketing success
Buyer Persona - Key to B2B online marketing successShimonBen
 

Viewers also liked (20)

Homepage i TOS - #Moja Srbija
Homepage i TOS - #Moja SrbijaHomepage i TOS - #Moja Srbija
Homepage i TOS - #Moja Srbija
 
Mastering composer
Mastering composerMastering composer
Mastering composer
 
Android tv market - March 2017 - analysis and commentary
Android tv market -  March 2017 - analysis and commentaryAndroid tv market -  March 2017 - analysis and commentary
Android tv market - March 2017 - analysis and commentary
 
Efficient development workflows with composer
Efficient development workflows with composerEfficient development workflows with composer
Efficient development workflows with composer
 
Ko konkuriše za nagradu EY Preduzetnik godine 2016?
Ko konkuriše za nagradu EY Preduzetnik godine 2016?Ko konkuriše za nagradu EY Preduzetnik godine 2016?
Ko konkuriše za nagradu EY Preduzetnik godine 2016?
 
Design Patterns in Swift ch0 Introduction
Design Patterns in Swift ch0 IntroductionDesign Patterns in Swift ch0 Introduction
Design Patterns in Swift ch0 Introduction
 
Custom Android App Development – Web Animation India
Custom Android App Development – Web Animation IndiaCustom Android App Development – Web Animation India
Custom Android App Development – Web Animation India
 
Android coding guidlines
Android coding guidlinesAndroid coding guidlines
Android coding guidlines
 
PHP Web Programming
PHP Web ProgrammingPHP Web Programming
PHP Web Programming
 
How Much Does it Cost to Build a Mobile App for iPhone & Android?
How Much Does it Cost to Build a Mobile App for iPhone & Android?How Much Does it Cost to Build a Mobile App for iPhone & Android?
How Much Does it Cost to Build a Mobile App for iPhone & Android?
 
Introduction to PHP
Introduction to PHPIntroduction to PHP
Introduction to PHP
 
Ascent of pikes peak
Ascent of pikes peakAscent of pikes peak
Ascent of pikes peak
 
Design persuasivo: alcuni esempi
Design persuasivo: alcuni esempiDesign persuasivo: alcuni esempi
Design persuasivo: alcuni esempi
 
SHERRI GOODWIN Resume 1 (2)
SHERRI GOODWIN Resume 1 (2)SHERRI GOODWIN Resume 1 (2)
SHERRI GOODWIN Resume 1 (2)
 
Plan de-clase
Plan de-clasePlan de-clase
Plan de-clase
 
Каталог Wellness
Каталог WellnessКаталог Wellness
Каталог Wellness
 
Valsts pārvaldes institūciju pasūtīto pētījumu koordinācijas sistēma
Valsts pārvaldes institūciju pasūtīto pētījumu koordinācijas sistēmaValsts pārvaldes institūciju pasūtīto pētījumu koordinācijas sistēma
Valsts pārvaldes institūciju pasūtīto pētījumu koordinācijas sistēma
 
AWS Roadshow Herbst 2013: Beschleunigen Sie Entwicklungs- und Test-Szenarien ...
AWS Roadshow Herbst 2013: Beschleunigen Sie Entwicklungs- und Test-Szenarien ...AWS Roadshow Herbst 2013: Beschleunigen Sie Entwicklungs- und Test-Szenarien ...
AWS Roadshow Herbst 2013: Beschleunigen Sie Entwicklungs- und Test-Szenarien ...
 
Buyer Persona - Key to B2B online marketing success
Buyer Persona - Key to B2B online marketing successBuyer Persona - Key to B2B online marketing success
Buyer Persona - Key to B2B online marketing success
 
Set
SetSet
Set
 

Similar to PHP Dependency Management with Composer

Php Dependency Management with Composer ZendCon 2016
Php Dependency Management with Composer ZendCon 2016Php Dependency Management with Composer ZendCon 2016
Php Dependency Management with Composer ZendCon 2016Clark Everetts
 
Piattaforma Web Linux completa dai sorgenti
Piattaforma Web Linux completa dai sorgentiPiattaforma Web Linux completa dai sorgenti
Piattaforma Web Linux completa dai sorgentiGiulio Destri
 
Linux containers and docker
Linux containers and dockerLinux containers and docker
Linux containers and dockerFabio Fumarola
 
Digital Fabrication Studio v.0.2: Information
Digital Fabrication Studio v.0.2: InformationDigital Fabrication Studio v.0.2: Information
Digital Fabrication Studio v.0.2: InformationMassimo Menichinelli
 
Digital Fabrication Studio.02 _Information @ Aalto Media Factory
Digital Fabrication Studio.02 _Information @ Aalto Media FactoryDigital Fabrication Studio.02 _Information @ Aalto Media Factory
Digital Fabrication Studio.02 _Information @ Aalto Media FactoryMassimo Menichinelli
 
2 Linux Container and Docker
2 Linux Container and Docker2 Linux Container and Docker
2 Linux Container and DockerFabio Fumarola
 
Develop with linux containers and docker
Develop with linux containers and dockerDevelop with linux containers and docker
Develop with linux containers and dockerFabio Fumarola
 
Composer Lightning Talk
Composer Lightning TalkComposer Lightning Talk
Composer Lightning TalkEric Johnson
 
Prizm Installation Guide
Prizm Installation GuidePrizm Installation Guide
Prizm Installation Guidevjvarenya
 
Docker - Demo on PHP Application deployment
Docker - Demo on PHP Application deployment Docker - Demo on PHP Application deployment
Docker - Demo on PHP Application deployment Arun prasath
 
Php Dependency Management with Composer ZendCon 2017
Php Dependency Management with Composer ZendCon 2017Php Dependency Management with Composer ZendCon 2017
Php Dependency Management with Composer ZendCon 2017Clark Everetts
 
Development and deployment with composer and kite
Development and deployment with composer and kiteDevelopment and deployment with composer and kite
Development and deployment with composer and kiteChristian Opitz
 
An Introduction of Node Package Manager (NPM)
An Introduction of Node Package Manager (NPM)An Introduction of Node Package Manager (NPM)
An Introduction of Node Package Manager (NPM)iFour Technolab Pvt. Ltd.
 
Create a PHP Library the right way
Create a PHP Library the right wayCreate a PHP Library the right way
Create a PHP Library the right wayChristian Varela
 
PHP on Heroku: Deploying and Scaling Apps in the Cloud
PHP on Heroku: Deploying and Scaling Apps in the CloudPHP on Heroku: Deploying and Scaling Apps in the Cloud
PHP on Heroku: Deploying and Scaling Apps in the CloudSalesforce Developers
 
Automate drupal deployments with linux containers, docker and vagrant
Automate drupal deployments with linux containers, docker and vagrant Automate drupal deployments with linux containers, docker and vagrant
Automate drupal deployments with linux containers, docker and vagrant Ricardo Amaro
 
12 Composer #burningkeyboards
12 Composer #burningkeyboards12 Composer #burningkeyboards
12 Composer #burningkeyboardsDenis Ristic
 

Similar to PHP Dependency Management with Composer (20)

Php Dependency Management with Composer ZendCon 2016
Php Dependency Management with Composer ZendCon 2016Php Dependency Management with Composer ZendCon 2016
Php Dependency Management with Composer ZendCon 2016
 
Composer namespacing
Composer namespacingComposer namespacing
Composer namespacing
 
Piattaforma Web Linux completa dai sorgenti
Piattaforma Web Linux completa dai sorgentiPiattaforma Web Linux completa dai sorgenti
Piattaforma Web Linux completa dai sorgenti
 
Linux containers and docker
Linux containers and dockerLinux containers and docker
Linux containers and docker
 
Digital Fabrication Studio v.0.2: Information
Digital Fabrication Studio v.0.2: InformationDigital Fabrication Studio v.0.2: Information
Digital Fabrication Studio v.0.2: Information
 
Digital Fabrication Studio.02 _Information @ Aalto Media Factory
Digital Fabrication Studio.02 _Information @ Aalto Media FactoryDigital Fabrication Studio.02 _Information @ Aalto Media Factory
Digital Fabrication Studio.02 _Information @ Aalto Media Factory
 
2 Linux Container and Docker
2 Linux Container and Docker2 Linux Container and Docker
2 Linux Container and Docker
 
Develop with linux containers and docker
Develop with linux containers and dockerDevelop with linux containers and docker
Develop with linux containers and docker
 
Composer Lightning Talk
Composer Lightning TalkComposer Lightning Talk
Composer Lightning Talk
 
Prizm Installation Guide
Prizm Installation GuidePrizm Installation Guide
Prizm Installation Guide
 
Docker - Demo on PHP Application deployment
Docker - Demo on PHP Application deployment Docker - Demo on PHP Application deployment
Docker - Demo on PHP Application deployment
 
Php Dependency Management with Composer ZendCon 2017
Php Dependency Management with Composer ZendCon 2017Php Dependency Management with Composer ZendCon 2017
Php Dependency Management with Composer ZendCon 2017
 
Development and deployment with composer and kite
Development and deployment with composer and kiteDevelopment and deployment with composer and kite
Development and deployment with composer and kite
 
An Introduction of Node Package Manager (NPM)
An Introduction of Node Package Manager (NPM)An Introduction of Node Package Manager (NPM)
An Introduction of Node Package Manager (NPM)
 
Create a PHP Library the right way
Create a PHP Library the right wayCreate a PHP Library the right way
Create a PHP Library the right way
 
Docker-v3.pdf
Docker-v3.pdfDocker-v3.pdf
Docker-v3.pdf
 
Composer intro
Composer introComposer intro
Composer intro
 
PHP on Heroku: Deploying and Scaling Apps in the Cloud
PHP on Heroku: Deploying and Scaling Apps in the CloudPHP on Heroku: Deploying and Scaling Apps in the Cloud
PHP on Heroku: Deploying and Scaling Apps in the Cloud
 
Automate drupal deployments with linux containers, docker and vagrant
Automate drupal deployments with linux containers, docker and vagrant Automate drupal deployments with linux containers, docker and vagrant
Automate drupal deployments with linux containers, docker and vagrant
 
12 Composer #burningkeyboards
12 Composer #burningkeyboards12 Composer #burningkeyboards
12 Composer #burningkeyboards
 

More from Adam Englander

Making PHP Smarter - Dutch PHP 2023.pptx
Making PHP Smarter - Dutch PHP 2023.pptxMaking PHP Smarter - Dutch PHP 2023.pptx
Making PHP Smarter - Dutch PHP 2023.pptxAdam Englander
 
Practical API Security - PyCon 2019
Practical API Security - PyCon 2019Practical API Security - PyCon 2019
Practical API Security - PyCon 2019Adam Englander
 
Threat Modeling for Dummies
Threat Modeling for DummiesThreat Modeling for Dummies
Threat Modeling for DummiesAdam Englander
 
ZendCon 2018 - Practical API Security
ZendCon 2018 - Practical API SecurityZendCon 2018 - Practical API Security
ZendCon 2018 - Practical API SecurityAdam Englander
 
ZendCon 2018 - Cryptography in Depth
ZendCon 2018 - Cryptography in DepthZendCon 2018 - Cryptography in Depth
ZendCon 2018 - Cryptography in DepthAdam Englander
 
Threat Modeling for Dummies - Cascadia PHP 2018
Threat Modeling for Dummies - Cascadia PHP 2018Threat Modeling for Dummies - Cascadia PHP 2018
Threat Modeling for Dummies - Cascadia PHP 2018Adam Englander
 
Dutch PHP 2018 - Cryptography for Beginners
Dutch PHP 2018 - Cryptography for BeginnersDutch PHP 2018 - Cryptography for Beginners
Dutch PHP 2018 - Cryptography for BeginnersAdam Englander
 
php[tek] 2108 - Cryptography Advances in PHP 7.2
php[tek] 2108 - Cryptography Advances in PHP 7.2php[tek] 2108 - Cryptography Advances in PHP 7.2
php[tek] 2108 - Cryptography Advances in PHP 7.2Adam Englander
 
php[tek] 2018 - Biometrics, fantastic failure point of the future
php[tek] 2018 - Biometrics, fantastic failure point of the futurephp[tek] 2018 - Biometrics, fantastic failure point of the future
php[tek] 2018 - Biometrics, fantastic failure point of the futureAdam Englander
 
Biometrics: Sexy, Secure and... Stupid - RSAC 2018
Biometrics: Sexy, Secure and... Stupid - RSAC 2018Biometrics: Sexy, Secure and... Stupid - RSAC 2018
Biometrics: Sexy, Secure and... Stupid - RSAC 2018Adam Englander
 
Practical API Security - PyCon 2018
Practical API Security - PyCon 2018Practical API Security - PyCon 2018
Practical API Security - PyCon 2018Adam Englander
 
Practical API Security - Midwest PHP 2018
Practical API Security - Midwest PHP 2018Practical API Security - Midwest PHP 2018
Practical API Security - Midwest PHP 2018Adam Englander
 
Cryptography for Beginners - Midwest PHP 2018
Cryptography for Beginners - Midwest PHP 2018Cryptography for Beginners - Midwest PHP 2018
Cryptography for Beginners - Midwest PHP 2018Adam Englander
 
Cryptography for Beginners - Sunshine PHP 2018
Cryptography for Beginners - Sunshine PHP 2018Cryptography for Beginners - Sunshine PHP 2018
Cryptography for Beginners - Sunshine PHP 2018Adam Englander
 
ConFoo Vancouver 2017 - Biometrics: Fantastic Failure Point of the Future
ConFoo Vancouver 2017 - Biometrics: Fantastic Failure Point of the FutureConFoo Vancouver 2017 - Biometrics: Fantastic Failure Point of the Future
ConFoo Vancouver 2017 - Biometrics: Fantastic Failure Point of the FutureAdam Englander
 
Con Foo 2017 - Don't Loose Sleep - Secure Your REST
Con Foo 2017 - Don't Loose Sleep - Secure Your RESTCon Foo 2017 - Don't Loose Sleep - Secure Your REST
Con Foo 2017 - Don't Loose Sleep - Secure Your RESTAdam Englander
 
ZendCon 2017 - Cryptography for Beginners
ZendCon 2017 - Cryptography for BeginnersZendCon 2017 - Cryptography for Beginners
ZendCon 2017 - Cryptography for BeginnersAdam Englander
 
ZendCon 2017: The Red Team is Coming
ZendCon 2017: The Red Team is ComingZendCon 2017: The Red Team is Coming
ZendCon 2017: The Red Team is ComingAdam Englander
 
ZendCon 2017 - Build a Bot Workshop - Async Primer
ZendCon 2017 - Build a Bot Workshop - Async PrimerZendCon 2017 - Build a Bot Workshop - Async Primer
ZendCon 2017 - Build a Bot Workshop - Async PrimerAdam Englander
 
Symfony Live San Franciso 2017 - BDD API Development with Symfony and Behat
Symfony Live San Franciso 2017 - BDD API Development with Symfony and BehatSymfony Live San Franciso 2017 - BDD API Development with Symfony and Behat
Symfony Live San Franciso 2017 - BDD API Development with Symfony and BehatAdam Englander
 

More from Adam Englander (20)

Making PHP Smarter - Dutch PHP 2023.pptx
Making PHP Smarter - Dutch PHP 2023.pptxMaking PHP Smarter - Dutch PHP 2023.pptx
Making PHP Smarter - Dutch PHP 2023.pptx
 
Practical API Security - PyCon 2019
Practical API Security - PyCon 2019Practical API Security - PyCon 2019
Practical API Security - PyCon 2019
 
Threat Modeling for Dummies
Threat Modeling for DummiesThreat Modeling for Dummies
Threat Modeling for Dummies
 
ZendCon 2018 - Practical API Security
ZendCon 2018 - Practical API SecurityZendCon 2018 - Practical API Security
ZendCon 2018 - Practical API Security
 
ZendCon 2018 - Cryptography in Depth
ZendCon 2018 - Cryptography in DepthZendCon 2018 - Cryptography in Depth
ZendCon 2018 - Cryptography in Depth
 
Threat Modeling for Dummies - Cascadia PHP 2018
Threat Modeling for Dummies - Cascadia PHP 2018Threat Modeling for Dummies - Cascadia PHP 2018
Threat Modeling for Dummies - Cascadia PHP 2018
 
Dutch PHP 2018 - Cryptography for Beginners
Dutch PHP 2018 - Cryptography for BeginnersDutch PHP 2018 - Cryptography for Beginners
Dutch PHP 2018 - Cryptography for Beginners
 
php[tek] 2108 - Cryptography Advances in PHP 7.2
php[tek] 2108 - Cryptography Advances in PHP 7.2php[tek] 2108 - Cryptography Advances in PHP 7.2
php[tek] 2108 - Cryptography Advances in PHP 7.2
 
php[tek] 2018 - Biometrics, fantastic failure point of the future
php[tek] 2018 - Biometrics, fantastic failure point of the futurephp[tek] 2018 - Biometrics, fantastic failure point of the future
php[tek] 2018 - Biometrics, fantastic failure point of the future
 
Biometrics: Sexy, Secure and... Stupid - RSAC 2018
Biometrics: Sexy, Secure and... Stupid - RSAC 2018Biometrics: Sexy, Secure and... Stupid - RSAC 2018
Biometrics: Sexy, Secure and... Stupid - RSAC 2018
 
Practical API Security - PyCon 2018
Practical API Security - PyCon 2018Practical API Security - PyCon 2018
Practical API Security - PyCon 2018
 
Practical API Security - Midwest PHP 2018
Practical API Security - Midwest PHP 2018Practical API Security - Midwest PHP 2018
Practical API Security - Midwest PHP 2018
 
Cryptography for Beginners - Midwest PHP 2018
Cryptography for Beginners - Midwest PHP 2018Cryptography for Beginners - Midwest PHP 2018
Cryptography for Beginners - Midwest PHP 2018
 
Cryptography for Beginners - Sunshine PHP 2018
Cryptography for Beginners - Sunshine PHP 2018Cryptography for Beginners - Sunshine PHP 2018
Cryptography for Beginners - Sunshine PHP 2018
 
ConFoo Vancouver 2017 - Biometrics: Fantastic Failure Point of the Future
ConFoo Vancouver 2017 - Biometrics: Fantastic Failure Point of the FutureConFoo Vancouver 2017 - Biometrics: Fantastic Failure Point of the Future
ConFoo Vancouver 2017 - Biometrics: Fantastic Failure Point of the Future
 
Con Foo 2017 - Don't Loose Sleep - Secure Your REST
Con Foo 2017 - Don't Loose Sleep - Secure Your RESTCon Foo 2017 - Don't Loose Sleep - Secure Your REST
Con Foo 2017 - Don't Loose Sleep - Secure Your REST
 
ZendCon 2017 - Cryptography for Beginners
ZendCon 2017 - Cryptography for BeginnersZendCon 2017 - Cryptography for Beginners
ZendCon 2017 - Cryptography for Beginners
 
ZendCon 2017: The Red Team is Coming
ZendCon 2017: The Red Team is ComingZendCon 2017: The Red Team is Coming
ZendCon 2017: The Red Team is Coming
 
ZendCon 2017 - Build a Bot Workshop - Async Primer
ZendCon 2017 - Build a Bot Workshop - Async PrimerZendCon 2017 - Build a Bot Workshop - Async Primer
ZendCon 2017 - Build a Bot Workshop - Async Primer
 
Symfony Live San Franciso 2017 - BDD API Development with Symfony and Behat
Symfony Live San Franciso 2017 - BDD API Development with Symfony and BehatSymfony Live San Franciso 2017 - BDD API Development with Symfony and Behat
Symfony Live San Franciso 2017 - BDD API Development with Symfony and Behat
 

Recently uploaded

The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
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
 
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
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processorsdebabhi2
 
🐬 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
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slidespraypatel2
 
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
 
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
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
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
 

Recently uploaded (20)

The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
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...
 
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)
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Slack Application Development 101 Slides
Slack Application Development 101 SlidesSlack Application Development 101 Slides
Slack Application Development 101 Slides
 
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
 
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...
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
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
 

PHP Dependency Management with Composer

  • 2. Who Am I? • Selling Source Direct Lead Developer • Coupla CTO • Founder/Organizer of Las Vegas PHP Users Group • Co-Organizer of Las Vegas Developers Users Group • PHP Machinist Maintainer • #VegasTech Enthusiast Adam Englander adamenglander@yahoo.com @adam_englander http://adamknowsstuff.com https://github.com/derptest
  • 3. What is Dependency Management? Dependency management for this context is best described as the resolution and installation of library dependencies for a software project. This includes resolving potential conflicts between libraries and providing the dependencies for all libraries on the dependency tree.
  • 4. Simple Example of Dependencies  My Project  PHP >= 5.5.0  Monolog >= 1.3.0, < 2.0 ○ PHP >= 5.3.0 ○ PSR Log >= 1.0, < 2.0
  • 5. Sharing used to be hard
  • 6. Legacy Solutions PEAR  PECL  Version Control System Sub-repositories (SVN, Git, Mercurial)  Directly adding dependencies to your codebase  Custom dependency manager  Write monolithic code bases 
  • 7. PEAR – PHP Extension and Application Library     Multiple Repositories Private Repositories Sub-dependency version resolution Hundreds of libraries      One package install per server No common format for defining project dependencies Not extensible Each server had to be aware of repositories Publishing required
  • 8. PECL– PHP Extension Community Library    Highly trusted libraries Hundreds of libraries Sub-dependency version resolution      One package install per server No common format for defining project dependencies No private repos Each server had to be aware of repositories Publishing required
  • 9. VCS Sub-Repositories    Project based dependencies Private Repositories Potentially millions of libraries    Normally requires using the external library’s VCS No deep dependency management Need to monitor patches and updates to external libraries
  • 10. Directly adding dependencies to your codebase    Project based dependencies Private Repositories Potentially millions of libraries    Project codebases have dependency code making them large and unwieldy You have to manually resolve all dependencies You have to test interoperability of all dependent libraries
  • 11. Custom Repository Manager  If you can dream it, you can do it.   Difficult to write You must implement every feature and fix every bug
  • 12. Monolithic Code Base   No need for dependency management Private Repositories      Harder to manage Harder to test Re-writing the same code in multiple projects. Maintaining the the same bug fixes in multiple projects. No leveraging of community code
  • 13. DRY – Don’t repeat yourself or anyone else for that matter.
  • 14. The Platform Composer – The fully self-contained and completely extensible client  Satis – The app for generating static servable repository data.  Packagist – The server for managing and maintaining dynamic repository data.  Packagist.org – The public Packagist server for open source libraries and projects. 21K+ packages. 
  • 15. The alpha and the omega
  • 16. Composer Overview  Command line client application for:      Searching repositories for packages Installing project skeletons Executing install/update hooks Managing project dependencies Managing project metadata Base code for servers  The only product on the platform necessary for managing dependencies in a project 
  • 17. Installation There  Download the composer.phar from http://getcomposer.org/download/  Use the installer script from http://getcomposer.org/download/  Install from your *nix distro package manager (yum/apt/pkgsrc/homebrew)
  • 18. Search the repositories vagrant:/$ composer search monolog monolog/monolog Sends your logs to files, sockets, inboxes, databases and various web services symfony/monolog-bundle Symfony MonologBundle symfony/monolog-bridge Symfony Monolog Bridge flynsarmy/slim-monolog Monolog logging support Slim Framework logentries/logentries-monolog-handler A handler for Monolog that sends messages to Logentries.com. kamisama/monolog-init Very basic and light Dependency Injector Container for Monolog ddtraceweb/monolog-parser A parser for monolog log entries lexik/monolog-browser-bundle This Symfony2 bundle provides a Doctrine DBAL handler for Monolog and a web UI to display log entries graze/monolog-extensions Monolog extensions for use within Graze bazo/nette-monolog-extension Nette monolog compiler extension fancyguy/wordpress-monolog WordPress Monolog Integration kmelia/monolog-stdout-handler A handler for Monolog that sends messages to stdout (with color). support
  • 19. Installing Project Skeletons vagrant:/$ composer create-project laravel/laravel --preferdist Installing laravel/laravel (v4.1.0) - Installing laravel/laravel (v4.1.0) Downloading: 100% Created project in /tmp/laravel Loading composer repositories with package information Installing dependencies (including require-dev) - Installing filp/whoops (1.0.10) Downloading: 100% - Installing psr/log (dev-master 65f363a) Downloading: 100% …
  • 20. Executing install/update hooks vagrant:/$ composer create-project laravel/laravel --prefer-dist Installing laravel/laravel (v4.1.0) - Installing laravel/laravel (v4.1.0) Downloading: 100% … Writing lock file Generating autoload files Generating optimized class loader Application key [TzvXWZSq0MTEuqAEhzO0Vsq3yMbJZHP0] set successfully.
  • 21. How to Setup Install/Update Hooks { "scripts": { "post-install-cmd": [ "php artisan optimize" ], "post-update-cmd": [ "php artisan clear-compiled", "php artisan optimize" ], "post-create-project-cmd": [ "php artisan key:generate" ] } }
  • 22. Managing Project Dependencies: Overview A project can be initialized with the init command  Project dependencies can be configured by the command line or directly in the composer.json file.  The validate command will validate the composer.json file.  The composer.lock file will lock the revision/change number of the dependencies. 
  • 23. Managing Project Dependencies: Overview (continued) The install command will install locked versions if composer.lock is present or act like the update command if not.  The update command will update the library versions and the composer.lock file.  Running the Composer binary without any commands will list the available commands.  Running the help command will provide help 
  • 24. Managing Project Metadata: Overview  The composer specification allows for the following metadata:        Description – package description Type – I.E. project or library Keywords – Aid in searching repositories Homepage – Project homepage License – License type for the package Authors – Information about the authors Support – Information for obtaining support regarding the library
  • 25. Managing Project Metadata: Example { "name": "composer/composer", "description": "Dependency Manager", "keywords": ["package", "dependency", "autoload"], "homepage": "http://getcomposer.org/", "type": "library", "license": "MIT", "authors": [ { "name": "Nils Adermann", "email": "naderman@naderman.de", "homepage": "http://www.naderman.de" } ], "support": { "irc": "irc://irc.freenode.org/composer", "issues": "https://github.com/composer/composer/issues" } }
  • 26. Managing Dependency Conflicts  You can manually resolve conflicts between in dependencies when:  Changing the version of one of the dependent packages that causes the conflict is not an option  The version you choose will not negatively effect either dependent package. "monolog/monolog": "1.7.0 as 1.6.0"
  • 27. Applying Forks as Dependencies Alternate repositories can be used to provide versions with aliases  One of the following must be true for Composer to use an alternate repository:   The repository specifying the alias is listed before the repository containing original package in the composer.json file.  The repository containing original package does not have a version specified by the alias (risky)
  • 28. Applying Forks as Dependencies: Example { "repositories": [ { "type": "vcs", "url": "https://github.com/my/monolog" } ], "require": { "symfony/monolog-bundle": "2.0", "monolog/monolog": "dev-myfix as 1.0.x-dev” } }
  • 29. Managing Repositories  Repositories hold package information in multiple types:       Packagist.org – Default repository Composer (Packagist/Satis/Manual) VCS (git/mercurial/subversion) PEAR – Using PEAR channels Artifact – Pre-built artifacts Package – Using libraries that All repositories except “Package” require a composer.json file.  Repository additions must be on the root package. 
  • 30. Packagist.org Repository Will be the final repository searched  Enabled by default but can be disabled:  { "repositories": [ { "packagist": false } ] }
  • 31. Composer Repository Provides a packages.json file.  Defined by URL. Path contains file.  Example inclusion:  { "repositories": [ { "type": "composer", "url": http://packages.example.com } ] }
  • 32. VCS Repository Composer client will scan VCS repositories to find branches and tags with a composer.json file in the root.  Package name from the composer.json file.  Version is from the branch/tag name. Branch versions will be prefixed with dev-. 
  • 33. Pear Repository  Composer access to existing PEAR channels. { repositories: [ { "type": "pear", "url": “pear.phpunit.de”, “vendor-alias”: “phpunit” } ] }  Access repository packages via channel or alias  “pear.phpunit.de/PHPUnit”: “>=3.7.0”  “phpunit/PHPUnit”: “>=3.7.0”
  • 34. Artifact Repository   Scans directory of zip files with composer.json files in the root of the zip. Uses package and version in composer.json file. { "repositories": [ { "type": "artifact", "url": "path/to/zips/dir” } ] }
  • 35. Package Repository Defines the package and versions in the composer.json file.  Uses the same format as packages.json file from Composer repository.  Allows for providing shared code that is not available by any of the other means. 
  • 36. Package Repository Example {“packages”: [ { "type": "package", "package": { "name": ”smarty/smarty", "version": ”3.1.7", "dist": { "url": "http://www.smarty.net/files/Smarty3.1.7.zip", "type": "zip” } } } ]}
  • 37. Simple repository management for small organizations
  • 38. Satis: Easy as Pie Maintain a JSON based meta-data file with the list of repositories to scour.  Execute the command and it will provide:   Composer compliant packages.json file  HTML file with instructions on adding the repository to a composer.json file as well as a filterable list.
  • 39. Satis: Repository Cache If the archive section is configured in the Satis meta-data file, Satis will scan all repositories defined and create local archives  If options require-dependencies is set to true, it will also cache dependencies. This only works on known packages in the defined repositories.  Here’s a link to an excellent article on how to affectively cache packagist.org: http://tech.m6web.fr/composer-installationwithout-github.html 
  • 40. Satis Metadata Example { "name": "My Repository", "homepage": "http://satis.my.org", "repositories": [ { "type": "vcs", "url": "http://github.com/my/repo" } ], "require-all": true }
  • 41. Satis Conclusions      Simple to use Easy to deploy Full PHP implementation Uses static files for hosting Can cache repositories from VCS and Packagist     Requires management of a config file Becomes unwieldy for large numbers of packages Limited search and package information Requires shared disk for HA
  • 43. Packagist…and a bag of chips Web based package management  Optimized search via Solr  Allows for high availability via MySQL  API for remotely triggering package scans  Package statistics 
  • 44. Packagist Conclusions     Web based management interface Solr based search HA capable Virtually unlimited package management     No archives for non Github/BitBucket VCS repositories Complex architecture Requires MySQL and Solr knowledge and management Only VCS packages
  • 45. Your one stop shop for open source projects and libraries
  • 46. One Repository to Rule Them All 21,762 packages (1/7/2014)  Default package manager for Composer  Free accounts to register/maintain packages  Contains nearly every widely used open source PHP package  Just use it! 
  • 47. Registering a package       Get a user Log in Click “Submit a Package” Enter the URL for your public repository Click “Check” Optionally but suggested: Register a commit hook to scan for updates on commit.  Github has a pre-configured hook  BitBucket can use a POST hook