vagrant-sptsync 0.0.53 → 0.0.54

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 53d003ee76bbaf344ba90b95d9b47cd39b30054a
4
- data.tar.gz: 3f25faa1ef433564199992f8372c567eb3c5d101
3
+ metadata.gz: 73b141a676d59df55a1930dd2d6d8f017d6ea098
4
+ data.tar.gz: bb3ee241f1a95401623aa582a091e30b950b493e
5
5
  SHA512:
6
- metadata.gz: 1ec8baadd85cfe44d3cf941be856d7beb3c16c83dedef76d9367d3ae0d9314b86ff8cb9fbfe3cebf2d15278d0c8ac5a1694839416bcebf716b9b37067fe163b7
7
- data.tar.gz: be7f8f3c0496916d4e9609d2838a6821da1d6b7659b10ec5f1f1ab81b58dccf697f61c1a16ffed4544fa07f13f638cba998ea557241b2b34261997f34214d071
6
+ metadata.gz: c758715ff7a60aefdcc78726eb234d3459725a37f17308dbfb45d1213bc82e4e242c56922ceca372b5fbab6f9eb5ae97402ed2615f4a048bfe1c8244948c794c
7
+ data.tar.gz: 8e5e3896b6e9e5fda4db96b60efa30ff2adeff6d4696ef6d3c4aec289b517e75ab66a0abf819cb42fa213796729e1cb003bcaf877a43ce036562aeaf95bc0926
@@ -27,7 +27,7 @@ module VagrantPlugins
27
27
  @options[:site] = site
28
28
  end
29
29
 
30
- opts.on("-r", "--revision [VERSION]", "Specifies the verion of the site to pulldown. Defaults to 3.0") do |revision|
30
+ opts.on("-r", "--revision [VERSION]", "Specifies the verion of the site to pulldown. Defaults to 3.1") do |revision|
31
31
  puts "revision: #{revision}"
32
32
  @options[:revision] = revision
33
33
  end
@@ -61,40 +61,32 @@ module VagrantPlugins
61
61
  end
62
62
 
63
63
  def commands
64
+ revision = @options[:revision] || '3.1'
64
65
  server = @options[:server]
65
- local = @options[:site]
66
- remote = @options[:site]
67
- folder = 'deploy'
68
- if @options[:revision]
69
- revision = @options[:revision]
70
- case revision
71
- when '3.0'
72
- folder = 'deploy'
73
- else
74
- folder = revision
75
- remote = "#{remote}.v#{revision.gsub('.', '')}"
76
- end
77
- end
66
+ site = "#{@options[:site]}.v#{revision.gsub('.', '')}"
67
+ folder = revision
68
+ files_dir = "/var/www/#{folder}/current/sites/#{site}/files/"
78
69
  commands = {
79
- "downloading files" => "sudo -E rsync --recursive --compress --times --rsh='ssh -l deploy' spt-#{server}.com:/var/www/#{folder}/current/sites/#{local}/files/ /var/www/deploy/current/sites/#{local}/files/",
80
- "setting file owner" => "sudo chown -R deploy:www-data /var/www/deploy/shared/#{local}/files/",
81
- "setting css file owner" => "sudo chown -R www-data:www-data /var/www/deploy/shared/#{local}/files/css",
82
- "setting file permissions" => "sudo chmod -R 2775 /var/www/deploy/shared/#{local}/files/",
83
- "dropping database" => "drush @#{local} sql-drop -y && drush cc drush",
84
- "downloading database" => "ssh -l deploy spt-#{server}.com drush @#{remote} sql-dump | drush @#{local} sql-cli",
85
- "updating database" => "drush @#{local} updb -y",
86
- "turning off css compressing" => "drush @#{local} vset preprocess_css 0 --yes",
87
- "turning off js compressing" => "drush @#{local} vset preprocess_js 0 --yes",
88
- "turning off block caching" => "drush @#{local} vset block_cache 0 --yes",
89
- "turning off page caching" => "drush @#{local} vset cache 0 --yes",
90
- "flushing block cache" => "drush @#{local} vset cache_content_flush_cache_block 0 --yes",
91
- "flushing page cache" => "drush @#{local} vset cache_content_flush_cache_page 0 --yes",
92
- "setting image permissions" => "drush @#{local} vset image_allow_insecure_derivatives 1 --yes",
93
- "turning on error reporting" => "drush @#{local} vset error_level 2 --yes",
94
- "turning on devel and theme_swapper" => "drush @#{local} en devel theme_swapper -y",
95
- "setting devel permissions" => "drush @#{local} php-eval '$permissions = array(\"access devel information\"); user_role_grant_permissions(4, $permissions);'",
96
- "disabling cdn and constant contact" => "drush @#{local} dis cdn spt_constant_contact -y",
97
- "clearing cache" => "drush @#{local} cc all",
70
+ "downloading files" => "sudo -E rsync --recursive --compress --times --rsh='ssh -l deploy' spt-#{server}.com:#{files_dir} #{files_dir}",
71
+ "setting file owner" => "sudo chown -R deploy:www-data #{files_dir}",
72
+ "setting css file owner" => "sudo chown -R www-data:www-data #{files_dir}css",
73
+ "setting cdn file owner" => "sudo chown -R www-data:www-data #{files_dir}cdn",
74
+ "setting file permissions" => "sudo chmod -R 2775 #{files_dir}",
75
+ "dropping database" => "drush @#{site} sql-drop -y && drush cc drush",
76
+ "downloading database" => "ssh -l deploy spt-#{server}.com drush @#{site} sql-dump | drush @#{site} sql-cli",
77
+ "updating database" => "drush @#{site} updb -y",
78
+ "turning off css compressing" => "drush @#{site} vset preprocess_css 0 --yes",
79
+ "turning off js compressing" => "drush @#{site} vset preprocess_js 0 --yes",
80
+ "turning off block caching" => "drush @#{site} vset block_cache 0 --yes",
81
+ "turning off page caching" => "drush @#{site} vset cache 0 --yes",
82
+ "flushing block cache" => "drush @#{site} vset cache_content_flush_cache_block 0 --yes",
83
+ "flushing page cache" => "drush @#{site} vset cache_content_flush_cache_page 0 --yes",
84
+ "setting image permissions" => "drush @#{site} vset image_allow_insecure_derivatives 1 --yes",
85
+ "turning on error reporting" => "drush @#{site} vset error_level 2 --yes",
86
+ "turning on devel and theme_swapper" => "drush @#{site} en devel theme_swapper -y",
87
+ "setting devel permissions" => "drush @#{site} php-eval '$permissions = array(\"access devel information\"); user_role_grant_permissions(4, $permissions);'",
88
+ "disabling cdn and constant contact" => "drush @#{site} dis cdn spt_constant_contact -y",
89
+ "clearing cache" => "drush @#{site} cc all",
98
90
  }
99
91
  commands
100
92
  end
@@ -1,5 +1,5 @@
1
1
  module VagrantPlugins
2
2
  module SPTSync
3
- VERSION = "0.0.53"
3
+ VERSION = "0.0.54"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vagrant-sptsync
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.53
4
+ version: 0.0.54
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sean Sehr
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-08-06 00:00:00.000000000 Z
11
+ date: 2014-10-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -80,3 +80,4 @@ signing_key:
80
80
  specification_version: 4
81
81
  summary: For syncing sites
82
82
  test_files: []
83
+ has_rdoc: