*** This version of Confluence is for testing only and contains a copy of content from June 29th 2026. No changes will be preserved. ***
...
Set up the local directory
- Add these empty directories:
- backup
- drupal_config
- private_files
- public
- Let capistrano create it's files and directories
Code Block capify .- (this creates Capfile and config/deploy.rb)
- featureserver_test_library_cornell_edu
- .git
- .gitignore
- README.txt
- backup/ - place for backup files
- drupal_config/ - a place for Drupal make file and module lists
- private_files/ - point Drupal's private file directory at this directory (later)
- public/ - put your Drupal site here (later)
Here's what my .gitignore looks like.
In our environment the public directory is a 'fake submodule' containing Drupal core and some standard modules:
| Code Block |
|---|
git clone --depth 1 git@git.library.cornell.edu:drupal_7_x.git public
|
Let capistrano create its default files
...
- Change the default deploy.rb to add stages (eg. staging, production) and add a deploy directory containing a file for each stage.
- featureserver_test_library_cornell_edu
- .git
- .gitignore
- Capfile
- config
- deploy
- staging.rb
- production.rb
- deploy.rb
- deploy
- README.txt
- backup/ - place for backup files
- private_files/ - point Drupal's private file directory at this directory (later)
- public/ - put your Drupal site here (later)
...
- Here are some examples
...
- for deploy.rb, staging.rb,
...
- and production.rb
...
- that work for CUL servers.
...
- You might as well plan to customize these .rb files to suit your server and site needs, even if you're new to Ruby. You'll need to at least modify the URLs and paths wherever there is a TODO comment.
Code Block config ├── deploy │ ├── production.rb │ └── staging.rb └── deploy.rb
Now might be a good time to add all these new files into git.
| Code Block |
|---|
bash> git add Capfile config/ drupal_config/ bash> git commit Capfile -m 'inital version from capify' bash> git commit config/ -m 'staging and production deploy instructions' bash> git commit drupal_config/ -m 'where to put Drupal make file and friends' |
The Drupal Site
Next step: build the drupal site inside public/ including an installation profile we can use to build the site on a target machine.
Once you get the Drupal site set up you'll need to push that all into git also.
- Build a make file and lists of modules in the drupal_config directory
Before the first deploy
Set up the staging/production server directories
...