Skip to content

Commit

Permalink
Move doc website tomo-deploy.com → tomo.mattbrictson.com (#403)
Browse files Browse the repository at this point in the history
  • Loading branch information
mattbrictson authored Sep 11, 2023
1 parent ad63ce9 commit 631cbac
Show file tree
Hide file tree
Showing 14 changed files with 56 additions and 56 deletions.
86 changes: 43 additions & 43 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Tomo is a friendly command-line tool for deploying Rails apps.
📚 Quality documentation<br/>
🔬 Minimal dependencies<br/>

[→ See how tomo compares to other Ruby deployment tools like Capistrano and Mina.](https://tomo-deploy.com/comparisons/)
[→ See how tomo compares to other Ruby deployment tools like Capistrano and Mina.](https://tomo.mattbrictson.com/comparisons/)

---

Expand Down Expand Up @@ -88,8 +88,8 @@ end

#### Next steps

[→ The reference docs have a complete guide to tomo configuration.](https://tomo-deploy.com/configuration/)<br>
[→ Check out the **Deploying Rails From Scratch** tutorial for a step-by-step guide to using tomo with a real app.](https://tomo-deploy.com/tutorials/deploying-rails-from-scratch/)
[→ The reference docs have a complete guide to tomo configuration.](https://tomo.mattbrictson.com/configuration/)<br>
[→ Check out the **Deploying Rails From Scratch** tutorial for a step-by-step guide to using tomo with a real app.](https://tomo.mattbrictson.com/tutorials/deploying-rails-from-scratch/)

## Usage

Expand All @@ -113,24 +113,24 @@ Out of the box, tomo will:
- Create all necessary deployment directories
- Create the Rails database, load the schema, and insert seed data

[→ Here is the default list of tasks invoked by the setup command.](https://tomo-deploy.com/configuration#setupblock)<br>
[→ The `tomo setup` section of the reference docs explains supported command-line options.](https://tomo-deploy.com/commands/setup/)
[→ Here is the default list of tasks invoked by the setup command.](https://tomo.mattbrictson.com/configuration#setupblock)<br>
[→ The `tomo setup` section of the reference docs explains supported command-line options.](https://tomo.mattbrictson.com/commands/setup/)

### `tomo deploy`

Whereas `tomo setup` is typically run once, you can use `tomo deploy` every time you want to deploy a new version of your app. The deploy command will sequentially run the `deploy` list of tasks specified in `.tomo/config.rb`. You can customize this list to meet the needs of your app. By default, tomo runs these tasks:

1. Create a release (using the [git:create_release](https://tomo-deploy.com/plugins/git#gitcreate_release) task)
2. Build the project (e.g. [bundler:install](https://tomo-deploy.com/plugins/bundler#bundlerinstall), [rails:assets_precompile](https://tomo-deploy.com/plugins/rails#railsassets_precompile))
3. Migrate data to the meet the requirements of the new release (e.g. [rails:db_migrate](https://tomo-deploy.com/plugins/rails#railsdb_migrate))
4. Make the new release the "current" one ([core:symlink_current](https://tomo-deploy.com/plugins/core#coresymlink_current))
5. Restart the app to use the new current release (e.g. [puma:restart](https://tomo-deploy.com/plugins/puma#pumarestart))
6. Perform any cleanup (e.g. [bundler:clean](https://tomo-deploy.com/plugins/bundler#bundlerclean))
1. Create a release (using the [git:create_release](https://tomo.mattbrictson.com/plugins/git#gitcreate_release) task)
2. Build the project (e.g. [bundler:install](https://tomo.mattbrictson.com/plugins/bundler#bundlerinstall), [rails:assets_precompile](https://tomo.mattbrictson.com/plugins/rails#railsassets_precompile))
3. Migrate data to the meet the requirements of the new release (e.g. [rails:db_migrate](https://tomo.mattbrictson.com/plugins/rails#railsdb_migrate))
4. Make the new release the "current" one ([core:symlink_current](https://tomo.mattbrictson.com/plugins/core#coresymlink_current))
5. Restart the app to use the new current release (e.g. [puma:restart](https://tomo.mattbrictson.com/plugins/puma#pumarestart))
6. Perform any cleanup (e.g. [bundler:clean](https://tomo.mattbrictson.com/plugins/bundler#bundlerclean))

> 💡 **Protip:** you can abbreviate tomo commands, like `tomo d` for `tomo deploy` or `tomo s` for `tomo setup`.
[→ Here is the default list of tasks invoked by the deploy command.](https://tomo-deploy.com/configuration#deployblock)<br>
[→ The `tomo deploy` section of the reference docs explains supported command-line options, like `--dry-run`.](https://tomo-deploy.com/commands/deploy/)
[→ Here is the default list of tasks invoked by the deploy command.](https://tomo.mattbrictson.com/configuration#deployblock)<br>
[→ The `tomo deploy` section of the reference docs explains supported command-line options, like `--dry-run`.](https://tomo.mattbrictson.com/commands/deploy/)

### `tomo run [TASK]`

Expand All @@ -144,7 +144,7 @@ One of the built-in Rails tasks is `rails:console`, which brings up a fully-inte

> 💡 **Protip:** you can shorten this as `tomo rails:console` (the `run` command is implied).
[→ The `tomo run` section of the reference docs explains supported command-line options and has more examples.](https://tomo-deploy.com/commands/run/)
[→ The `tomo run` section of the reference docs explains supported command-line options and has more examples.](https://tomo.mattbrictson.com/commands/run/)

## Extending tomo

Expand All @@ -170,47 +170,47 @@ And run it!

![$ tomo run my-plugin:hello](./readme_images/tomo-run-hello.png)

[→ The **Writing Custom Tasks** tutorial has an in-depth explanation of how plugins work.](https://tomo-deploy.com/tutorials/writing-custom-tasks/)<br>
[→ The **TaskLibrary** API is tomo's DSL for building tasks.](https://tomo-deploy.com/api/TaskLibrary/)<br>
[→ The **Publishing a Plugin** tutorial explains how to package your plugin as a Ruby gem to share it with the community.](https://tomo-deploy.com/tutorials/publishing-a-plugin/)
[→ The **Writing Custom Tasks** tutorial has an in-depth explanation of how plugins work.](https://tomo.mattbrictson.com/tutorials/writing-custom-tasks/)<br>
[→ The **TaskLibrary** API is tomo's DSL for building tasks.](https://tomo.mattbrictson.com/api/TaskLibrary/)<br>
[→ The **Publishing a Plugin** tutorial explains how to package your plugin as a Ruby gem to share it with the community.](https://tomo.mattbrictson.com/tutorials/publishing-a-plugin/)

## Tutorials

- [Deploying Rails From Scratch](https://tomo-deploy.com/tutorials/deploying-rails-from-scratch/)
- [Writing Custom Tasks](https://tomo-deploy.com/tutorials/writing-custom-tasks/)
- [Publishing a Plugin](https://tomo-deploy.com/tutorials/publishing-a-plugin/)
- [Deploying Rails From Scratch](https://tomo.mattbrictson.com/tutorials/deploying-rails-from-scratch/)
- [Writing Custom Tasks](https://tomo.mattbrictson.com/tutorials/writing-custom-tasks/)
- [Publishing a Plugin](https://tomo.mattbrictson.com/tutorials/publishing-a-plugin/)

## Blog posts

- [Automate Rails deployments with GitHub Actions](https://mattbrictson.com/blog/deploy-rails-with-github-actions)

## Reference documentation

- [Configuration](https://tomo-deploy.com/configuration/)
- [Configuration](https://tomo.mattbrictson.com/configuration/)
- Commands
- [init](https://tomo-deploy.com/commands/init/)
- [setup](https://tomo-deploy.com/commands/setup/)
- [deploy](https://tomo-deploy.com/commands/deploy/)
- [run](https://tomo-deploy.com/commands/run/)
- [tasks](https://tomo-deploy.com/commands/tasks/)
- [init](https://tomo.mattbrictson.com/commands/init/)
- [setup](https://tomo.mattbrictson.com/commands/setup/)
- [deploy](https://tomo.mattbrictson.com/commands/deploy/)
- [run](https://tomo.mattbrictson.com/commands/run/)
- [tasks](https://tomo.mattbrictson.com/commands/tasks/)
- Plugins
- [core](https://tomo-deploy.com/plugins/core/)
- [bundler](https://tomo-deploy.com/plugins/bundler/)
- [env](https://tomo-deploy.com/plugins/env/)
- [git](https://tomo-deploy.com/plugins/git/)
- [nodenv](https://tomo-deploy.com/plugins/nodenv/)
- [puma](https://tomo-deploy.com/plugins/puma/)
- [rails](https://tomo-deploy.com/plugins/rails/)
- [rbenv](https://tomo-deploy.com/plugins/rbenv/)
- [core](https://tomo.mattbrictson.com/plugins/core/)
- [bundler](https://tomo.mattbrictson.com/plugins/bundler/)
- [env](https://tomo.mattbrictson.com/plugins/env/)
- [git](https://tomo.mattbrictson.com/plugins/git/)
- [nodenv](https://tomo.mattbrictson.com/plugins/nodenv/)
- [puma](https://tomo.mattbrictson.com/plugins/puma/)
- [rails](https://tomo.mattbrictson.com/plugins/rails/)
- [rbenv](https://tomo.mattbrictson.com/plugins/rbenv/)
- API
- [Host](https://tomo-deploy.com/api/Host/)
- [Logger](https://tomo-deploy.com/api/Logger/)
- [Paths](https://tomo-deploy.com/api/Paths/)
- [PluginDSL](https://tomo-deploy.com/api/PluginDSL/)
- [Remote](https://tomo-deploy.com/api/Remote/)
- [Result](https://tomo-deploy.com/api/Result/)
- [TaskLibrary](https://tomo-deploy.com/api/TaskLibrary/)
- [Testing::MockPluginTester](https://tomo-deploy.com/api/testing/MockPluginTester/)
- [Host](https://tomo.mattbrictson.com/api/Host/)
- [Logger](https://tomo.mattbrictson.com/api/Logger/)
- [Paths](https://tomo.mattbrictson.com/api/Paths/)
- [PluginDSL](https://tomo.mattbrictson.com/api/PluginDSL/)
- [Remote](https://tomo.mattbrictson.com/api/Remote/)
- [Result](https://tomo.mattbrictson.com/api/Result/)
- [TaskLibrary](https://tomo.mattbrictson.com/api/TaskLibrary/)
- [Testing::MockPluginTester](https://tomo.mattbrictson.com/api/testing/MockPluginTester/)

## FAQ

Expand All @@ -227,7 +227,7 @@ set ssh_strict_host_key_checking: true # or false

Tomo relies on the host user's bash profile for various things, like setting environment variables and initializing rbenv and nodenv. This makes it impractical to deploy multiple apps to a single host using the same deploy user.

The solution is to create multiple users on the remote host, and then configure a different user for deploying each app. That way each user can have its own distinct environment variables and you can easily configure each app differently without risking conflicts. Refer to the [tomo Rails tutorial](https://tomo-deploy.com/tutorials/deploying-rails-from-scratch/#set-up-a-deployer-user) for instructions on creating a deploy user.
The solution is to create multiple users on the remote host, and then configure a different user for deploying each app. That way each user can have its own distinct environment variables and you can easily configure each app differently without risking conflicts. Refer to the [tomo Rails tutorial](https://tomo.mattbrictson.com/tutorials/deploying-rails-from-scratch/#set-up-a-deployer-user) for instructions on creating a deploy user.

E.g. app1 would be configured to deploy as:

Expand Down
2 changes: 1 addition & 1 deletion custom_theme/main.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{% extends "base.html" %}

{% block extrahead %}
<script defer data-domain="tomo-deploy.com" src="https://plausible.io/js/script.js"></script>
<script defer data-domain="tomo.mattbrictson.com" src="https://plausible.io/js/script.js"></script>
{% endblock %}
2 changes: 1 addition & 1 deletion docs/CNAME
Original file line number Diff line number Diff line change
@@ -1 +1 @@
tomo-deploy.com
tomo.mattbrictson.com
2 changes: 1 addition & 1 deletion lib/tomo/commands/default.rb
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ def banner
Or read the full documentation for all commands at:
#{blue('https://tomo-deploy.com/')}
#{blue('https://tomo.mattbrictson.com/')}
BANNER
end

Expand Down
2 changes: 1 addition & 1 deletion lib/tomo/commands/deploy.rb
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ def banner
More documentation and examples can be found here:
#{blue('https://tomo-deploy.com/commands/deploy')}
#{blue('https://tomo.mattbrictson.com/commands/deploy')}
BANNER
end

Expand Down
2 changes: 1 addition & 1 deletion lib/tomo/commands/run.rb
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ def banner
For more documentation and examples, visit:
#{blue('https://tomo-deploy.com/commands/run')}
#{blue('https://tomo.mattbrictson.com/commands/run')}
BANNER
end

Expand Down
2 changes: 1 addition & 1 deletion lib/tomo/commands/setup.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ def banner
More documentation and examples can be found here:
#{blue('https://tomo-deploy.com/commands/setup')}
#{blue('https://tomo.mattbrictson.com/commands/setup')}
BANNER
end

Expand Down
2 changes: 1 addition & 1 deletion lib/tomo/configuration/dsl/error_formatter.rb
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ def to_console
#{highlighted_lines}
#{Colors.red([self.class, message].join(': '))}
Visit #{Colors.blue('https://tomo-deploy.com/configuration')} for syntax reference.
Visit #{Colors.blue('https://tomo.mattbrictson.com/configuration')} for syntax reference.
#{trace_hint}
ERROR
end
Expand Down
2 changes: 1 addition & 1 deletion lib/tomo/plugin/env/tasks.rb
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ def fail_if_different_app_already_configured!(bashrc)
user@host. To deploy multiple applications to the same host, use a separate
deployer user per app. Refer to the tomo FAQ for details:
https://tomo-deploy.com/#faq
https://tomo.mattbrictson.com/#faq
You may be receiving this message in error if you recently renamed or
reconfigured your application. In this case, remove the references to the
Expand Down
2 changes: 1 addition & 1 deletion lib/tomo/runtime/no_tasks_error.rb
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ def to_console
More configuration documentation and examples can be found here:
#{blue('https://tomo-deploy.com/configuration')}
#{blue('https://tomo.mattbrictson.com/configuration')}
ERROR
end
end
Expand Down
2 changes: 1 addition & 1 deletion lib/tomo/templates/plugin.rb.erb
Original file line number Diff line number Diff line change
@@ -1 +1 @@
# https://tomo-deploy.com/tutorials/writing-custom-tasks/
# https://tomo.mattbrictson.com/tutorials/writing-custom-tasks/
2 changes: 1 addition & 1 deletion test/tomo/cli_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ def test_prints_error_when_config_dsl_is_used_incorrectly
ArgumentError: wrong number of arguments (given 0, expected 1)
Visit https://tomo-deploy.com/configuration for syntax reference.
Visit https://tomo.mattbrictson.com/configuration for syntax reference.
You can run this command again with --trace for a full backtrace.
OUTPUT
Expand Down
2 changes: 1 addition & 1 deletion test/tomo/commands/init_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ def test_generates_a_sample_plugin_with_comment
@tester.run "init"

app = File.basename(File.expand_path("."))
assert_match(%r{^# https://tomo-deploy.com}, File.read(".tomo/plugins/#{app}.rb"))
assert_match(%r{^# https://tomo.mattbrictson.com}, File.read(".tomo/plugins/#{app}.rb"))
end
end

Expand Down
2 changes: 1 addition & 1 deletion tomo.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ Gem::Specification.new do |spec|
"changelog_uri" => "https://github.com/mattbrictson/tomo/releases",
"source_code_uri" => "https://github.com/mattbrictson/tomo",
"homepage_uri" => spec.homepage,
"documentation_uri" => "https://tomo-deploy.com/",
"documentation_uri" => "https://tomo.mattbrictson.com/",
"rubygems_mfa_required" => "true"
}

Expand Down

0 comments on commit 631cbac

Please sign in to comment.