Drupal Enterprise: Updating Your Site Code

The following instructions are for websites using the default UMN Drupal Enterprise configuration.

After you have installed UMN Drupal locally to work with the UMN Git repository, you can push code to your repository by following these steps.

Pushing code to your Git repository

 

  1. Open your terminal.
  2. If you have not cloned your site's repository to your local computer, run the command git clone [clone URL] [name of directory].
  3. Run the command cd to navigate to your repository's main folder.
    cd [name of directory]
  4. Run the command git checkout to change branches to the one that should be updated.
  5. Run the command git pull to copy any changes from the github repository to your local repository.
  6. Add or update the needed files in the local repository using a text editor.
  7. Run the command git status to show which files have changed. This indicates that files have been changed / added / deleted.
  8. Run the command git add . (You need to type the period too; this will add all the modified files to the commit.)
  9. Run the command git commit -m "[message about your commit]".
    • A message will display explaining which files were committed and what type of changes were made (i.e., add / change / delete.)
  10. Run the command git push to copy all the changed files from the local repository to your github repository.
    • After all steps have been completed, your shell will look similar to this:
      Console showing completed steps
  11. Go to your repository through your web browser and verify that the changes are there. Your page should show the time of the latest commit.
    github.umn.edu repository showing changes have been pushed and last commit was 5 minutes ago

Deploy the new code to your site

  1. Dev or Stage environment:
    1. Log in to Drupal Management with your UMN Internet ID and password (http://drupalmanagement.umn.edu/saml_login)
    2. Navigate to the site you are working on
    3. Click Deploy on the environment that you are working on.
    4. Confirm the deployment.
    5. Deployment takes approximately 10 minutes.
    6. You might need to clear the Drupal caches to see your changes.
  2. Production environment: Submit Drupal Support Request form requesting that your changes be deployed.

 

Last modified

Changed

TDX ID

TDX ID
3816