Results 1 to 7 of 7

Thread: Web Development Environment Setup

  1. #1
    Join Date
    Feb 2010

    Web Development Environment Setup

    I have been looking around the web and forums for a while for the best way to set up a development office. I havent really found many specifics.

    I am with a new company is just starting to really take their development services seriously. We've added a couple developers and designers in the last month. I am trying to figure out a the best way to set up our environment.

    We have a couple dedicated virtual servers with Media Temple. Currently, we develop everything under a subdomain of a domain we set up for development. When the site is ready to go live we move the site to its own domain. I cant believe this is the best way to go about things. So, what do you guys suggest as a setup? Software, versioning, etc. We have the ability to setup a test server in house and then push out changes to the production server but not really sure if that is needed.

    We do mainly Wordpress development.

    Any advice, links to articles, etc is appreciated.

    If this should be posted in another area, please let me know.


  2. #2
    Join Date
    Sep 2009
    I would also like to know this answer.
    Thank you

  3. #3
    Join Date
    Jan 2007
    First, see my response to this thread: http://www.webdeveloper.com/forum/sh...67#post1144867

    Now, as a member of a client organization dealing with larger development firms, I've found that, while there is no single way to do things, there are some patterns to follow:

    Use subversion or CVS. Simple -- just make sure your project is under some version control somewhere. So far, I have yet to encounter anyone using anything other than subversion.

    Multiple working copies. You'll have multiple functioning copies of the application, each of which gets updated on a different schedule, and each of which will have different levels of reliability and testing needs. So, you may end up with "layers" like this:

    Lives on: the actual development machine(s): you and your co-developers' local PCs, macbooks, etc.
    Updated: constantly -- every time code is changed.
    Reliability: consider these copies highly unreliable -- they should have their own data sets.

    Lives on: a publicly accessible server, possibly password protected to protect IP, which may or may not live on the production server
    Updated: often -- daily, weekly, or whenever you accomplish something and are reasonably sure it's stable
    reliability: pretty low -- it uses its own dataset, which may even have a lot of lingering structures from past explorations and tests

    Lives on: a publicly accessible server, which may or may not be the alpha and/or production server
    Updated: whenever the project on alpha reaches a state that is ready for final QA before going to production
    reliability: pretty good -- beta environments can sometimes even share data with production, depending on whether there are outstanding schema updates to make to the production dataset

    Self explanatory -- the public application.

    Now, some firms will break down alpha, beta, or staging environments even further. Some developers will simply have one beta environment that serves most or all non-production needs. And how you lay these all out on hardware is really up to you. If you're working on a multi-core machine and ensure that your database connections are configured safely and correctly, you generally don't have to worry about your dev/alpha/staging copies affecting live. And if everything is on the same hardware, it can make turning your alpha into beta and beta into staging and staging into production really snappy.

    In terms of the virtual hosting setup -- I tend to prefer giving each stage its own hostname:
    local.sitename.com : local hosts entry ->
    alpha.sitename.com : local OR actual DNS entry -> alpha server
    beta.sitename.com : actual DNS entry -> beta server, could be same as alpha or beta
    staging.sitename.com : actual DNS entry -> probably same as live server
    www.sitename.com : actual DNS entry -> live server ... obviously.

    And the application needs to be smart enough to "know" which host it's working under, refer to files correctly, and use the right data resources. For me, I have found that this is best done placing a localconfig file on each environment that lives outside the repository or "project" (if using an IDE), that will not be overwritten on accident, and serves to rewrite a set of default values. (so the site functions as the LIVE site in the absence of that file -- so when you package up the app and hand it off, you don't have to worry about forgetting to include some file that doesn't exist in your project)

    ... is that at all helpful? Sorry for the rambling.
    Jon Wire

    thepointless.com | rounded corner generator

    I agree with Apple. Flash is just terrible.

    Use CODE tags!

  4. #4
    Join Date
    Mar 2010

    Your reply was quite comprehensive and was close to what I am looking for. Can you please help me a little further to implement this setup in combination of windows and linux environment.

    My current setup is like

    1. I have development environment setup on my local windows machine with version control (subversion).
    2. I upload files with some FTP client OR built-in FTP support of netbeans to Remote Server.

    Now to transform this in to wonderful system you proposed...

    I want to continue coding on my local environment but I want to test it on remote server (which can have subversion repository also) by creating a test subdomain. Once my test results are satisfactory then I can move code/files to production environment which is of course on same remote server.

    For me confusion arises about...

    1. How can I upload local files to remote test repository without FTP.
    2. What will be the best way of setting up repository on Remote Server so I can easily commit changes from test environment to live environment.


  5. #5
    Join Date
    Jan 2007
    I'm a little confused about what you're asking.

    The dev/alpha/beta/live instances I'm referring to above aren't tied to different repos. They're all just site instances. I called them working copies from a PHP dev's perspective, since your WC usually "is" a functioning site instance. If you're working with a compiled language, like C#, the site instances are just builds that you FTP/SFTP out (or copy over the network, or to your inetpub folder, or whatever).

    In terms of a repository, you should only have one per application or project. And you need to follow whatever other "best" practices suit your needs. If you're a solo developer, you just need to ensure you always have a branch you can recreate the live site from -- everything else is up to you. If you're working in a group, same thing, except you need to ensure folks know which branch to be working on at any given time for any given "feature" or bug. Etc.

    Where that repository lives is up to you. I've actually gotten out of the business of managing subversion installs and just gone with a hosted solution (http://repositoryhosting.com/). But, you don't FTP to or from a repository. You perform updates, commits, etc. All it does it keep track of your code revisions.

    But, once you're ready for a client (or the world) to see the fruits of your labor, you can just publish the app by whatever means you normally do. (You CAN use subversion to help with this, but that's not necessary, and it's not the big point here.)
    Jon Wire

    thepointless.com | rounded corner generator

    I agree with Apple. Flash is just terrible.

    Use CODE tags!

  6. #6
    Join Date
    Mar 2010
    Thank you very much for your reply. I am sorry if I wasn't clear enough with my problem. Right now, I am a bit confused to how to integrate subversion in my processes.

    My website is in PHP/Mysql. All I want is a way I can continue coding in my local environment (yes, currently I am the solo developer) and then by some mean (definitely not FTP) upload updates to the test area of the remote server. Once testing is done deploy it to the live site.

    Is it possible to make repository with 3 instances dev/test/prod on the remote server? What is the best practice to access dev version to create/update the code. I am using netbeans IDE.

  7. #7
    Join Date
    Jan 2007
    You create a single repository. It's primary purpose is to track and backup revisions of your working copy. If you want to also use it to assist in publishing the code, you can do that. But, it depends entirely on your publishing model.

    When I develop PHP, I work directly out of the docroot on my development machine. I exclude files with credentials from the repository. I perform regular svn commits, etc.

    When it comes time to publish to machine X, I ssh into machine X, CD to the docroot for the site, and perform an svn update to grab the latest changes. (This works with PHP b/c your working copy can be the same as your published, running copy.) I then FTP or edit credentials files separately.

    If you're not working directly from a local docroot, and you instead work from a "project" directory and hit a "publish" button, you may have two repositories, if you want to avoid FTPing anything. One repo to version the actual project code. And another to version the builds (the docroot).
    Jon Wire

    thepointless.com | rounded corner generator

    I agree with Apple. Flash is just terrible.

    Use CODE tags!

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center



X vBulletin 4.2.2 Debug Information

  • Page Generation 0.12850 seconds
  • Memory Usage 2,915KB
  • Queries Executed 15 (?)
More Information
Template Usage (32):
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_global_above_footer
  • (1)ad_global_below_navbar
  • (1)ad_global_header1
  • (1)ad_global_header2
  • (1)ad_navbar_below
  • (1)ad_showthread_firstpost_sig
  • (1)ad_showthread_firstpost_start
  • (1)ad_thread_first_post_content
  • (1)ad_thread_last_post_content
  • (1)footer
  • (1)forumjump
  • (1)forumrules
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (1)headinclude_bottom
  • (7)memberaction_dropdown
  • (1)navbar
  • (4)navbar_link
  • (1)navbar_moderation
  • (1)navbar_noticebit
  • (1)navbar_tabs
  • (2)option
  • (7)postbit
  • (7)postbit_onlinestatus
  • (7)postbit_wrapper
  • (1)spacer_close
  • (1)spacer_open
  • (1)tagbit_wrapper 

Phrase Groups Available (6):
  • global
  • inlinemod
  • postbit
  • posting
  • reputationlevel
  • showthread
Included Files (26):
  • ./showthread.php
  • ./global.php
  • ./includes/class_bootstrap.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/functions_navigation.php
  • ./includes/class_friendly_url.php
  • ./includes/class_hook.php
  • ./includes/class_bootstrap_framework.php
  • ./vb/vb.php
  • ./vb/phrase.php
  • ./includes/functions_facebook.php
  • ./includes/functions_calendar.php
  • ./includes/functions_bigthree.php
  • ./includes/class_postbit.php
  • ./includes/class_bbcode.php
  • ./includes/functions_reputation.php
  • ./includes/functions_notice.php
  • ./packages/vbattach/attach.php
  • ./vb/types.php
  • ./vb/cache.php
  • ./vb/cache/db.php
  • ./vb/cache/observer/db.php
  • ./vb/cache/observer.php 

Hooks Called (72):
  • init_startup
  • friendlyurl_resolve_class
  • init_startup_session_setup_start
  • database_pre_fetch_array
  • database_post_fetch_array
  • init_startup_session_setup_complete
  • global_bootstrap_init_start
  • global_bootstrap_init_complete
  • cache_permissions
  • fetch_postinfo_query
  • fetch_postinfo
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • load_show_variables
  • load_forum_show_variables
  • global_state_check
  • global_bootstrap_complete
  • global_start
  • style_fetch
  • global_setup_complete
  • showthread_start
  • showthread_getinfo
  • strip_bbcode
  • friendlyurl_clean_fragment
  • friendlyurl_geturl
  • forumjump
  • cache_templates
  • cache_templates_process
  • template_register_var
  • template_render_output
  • fetch_template_start
  • fetch_template_complete
  • parse_templates
  • fetch_musername
  • notices_check_start
  • notices_noticebit
  • process_templates_complete
  • friendlyurl_redirect_canonical
  • showthread_post_start
  • showthread_query_postids
  • showthread_query
  • bbcode_fetch_tags
  • bbcode_create
  • showthread_postbit_create
  • postbit_factory
  • postbit_display_start
  • postbit_imicons
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • postbit_display_complete
  • memberaction_dropdown
  • tag_fetchbit_complete
  • forumrules
  • navbits
  • navbits_complete
  • build_navigation_data
  • build_navigation_array
  • check_navigation_permission
  • process_navigation_links_start
  • process_navigation_links_complete
  • set_navigation_menu_element
  • build_navigation_menudata
  • build_navigation_listdata
  • build_navigation_list
  • set_navigation_tab_main
  • set_navigation_tab_fallback
  • navigation_tab_complete
  • fb_like_button
  • showthread_complete
  • page_templates