meskyanichi-generators 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. data/README.rdoc +28 -26
  2. data/Rakefile +2 -1
  3. data/VERSION.yml +1 -1
  4. metadata +12 -3
data/README.rdoc CHANGED
@@ -9,49 +9,51 @@ For now the gem only provides a generator for a simple capistrano template.
9
9
 
10
10
  Essentially what this does, is generate a basic Capistrano deployment recipe. The recipe does a couple of things initially when you set it up.
11
11
 
12
- - Create the necessary folders and files, namely the releases, current(symlink) and the shared folder
13
- - Creates a log folder and generates a new production.log
14
- - Creates a config folder and then syncs the database.yml from your Rails application to the remote server
12
+ Create the necessary folders and files, namely the releases, current(symlink) and the shared folder
13
+ Creates a log folder and generates a new production.log
14
+ Creates a config folder and then syncs the database.yml from your Rails application to the remote server
15
15
 
16
16
  During every deployment, the recipe will:
17
17
 
18
- - Update your remote repository before deployment to ensure all files are up to date
19
- - After deployment, will restart the application for Passenger
20
- - After deployment, will place the symlinks for the database and production.log files correctly
21
- - Make the javascripts and stylesheets directory, located in the RAILS_ROOT/public directory, writable to avoid script caching errors
18
+ Update your remote repository before deployment to ensure all files are up to date
19
+ After deployment, will restart the application for Passenger
20
+ After deployment, will place the symlinks for the database and production.log files correctly
21
+ Make the javascripts and stylesheets directory, located in the RAILS_ROOT/public directory,
22
+ writable to avoid script caching errors
22
23
 
23
24
  If you wish to generate the simple Capistrano Template, open the terminal, go to the root of your rails application and type the following:
24
25
 
25
- script/generate capistrano_template
26
+ script/generate capistrano_template
26
27
 
27
28
  This will generate the capistrano template which you help you get up and running.
28
29
 
29
30
  You can also pass in additional arguments to let the generator help you fill in Capistrano recipe.
30
31
 
31
- script/generate capistrano_template MyDomain.com git ssh://MyDomain.com/MyRepository.git master root /var/www/vhosts/MyDomain.com/httpdocs
32
+ script/generate capistrano_template MyDomain.com
33
+ git ssh://MyDomain.com/MyRepository.git master root /var/www/vhosts/MyDomain.com/httpdocs
32
34
 
33
35
  If you fill in the above correctly, (this also depends on your server setup / OS / etc), then it should work right out of the box.
34
36
 
35
37
  Below are the arguments which you can provide, in order:
36
38
 
37
- domain_name (e.g. MyDomain.com)
38
- scm (e.g. git)
39
- repository (e.g. ssh://MyDomain.com/MyRepository.git)
40
- branch (e.g. master)
41
- user (e.g. root)
42
- deploy_to (e.g. /var/www/vhosts/MyDomain.com/httpdocs)
39
+ domain_name (e.g. MyDomain.com)
40
+ scm (e.g. git)
41
+ repository (e.g. ssh://MyDomain.com/MyRepository.git)
42
+ branch (e.g. master)
43
+ user (e.g. root)
44
+ deploy_to (e.g. /var/www/vhosts/MyDomain.com/httpdocs)
43
45
 
44
46
  This generates the deploy.rb file with the specified settings in the RAILS_ROOT/config directory.
45
47
 
46
48
  Now the whole process in steps:
47
49
 
48
- 1: sudo gem install meskyanichi-generators
49
- 2: go to root of rails app and type "capify ."
50
- 3: then type "script/generate capistrano_template [arg1..arg6]"
51
- 4: when it prompts if you wish to overwrite, type "y" and hit return
52
- 5: now type "cap deploy:setup" to set up the whole directory structure and files
53
- 6: after the setup is finished, and assuming you have your local git repository set up correctly,
54
- type "cap deploy" and your application will go live in a matter of seconds!
50
+ 1: sudo gem install meskyanichi-generators
51
+ 2: go to root of rails app and type "capify ."
52
+ 3: then type "script/generate capistrano_template [arg1..arg6]"
53
+ 4: when it prompts if you wish to overwrite, type "y" and hit return
54
+ 5: now type "cap deploy:setup" to set up the whole directory structure and files
55
+ 6: after the setup is finished, and assuming you have your local git repository set up correctly,
56
+ type "cap deploy" and your application will go live in a matter of seconds!
55
57
 
56
58
  If you did not fill in all the arguments, or wish double check if it was all set up correctly, open the
57
59
  deploy.rb file located in the config directory and have a look. You can easily modify everything to your liking as well!
@@ -62,21 +64,21 @@ deploy.rb file located in the config directory and have a look. You can easily m
62
64
  The recipe provides a few commands which are pretty useful. Including syncing your local database.yml file
63
65
  with the one on the server so that you are not forced to go SSH or FTP to the server to manually change it.
64
66
 
65
- cap deploy:sync_database
67
+ cap deploy:sync_database
66
68
 
67
69
  If you wish to restart your application for Passenger without re-deploying your application, for example, after syncing the new database.yml,
68
70
  and you once again don't want to SHH manually, then you can do a:
69
71
 
70
- cap deploy:restart
72
+ cap deploy:restart
71
73
 
72
74
  This will restart the application for Passenger.
73
75
 
74
- cap deploy:setup
76
+ cap deploy:setup
75
77
 
76
78
  This will run the setup task, which will do everything Capistrano does out of the box,
77
79
  but also executes the tasks I mentioned at the top of this README.
78
80
 
79
- cap deploy
81
+ cap deploy
80
82
 
81
83
  After you've setup Capistrano correctly using the cap deploy:setup, you may now use the above command to deploy your rails application!
82
84
 
data/Rakefile CHANGED
@@ -9,7 +9,8 @@ begin
9
9
  gem.email = "meskyan@gmail.com"
10
10
  gem.homepage = "http://github.com/meskyanichi/generators"
11
11
  gem.authors = ["Michael"]
12
-
12
+ gem.add_dependency('capistrano')
13
+
13
14
  # gem is a Gem::Specification... see http://www.rubygems.org/read/chapter/20 for additional settings
14
15
  end
15
16
  rescue LoadError
data/VERSION.yml CHANGED
@@ -1,4 +1,4 @@
1
1
  ---
2
2
  :major: 0
3
3
  :minor: 1
4
- :patch: 0
4
+ :patch: 1
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: meskyanichi-generators
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael
@@ -11,8 +11,17 @@ cert_chain: []
11
11
 
12
12
  date: 2009-06-02 00:00:00 -07:00
13
13
  default_executable:
14
- dependencies: []
15
-
14
+ dependencies:
15
+ - !ruby/object:Gem::Dependency
16
+ name: capistrano
17
+ type: :runtime
18
+ version_requirement:
19
+ version_requirements: !ruby/object:Gem::Requirement
20
+ requirements:
21
+ - - ">="
22
+ - !ruby/object:Gem::Version
23
+ version: "0"
24
+ version:
16
25
  description:
17
26
  email: meskyan@gmail.com
18
27
  executables: []