Wednesday, July 7, 2010

PHP Application Lifecycle: Build vs. Deploy

Over the past few days, I've been playing with Phing, a build tool for PHP, similar to Ant for Java. I initially intended to use Phing to deploy a Web application I'm developing, but I've come to realize its power as a build tool while working on a set of PHP libraries as well. Through my time with the tool, I've realized the important distinction between a build tool, such as Phing, and a deployment tool.

Many articles and tutorials around the Internet tend to focus on using Phing for three things:
  • Kicking off automated tests with PHPUnit
  • Building API documentation with PHPDocumentor
  • Deploying code to a Web server
While Phing is definitely suited for these tasks, and indeed comes with many built-in tasks for these exact purposes, it can be used — and is intended to be used — to do so much more.

In the PHP world, where code is not compiled, the primary purpose of a build tool is to prepare a code base for distribution. This usually means changing configuration files, cleaning out development-only artifacts, and packaging the code base in a neat little tarball, PEAR package, or other archive. While Phing and other build tools often have built-in support for simple deployments via rsync, scp, and other file transport mechanisms, they typically don't support truly robust deployment features.

In many environments, especially those with only a single Web server, the simple mechanisms provided by the build tools may be just fine. However, in more complex environments, these methods quickly break down, and deployment should be handled by a dedicated utility. That's not to say that Phing doesn't belong in these environments; to the contrary, the real power of Phing can shine through the most here. By taking the code base from its development environment, transforming it, testing it, and packing it, a build tool can pass off the prepared code to the deployment system with a higher level of code confidence than before.

Some time in the future, I'll discuss a little about how I'm managing my code with Phing, my deployment solutions, and introduce my other new friend, the Hudson continuous integration server.

28 comments:

  1. Hudson is definitely a nice tool. I had a much easier time working with it vs. Cruise Control (phpUnderControl)

    I'm currently using Capistrano for deployment automation (actual moving code from point A to point B). Its flexible and works well over SSH.

    ReplyDelete
    Replies
    1. I have read your blog its very attractive and impressive. I like it your blog.

      PHP Training in chennai | PHP Training Course

      PHP Training in chennai | Online PHP Course

      Delete
    2. Great Article
      Cyber Security Projects

      projects for cse

      Networking Projects

      JavaScript Training in Chennai

      JavaScript Training in Chennai

      The Angular Training covers a wide range of topics including Components, Angular Directives, Angular Services, Pipes, security fundamentals, Routing, and Angular programmability. The new Angular TRaining will lay the foundation you need to specialise in Single Page Application developer. Angular Training

      Delete
  2. Hah, thx, it's interesting.
    Great blog, keep going!

    Best regards
    Toby, electronic data room

    ReplyDelete
  3. This is an awesome post.Really very informative and creative contents. These concept is a good way to enhance the knowledge.I like it and help me to development very well.Thank you for this brief explanation and very nice information.Well, got a good knowledge.
    Java Training in Chennai

    ReplyDelete
  4. In my opinion the right decision if you want to make money pleasant casino sites come here and get real money

    ReplyDelete
  5. I like the helpful info you provide in your articles. I’ll bookmark your weblog and check again here regularly. I am quite sure I will learn much new stuff right here! Good luck for the next!
    Google ads services
    Google Ads Management agency

    ReplyDelete
  6. Thanks a lot for sharing
    Having good health is what most people out there wants but can not achieve. some people takes buy ibogaine online AND buy weed online to get it.

    ReplyDelete
  7. keep up the good work. this is an Assam post. this to helpful, i have reading here all post. i am impressed. thank you. this is our digital marketing training center. This is an online certificate course
    digital marketing training in bangalore / https://www.excelr.com/digital-marketing-training-in-bangalore

    ReplyDelete
  8. medical care is what many people lack in the interior areas of the world. people face a lot of health issues everyday without solution. buy psychedelics online, Buy weed online, Buy fantanyl patches online

    ReplyDelete
  9. Thanks for sharing What an interesting site you have i really take a good look buy cocaine online and you can also take a good look at our blog too for more information buy crack cocaine online we also recommend you to take a good look at this site too they have good content buy mdma crystals online more of the site still want you to take a closer look too as they have really good content buy crystal meth online thanks for using your time to check on the link .order cocaine online

    ReplyDelete
  10. https://k2incenseonlineheadshop.com/
    info@k2incenseonlineheadshop.com
    Buy liquid incense cheap
    Buy liquid incense cheap For Sale At The Best Incense Online Shop
    K2 Spice Spray | Liquid K2 | Liquid Spice | K2 Spray for sale

    ReplyDelete
  11. https://syntheticworldwide.com/
    sales@syntheticworldwide.com

    Buy cheap liquid herbal incense at your best online shop

    ReplyDelete

  12. https://buydocumentation.com/

    Buy Driver’s License online, US driver license, drivers license renewal ca WhatsApp +1 (925) 526-5453


    Here at Buy Documentation, you can buy fake documents at a fraction of a cost. We keep our prices low to meet the needs of all our customers. We provide Best Quality Novelty Real and Fake IDs and Passport, Marriage Certificates and Drivers license online

    https://buydocumentation.com/canada-visa/

    https://buydocumentation.com/buy-real-drivers-license/

    https://buydocumentation.com/buy-real-id-cards/

    https://buydocumentation.com/social-security-number-ssn/

    ReplyDelete

  13. herbal incense 2021,
    trusted herbal incense sites 2021,
    k2 liquid incense,
    order cheap herbal incense,
    cheap strong herbal incense,
    super strong herbal incense liquid,
    most potent herbal incense on the market,
    best herbal incense website 2021,
    k2 liquid spray on paper for sale,
    where to buy liquid herbal incense,
    buy herbal incense with debit card,
    buy herbal incense overnight shipping,
    strongest liquid incense,
    buy herbal incense online cash on delivery,
    liquid herbal incense 2020,
    k2 spray that get you high for sale,
    buy herbal net


    https://k2herbalspice.com/
    Call Us: (+1) 747-500-1520
    Email: sales@k2herbalspice.com



    herbal incense 2021,
    trusted herbal incense sites 2021,
    k2 liquid incense,
    order cheap herbal incense,
    cheap strong herbal incense,
    super strong herbal incense liquid,
    most potent herbal incense on the market,
    best herbal incense website 2021,
    k2 liquid spray on paper for sale,
    where to buy liquid herbal incense,
    buy herbal incense with debit card,
    buy herbal incense overnight shipping,
    strongest liquid incense,
    buy herbal incense online cash on delivery,
    liquid herbal incense 2020,
    k2 spray that get you high for sale,
    buy herbal net


    website: https://herbalincensespices.com/
    Call Us: +1 (312)-319-2341
    Email: sales@herbalincensespices.com


    We are located in USA AND UK. Buy High Quality Grade(%99.96) Mephedrone (2- methylamino 1-one) also known as 4-methylmethcathinone(4-MMC).We are one of the top suppliers in wholesale and retail of Benzodiazepine,synthetic cannabinoids, Blotters chemicals. Mephedrone and other plants research chemicals such as: Amphetamines Pentylone Mephedrone Flephedrone Bulytone (bk-MBDB) MDAI Analgesic Chemical CB1 and CB2 CP 47497 CP-55940 HU-210 HU-331 Ephedrine Hcl Powder JWH-018 / JWH-200,JWH-250 TFMPP 2C-E, 2C-I, 2C-P, 2C-C, 2C-T-2 DOC, DOI Bromo DragonFly TCB-2 Testosterone 5-Meo-DMT 4-Aco-DMT 4-Ho-MIPT 4-Meo-PCP Naphyrone HEROIN. Methylone (bk-MDMA) Ethylone , Oxycodone Flephedrone (4-FMC, 4-Fluoromethcathinone) Methedrone (BK-PMMA, Methoxyphedrine) 4-Fluoromethamphetamine (4-FMA) a-Pyrrolidinopropiophenone (a-PPP). MDPV (Methylenedioxypyrovalerone, MDPK) Testosterone JWH-073, 1-butyl-3-(1-naphthoyl)indole Hydrocodone Dimethocaine (Larocaine/DMC) Morphine JWH-018, 1-Pentyl-3-(1-naphthoyl)indole Herione 4-Fluoroamphetamine (4-FA, 4-FMP, or Flux) Ketamine Our quality is the best you can find around and we sell in small/large quantities with guaranteed discreet delivery in good time Shipping

    website: https://uslegitresearchchemicals.com/
    Call Us: +1 760-573-6020
    Email: info@uslegitresearchchemicals.com

    ReplyDelete
  14. Amazing Article! I would like to thank you for the efforts you had made for writing this awesome article. This article inspired me to read more. keep it up.
    Data science course in pune

    ReplyDelete