Deploying with Rsync via SSH
Add your server configurations to the
Rakefile under Rsync deploy config. To deploy with Rsync, be sure your public key is listed in your server’s
1 2 3
Now if you run
in your terminal, your
public directory will be synced to your server’s document root.
Deploying to Github Pages
To setup deployment, you’ll want to clone your target repository into the
_deploy directory in your Octopress project.
If you’re using Github user or organization pages, clone the repository
With Github User/Organization pages
With Github Project pages (gh-pages)
config_deploy rake task takes a branch name as an argument and creates a new empty branch, and adds an initial commit.
This also sets
deploy_default = "push" in your
_config.yml and prepares your branch for easy deployment. The
rake deploy task copies the generated blog from the
public directory to the
_deploy directory, adds new files, removes old files, sets a commit message, and pushes to Github.
Github will queue your site for publishing (which usually occurs instantly or within minutes if it’s your first commit).
Now you should be set up to deploy, just run
Deploying to a Subdirectory (Github Project Pages does this)
If you’re deploying to a subdirectory on your site, or if you’re using Github’s project pages, make sure you set up your urls correctly in your configs. You can do this almost automatically:
1 2 3 4
Then update your
Rakefile as follows:
1 2 3 4 5
To manually configure deployment to a subdirectory, you’ll change
Here’s an example for deploying the Octopress website to Github Project Pages:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16