bonethug 0.0.87 → 0.0.88
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/config/cnf-local.yml +222 -0
- data/config/cnf.yml +6 -6
- data/config/deploy.rb +1 -1
- data/lib/bonethug/cli.rb +9 -8
- data/lib/bonethug/installer.rb +9 -10
- data/lib/bonethug/version.rb +2 -2
- data/lib/tasks/bonethug.rake +2 -2
- data/skel/base/Gemfile +8 -4
- data/skel/base/README.md +68 -64
- data/skel/project_types/drupal/.gitignore +1 -0
- data/skel/project_types/drupal/composer.json +0 -2
- data/skel/project_types/drupal/public/sites/default/settings.php +1 -0
- data/skel/project_types/drupal6/.gitignore +1 -0
- data/skel/project_types/drupal6/composer.json +0 -2
- data/skel/project_types/drupal6/public/sites/default/settings.php +1 -0
- data/skel/project_types/drupal7/.gitignore +1 -0
- data/skel/project_types/drupal7/composer.json +0 -2
- data/skel/project_types/drupal7/public/sites/default/settings.php +1 -1
- data/skel/project_types/drupal8/.gitignore +1 -0
- data/skel/project_types/drupal8/composer.json +0 -2
- data/skel/project_types/drupal8/public/sites/default/settings.php +1 -0
- data/skel/project_types/php/.gitignore +6 -1
- data/skel/project_types/rails3/.gitignore +18 -0
- data/skel/project_types/rails4/.gitignore +18 -0
- data/skel/project_types/silverstripe3/.gitignore +1 -0
- data/skel/project_types/silverstripe3/composer.json +1 -1
- metadata +5 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4ce96dd65bf299a1277f640f466f97d9ef588dd8
|
4
|
+
data.tar.gz: f712f57099087df2a5637a1df0f007ec2c306585
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: be9bf43739da5189f46932119000256d890a77e6cf4ce8b06306fe9c731ec67077469732b42e584a4cecea9d7e590f07c6757f1e7143e7ffa36c4a2f933b454a
|
7
|
+
data.tar.gz: 95a6da3541929cbb055bd1966786ab76566f391db6d44af99798d3b53f7493b6a929aed27aa859a8de6e7199480de9be43f57a4d8c1969bb8cd74f6fdc54b9d9
|
@@ -0,0 +1,222 @@
|
|
1
|
+
deploy:
|
2
|
+
common:
|
3
|
+
project_type: rails3 | rails4 | silverstripe3 | drupal6 | drupal7 | drupal8 | php | sinatra
|
4
|
+
base_dir: /var/www
|
5
|
+
repository: git@gitlab.....
|
6
|
+
project_slug: tradespot
|
7
|
+
default_branch: master
|
8
|
+
domain: domain.com
|
9
|
+
user: root
|
10
|
+
port: 22
|
11
|
+
keep: 2
|
12
|
+
environments:
|
13
|
+
development:
|
14
|
+
os:
|
15
|
+
type: ubuntu
|
16
|
+
version: 14.04
|
17
|
+
staging:
|
18
|
+
os:
|
19
|
+
type: ubuntu
|
20
|
+
version: 12.04
|
21
|
+
domain: staging.domain.com
|
22
|
+
default_branch: master
|
23
|
+
production:
|
24
|
+
os:
|
25
|
+
type: ubuntu
|
26
|
+
version: 14.04
|
27
|
+
domain: production.domain.com
|
28
|
+
default_branch: stable
|
29
|
+
dbs:
|
30
|
+
default:
|
31
|
+
development:
|
32
|
+
name: project_development
|
33
|
+
user: project_development
|
34
|
+
pass:
|
35
|
+
host: localhost
|
36
|
+
port: 3306
|
37
|
+
staging:
|
38
|
+
name: project_staging
|
39
|
+
user: project_staging
|
40
|
+
pass: passw0rd
|
41
|
+
host: localhost
|
42
|
+
port: 3306
|
43
|
+
production:
|
44
|
+
name: project_production
|
45
|
+
user: project_production
|
46
|
+
pass: passw0rd
|
47
|
+
host: localhost
|
48
|
+
port: 3306
|
49
|
+
backup:
|
50
|
+
local:
|
51
|
+
keep:2
|
52
|
+
ftp:
|
53
|
+
keep: 10
|
54
|
+
host: backup-host.com
|
55
|
+
user: remote_backup
|
56
|
+
pass: passw0rd
|
57
|
+
sftp:
|
58
|
+
keep: 10
|
59
|
+
host: backup-host.com
|
60
|
+
user: remote_backup
|
61
|
+
pass: passw0rd
|
62
|
+
s3:
|
63
|
+
keep: 10
|
64
|
+
key: key
|
65
|
+
secret: secret
|
66
|
+
bucket: bucket
|
67
|
+
rsync:
|
68
|
+
host: backup-host.com
|
69
|
+
user: remote_backup
|
70
|
+
pass: passw0rd
|
71
|
+
mail:
|
72
|
+
smtp:
|
73
|
+
development:
|
74
|
+
default_from:
|
75
|
+
name: dev
|
76
|
+
email: dev@domain.com
|
77
|
+
server: smtp.gmail.com
|
78
|
+
domain: gmail.com
|
79
|
+
authenticate: true
|
80
|
+
user: username@domain.com
|
81
|
+
pass: passw0rd
|
82
|
+
secure: tls
|
83
|
+
charset_encoding: utf-8
|
84
|
+
port: 587
|
85
|
+
staging:
|
86
|
+
default_from:
|
87
|
+
name: staging
|
88
|
+
email: dev@domain.com
|
89
|
+
server: smtp.gmail.com
|
90
|
+
domain: gmail.com
|
91
|
+
authenticate: true
|
92
|
+
user: username@domain.com
|
93
|
+
pass: passw0rd
|
94
|
+
secure: tls
|
95
|
+
charset_encoding: utf-8
|
96
|
+
port: 587
|
97
|
+
production:
|
98
|
+
default_from:
|
99
|
+
name: production
|
100
|
+
email: dev@domain.com
|
101
|
+
server: smtp.gmail.com
|
102
|
+
domain: gmail.com
|
103
|
+
authenticate: true
|
104
|
+
user: username@domain.com
|
105
|
+
pass: passw0rd
|
106
|
+
secure: tls
|
107
|
+
charset_encoding: utf-8
|
108
|
+
port: 587
|
109
|
+
vhost:
|
110
|
+
development:
|
111
|
+
conf_path: /etc/apache2/sites-available
|
112
|
+
type: apache
|
113
|
+
version: 2.4
|
114
|
+
server_name: development.domain.local
|
115
|
+
server_aliases:
|
116
|
+
- www.development.domain.local
|
117
|
+
env_vars:
|
118
|
+
RAILS_ENV: development
|
119
|
+
APPLICATION_ENV: development
|
120
|
+
staging:
|
121
|
+
conf_path: /etc/apache2/sites-available
|
122
|
+
type: apache
|
123
|
+
version: 2.2
|
124
|
+
server_name: staging.domain.com
|
125
|
+
server_aliases:
|
126
|
+
- www.staging.domain.com
|
127
|
+
env_vars:
|
128
|
+
RAILS_ENV: staging
|
129
|
+
APPLICATION_ENV: staging
|
130
|
+
basic_auth:
|
131
|
+
-
|
132
|
+
user: username1
|
133
|
+
pass: passw0rd1
|
134
|
+
-
|
135
|
+
user: username2
|
136
|
+
pass: passw0rd2
|
137
|
+
production:
|
138
|
+
conf_path: /etc/apache2/sites-available
|
139
|
+
type: apache
|
140
|
+
version: 2.4
|
141
|
+
server_name: production.domain.com
|
142
|
+
server_aliases:
|
143
|
+
- www.production.domain.com
|
144
|
+
server_admin: dev@domain.com
|
145
|
+
env_vars:
|
146
|
+
RAILS_ENV: production
|
147
|
+
APPLICATION_ENV: production
|
148
|
+
chown:
|
149
|
+
development:
|
150
|
+
staging:
|
151
|
+
-
|
152
|
+
path: public/uploads
|
153
|
+
user: www-data
|
154
|
+
production:
|
155
|
+
-
|
156
|
+
path: public/uploads
|
157
|
+
user: www-data
|
158
|
+
chmod:
|
159
|
+
development:
|
160
|
+
staging:
|
161
|
+
-
|
162
|
+
path: public/uploads
|
163
|
+
mode: 775
|
164
|
+
production:
|
165
|
+
-
|
166
|
+
path: public/uploads
|
167
|
+
mode: 775
|
168
|
+
chgrp:
|
169
|
+
development:
|
170
|
+
staging:
|
171
|
+
-
|
172
|
+
path: public/uploads
|
173
|
+
group: www-data
|
174
|
+
production:
|
175
|
+
-
|
176
|
+
path: public/uploads
|
177
|
+
group: www-data
|
178
|
+
resources:
|
179
|
+
- public/assets
|
180
|
+
- public/uploads
|
181
|
+
vendor:
|
182
|
+
- vendor
|
183
|
+
- public/thirdparty
|
184
|
+
- public/vendor
|
185
|
+
post_cmds:
|
186
|
+
development:
|
187
|
+
- touch public/random_file
|
188
|
+
- rm public/random_file
|
189
|
+
staging:
|
190
|
+
- touch public/random_file
|
191
|
+
- rm public/random_file
|
192
|
+
production:
|
193
|
+
- touch public/random_file
|
194
|
+
- rm public/random_file
|
195
|
+
watch:
|
196
|
+
sass:
|
197
|
+
-
|
198
|
+
src: public/themes/project/scss
|
199
|
+
dest: public/themes/project/css
|
200
|
+
filter: !ruby/regexp '/main\.scss$/'
|
201
|
+
-
|
202
|
+
src: public/themes/project/scss
|
203
|
+
dest: public/themes/project/css
|
204
|
+
filter: !ruby/regexp '/typography\.scss$/'
|
205
|
+
coffee:
|
206
|
+
-
|
207
|
+
src: public/project/coffee
|
208
|
+
dest: public/project/javascript
|
209
|
+
filter: !ruby/regexp '/^.+\.coffee$/'
|
210
|
+
concat_js:
|
211
|
+
-
|
212
|
+
onstart: true
|
213
|
+
src: public/project/vendor
|
214
|
+
dest: public/project/javascript
|
215
|
+
filter: "*"
|
216
|
+
uglify:
|
217
|
+
-
|
218
|
+
src: public/project/javascript
|
219
|
+
dest: public/project/javascript
|
220
|
+
filter: !ruby/regexp '/^.+(?<!min)\.js$/'
|
221
|
+
log_dirs:
|
222
|
+
- log
|
data/config/cnf.yml
CHANGED
@@ -13,17 +13,17 @@ deploy:
|
|
13
13
|
development:
|
14
14
|
os:
|
15
15
|
type: ubuntu
|
16
|
-
version: 14.04
|
16
|
+
version: 14.04
|
17
17
|
staging:
|
18
18
|
os:
|
19
19
|
type: ubuntu
|
20
|
-
version: 12.04
|
20
|
+
version: 12.04
|
21
21
|
domain: staging.domain.com
|
22
22
|
default_branch: master
|
23
23
|
production:
|
24
24
|
os:
|
25
25
|
type: ubuntu
|
26
|
-
version: 14.04
|
26
|
+
version: 14.04
|
27
27
|
domain: production.domain.com
|
28
28
|
default_branch: stable
|
29
29
|
dbs:
|
@@ -118,7 +118,7 @@ vhost:
|
|
118
118
|
RAILS_ENV: development
|
119
119
|
APPLICATION_ENV: development
|
120
120
|
staging:
|
121
|
-
conf_path: /etc/apache2/sites-available
|
121
|
+
conf_path: /etc/apache2/sites-available
|
122
122
|
type: apache
|
123
123
|
version: 2.2
|
124
124
|
server_name: staging.domain.com
|
@@ -135,7 +135,7 @@ vhost:
|
|
135
135
|
user: username2
|
136
136
|
pass: passw0rd2
|
137
137
|
production:
|
138
|
-
conf_path: /etc/apache2/sites-available
|
138
|
+
conf_path: /etc/apache2/sites-available
|
139
139
|
type: apache
|
140
140
|
version: 2.4
|
141
141
|
server_name: production.domain.com
|
@@ -180,7 +180,7 @@ resources:
|
|
180
180
|
- public/uploads
|
181
181
|
vendor:
|
182
182
|
- vendor
|
183
|
-
- public/thirdparty
|
183
|
+
- public/thirdparty
|
184
184
|
- public/vendor
|
185
185
|
post_cmds:
|
186
186
|
development:
|
data/config/deploy.rb
CHANGED
@@ -170,7 +170,7 @@ task :init_db => :environment do
|
|
170
170
|
dbs.each do |name,envs|
|
171
171
|
if envs
|
172
172
|
db = envs.get env
|
173
|
-
cmd = Bonethug::Installer.init_mysql_db_script db,
|
173
|
+
cmd = Bonethug::Installer.init_mysql_db_script db, ENV['admin_user'], ENV['admin_pass']
|
174
174
|
queue! %[#{cmd}]
|
175
175
|
end
|
176
176
|
end
|
data/lib/bonethug/cli.rb
CHANGED
@@ -93,19 +93,20 @@ module Bonethug
|
|
93
93
|
# handle args
|
94
94
|
env = ARGV.last
|
95
95
|
admin_user = ARGV.length == 3 ? ARGV[1] : 'root'
|
96
|
+
admin_pass = ARGV.length == 4 ? ARGV[2] : ''
|
96
97
|
|
97
98
|
# validate
|
98
99
|
if !env || env == task
|
99
|
-
puts 'Usage: ' + bin_name + ' ' + task + ' [admin_user] [environment]'
|
100
|
+
puts 'Usage: ' + bin_name + ' ' + task + ' [admin_user] [admin_pass] [environment]'
|
100
101
|
return
|
101
102
|
end
|
102
103
|
|
103
104
|
if task == 'init-local-db'
|
104
|
-
Installer.execute_init_mysql_db_script env, admin_user
|
105
|
+
Installer.execute_init_mysql_db_script env, admin_user, admin_pass
|
105
106
|
elsif task == 'setup-db'
|
106
|
-
exec "export to=#{env} && export admin_user=#{admin_user} && bundle exec mina -f .bonethug/deploy.rb setup_db --verbose"
|
107
|
+
exec "export to=#{env} && export admin_user=#{admin_user} && export admin_pass=#{admin_pass} && bundle exec mina -f .bonethug/deploy.rb setup_db --verbose"
|
107
108
|
else
|
108
|
-
exec "export to=#{env} && export admin_user=#{admin_user} && bundle exec mina -f .bonethug/deploy.rb init_db --verbose"
|
109
|
+
exec "export to=#{env} && export admin_user=#{admin_user} && export admin_pass=#{admin_pass} && bundle exec mina -f .bonethug/deploy.rb init_db --verbose"
|
109
110
|
end
|
110
111
|
|
111
112
|
when 'setup-env'
|
@@ -188,7 +189,7 @@ module Bonethug
|
|
188
189
|
else # apache
|
189
190
|
|
190
191
|
# install the vhost
|
191
|
-
system "echo \"#{vh}\" > #{conf_path}/#{vhost}.conf"
|
192
|
+
system "sudo echo \"#{vh}\" > #{conf_path}/#{vhost}.conf"
|
192
193
|
|
193
194
|
end
|
194
195
|
|
@@ -202,12 +203,12 @@ module Bonethug
|
|
202
203
|
|
203
204
|
# write the to the hosts file
|
204
205
|
# this needs work
|
205
|
-
system "sed -i '/## BONETHUG-#{vhost} ##/,/## END_BONETHUG-#{vhost} ##/ s/.*//g' #{path}"
|
206
|
+
system "sudo sed -i '/## BONETHUG-#{vhost} ##/,/## END_BONETHUG-#{vhost} ##/ s/.*//g' #{path}"
|
206
207
|
escaped = (hosts).gsub(/"/, '\"')
|
207
|
-
system "echo \"#{escaped}\" >> #{path}"
|
208
|
+
system "sudo echo \"#{escaped}\" >> #{path}"
|
208
209
|
|
209
210
|
# reload apache - linux - but need a debian specific look up
|
210
|
-
system "a2ensite #{vhost} && service apache2 restart" if RbConfig::CONFIG['target_os'] =~ /linux/i
|
211
|
+
system "sudo a2ensite #{vhost} && sudo service apache2 restart" if RbConfig::CONFIG['target_os'] =~ /linux/i
|
211
212
|
|
212
213
|
when 'init', 'update'
|
213
214
|
|
data/lib/bonethug/installer.rb
CHANGED
@@ -133,20 +133,18 @@ module Bonethug
|
|
133
133
|
# Prepares init db scripts
|
134
134
|
# --------------------------
|
135
135
|
|
136
|
-
def self.init_mysql_db_script(db,
|
136
|
+
def self.init_mysql_db_script(db, admin_user = 'root', admin_pass = '')
|
137
137
|
|
138
138
|
script_content = "
|
139
139
|
CREATE DATABASE IF NOT EXISTS " + db.get('name') + ";
|
140
|
-
GRANT ALL ON " + db.get('name') + ".* TO " + db.get('user') + "@" + db.get('host') + (db.get('pass') ? " IDENTIFIED BY '" + db.get('pass') + "'" : "") + ";
|
140
|
+
GRANT ALL ON " + db.get('name') + ".* TO " + db.get('user') + "@" + db.get('host') + (db.get('pass') ? " IDENTIFIED BY '" + db.get('pass') + "'" : "") + ";
|
141
141
|
FLUSH PRIVILEGES;
|
142
142
|
"
|
143
|
-
cmd = '
|
144
|
-
'echo "' + script_content + '" > .bonethug/sql.txt && ' +
|
145
|
-
'mysql -h ' + db.get('host') + ' -u ' + admin_user + ' -p < .bonethug/sql.txt'
|
143
|
+
cmd = 'echo "' + script_content + '" | mysql -h ' + db.get('host') + ' -u ' + admin_user + ' -p' + admin_pass
|
146
144
|
|
147
145
|
end
|
148
146
|
|
149
|
-
def self.execute_init_mysql_db_script(env, admin_user = 'root', path = '.')
|
147
|
+
def self.execute_init_mysql_db_script(env, admin_user = 'root', admin_pass = '', path = '.')
|
150
148
|
|
151
149
|
exec_path = File.expand_path(path)
|
152
150
|
conf = Bonethug::Conf.new.add(exec_path + '/config/cnf.yml')
|
@@ -159,8 +157,9 @@ module Bonethug
|
|
159
157
|
puts "No db for env " + env + " found - check your config file"
|
160
158
|
exit
|
161
159
|
else
|
162
|
-
puts "Mysql user " + admin_user + " is creating db: " + db.get('name') + " and granting access to " + db.get('user') + "@" + db.get('host') + ", you may be
|
163
|
-
|
160
|
+
puts "Mysql user " + admin_user + " is creating db: " + db.get('name') + " and granting access to " + db.get('user') + "@" + db.get('host') + ", you may be prompted for the password for the user: " + admin_user
|
161
|
+
puts "NB: You may be affected by this bug if your admin user pass is longer than 8 chars: http://dev.mysql.com/doc/refman/5.0/en/password-too-long.html"
|
162
|
+
system Bonethug::Installer.init_mysql_db_script(db, admin_user, admin_pass)
|
164
163
|
end
|
165
164
|
|
166
165
|
end
|
@@ -397,8 +396,8 @@ module Bonethug
|
|
397
396
|
end
|
398
397
|
|
399
398
|
# run bundler
|
400
|
-
exec 'bundle install
|
401
|
-
|
399
|
+
exec 'bundle install'
|
400
|
+
|
402
401
|
end
|
403
402
|
|
404
403
|
# self
|
data/lib/bonethug/version.rb
CHANGED
data/lib/tasks/bonethug.rake
CHANGED
@@ -20,7 +20,7 @@ namespace :thug do
|
|
20
20
|
ver_path = File.expand_path File.dirname(__FILE__) + '/../bonethug/version.rb'
|
21
21
|
|
22
22
|
# write data
|
23
|
-
File.open(ver_path,'w') do |file|
|
23
|
+
File.open(ver_path,'w') do |file|
|
24
24
|
file.puts content
|
25
25
|
end
|
26
26
|
|
@@ -36,7 +36,7 @@ namespace :thug do
|
|
36
36
|
|
37
37
|
puts "now " + Bonethug::VERSION
|
38
38
|
|
39
|
-
end
|
39
|
+
end
|
40
40
|
|
41
41
|
desc "Runs rake build + some other stuff"
|
42
42
|
task :build do
|
data/skel/base/Gemfile
CHANGED
@@ -1,6 +1,10 @@
|
|
1
1
|
source "https://rubygems.org"
|
2
2
|
|
3
|
-
gem '
|
4
|
-
gem
|
5
|
-
gem
|
6
|
-
gem
|
3
|
+
gem 'bonethug', '>=0.0.87'
|
4
|
+
gem "mina", github: "nadarei/mina"
|
5
|
+
gem "astrails-safe", github: "astrails/safe"
|
6
|
+
gem "whenever", github: "javan/whenever"
|
7
|
+
gem "guard-erb", github: "azt3k/guard-erb"
|
8
|
+
gem "coffee-script", github: "josh/ruby-coffee-script"
|
9
|
+
gem "guard-uglify", github: "customink/guard-uglify"
|
10
|
+
gem "guard-concat", github: "mikz/guard-concat"
|
data/skel/base/README.md
CHANGED
@@ -1,115 +1,119 @@
|
|
1
1
|
Bonethug Project Skeleton
|
2
2
|
=========================
|
3
3
|
|
4
|
-
|
5
|
-
|
6
|
-
Requirements
|
7
|
-
------------
|
8
|
-
|
9
|
-
- Ruby 1.9.3 +
|
10
|
-
|
11
|
-
- PHP 5.3 + (if using a php based project skeleton)
|
12
|
-
|
13
|
-
- Linux / OSX
|
14
|
-
|
15
|
-
- Apache
|
16
|
-
|
17
|
-
- MySQL 5.5 +
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
Overview
|
22
|
-
--------
|
23
|
-
|
24
|
-
- Deployment handled with mina. see [https://github.com/nadarei/mina]
|
25
|
-
|
26
|
-
- Cron handled wtih whenever. [https://github.com/javan/whenever]
|
27
|
-
|
28
|
-
- Backups handled with astrails-safe. [see https://github.com/astrails/safe]
|
29
|
-
|
30
|
-
- Ruby dependency management handled with bundler. see
|
31
|
-
|
32
|
-
- Built on the Silverstripe framework, CMS and Installer - 3.1.x dev branch.
|
33
|
-
|
34
|
-
- PHP dpendency management handled with composer. see [https://packagist.org/]
|
35
|
-
|
36
|
-
|
37
|
-
|
38
4
|
Set Up
|
39
5
|
------
|
40
6
|
|
7
|
+
## Windows
|
41
8
|
|
9
|
+
If you are windows you'll need some better unix command support this helps:
|
10
|
+
`http://git-scm.com/downloads`
|
11
|
+
`http://www.robvanderwoude.com/unixports.php`
|
42
12
|
|
43
|
-
###
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
1. If you are windows you'll need some better unix command support. Make usre
|
48
|
-
you install git for windows and this also helps:
|
49
|
-
http://www.robvanderwoude.com/unixports.php
|
50
|
-
|
51
|
-
2. Firstly you need an MAMP / LAMP / WAMP etc stack, ruby 1.9.3 and curl for
|
52
|
-
composer, if you're on windows there's an installer for composer
|
13
|
+
### Apache, MySQL, PHP
|
53
14
|
|
54
|
-
|
15
|
+
`http://www.wampserver.com/en/`
|
55
16
|
|
17
|
+
### Ruby
|
56
18
|
|
19
|
+
`http://rubyinstaller.org`
|
20
|
+
`https://github.com/vertiginous/pik`
|
57
21
|
|
58
|
-
|
22
|
+
### NodeJS / NPM
|
59
23
|
|
60
|
-
`
|
24
|
+
`http://nodejs.org/download/`
|
61
25
|
|
26
|
+
### Bundler
|
62
27
|
|
28
|
+
````bash
|
29
|
+
gem install bundler
|
30
|
+
````
|
63
31
|
|
64
|
-
|
32
|
+
### Bower
|
65
33
|
|
66
|
-
|
34
|
+
````bash
|
35
|
+
npm install bower -g
|
36
|
+
````
|
67
37
|
|
68
38
|
|
69
39
|
|
70
|
-
|
40
|
+
## OSX (10.9)
|
71
41
|
|
42
|
+
### Apache, MySQL, PHP
|
72
43
|
|
44
|
+
`http://coolestguidesontheplanet.com/set-amp-osx-10-9-mavericks-homebrew/`
|
73
45
|
|
74
|
-
|
46
|
+
### Ruby
|
75
47
|
|
76
|
-
|
48
|
+
`https://github.com/sstephenson/rbenv`
|
77
49
|
|
78
|
-
|
50
|
+
### Composer
|
79
51
|
|
80
|
-
`
|
52
|
+
`https://getcomposer.org/doc/00-intro.md#installation-nix`
|
81
53
|
|
82
|
-
|
54
|
+
### NPM
|
83
55
|
|
56
|
+
`http://howtonode.org/introduction-to-npm`
|
84
57
|
|
58
|
+
### Bundler
|
85
59
|
|
86
|
-
|
60
|
+
````bash
|
61
|
+
gem install bundler
|
62
|
+
````
|
87
63
|
|
64
|
+
### Bower
|
88
65
|
|
66
|
+
````bash
|
67
|
+
npm install bower -g
|
68
|
+
````
|
89
69
|
|
90
|
-
This only works on \*nix based OSes
|
91
70
|
|
92
71
|
|
72
|
+
## Linux
|
93
73
|
|
94
|
-
|
74
|
+
`https://github.com/azt3k/bonethug/blob/master/scripts/ubuntu-14.04-dev`
|
95
75
|
|
96
|
-
`bundle exec bonethug setup {staging|production}`
|
97
76
|
|
98
77
|
|
99
78
|
|
100
|
-
|
79
|
+
Getting a working copy up and running
|
80
|
+
-------------------------------------
|
101
81
|
|
102
|
-
|
82
|
+
````bash
|
83
|
+
# clone the repo
|
84
|
+
git clone git@git.domain.com:namespace/project-name.git project-name
|
85
|
+
cd project-name
|
103
86
|
|
87
|
+
# install depenedencies
|
88
|
+
bundle install
|
89
|
+
composer install
|
90
|
+
bower install
|
104
91
|
|
92
|
+
# init db
|
93
|
+
bundle exec thug init-local-db development
|
105
94
|
|
106
|
-
|
95
|
+
# set up a vhost (Ubuntu only currently)
|
96
|
+
bundle exec thug vhost-local development
|
107
97
|
|
108
|
-
|
109
|
-
|
98
|
+
# pull assets / db down
|
99
|
+
bundle exec thug sync-state pull-from-remote production push-to-local development
|
110
100
|
|
101
|
+
# watch sass / coffee script
|
102
|
+
bundle exec thug watch
|
103
|
+
````
|
111
104
|
|
105
|
+
Deployment
|
106
|
+
----------
|
112
107
|
|
108
|
+
````bash
|
109
|
+
# only do this if its a fresh deploy target
|
110
|
+
bundle exec thug setup staging
|
113
111
|
|
112
|
+
# deploy
|
113
|
+
bundle exec thug deploy staging
|
114
|
+
````
|
114
115
|
|
116
|
+
More Info
|
117
|
+
---------
|
115
118
|
|
119
|
+
https://github.com/azt3k/bonethug
|
@@ -349,11 +349,9 @@
|
|
349
349
|
},
|
350
350
|
"scripts": {
|
351
351
|
"post-update-cmd": [
|
352
|
-
"cp -rp vendor/drupal/drupal/. public/",
|
353
352
|
"rm -rf public/.gitignore"
|
354
353
|
],
|
355
354
|
"post-install-cmd": [
|
356
|
-
"cp -rp vendor/drupal/drupal/. public/",
|
357
355
|
"rm -rf public/.gitignore"
|
358
356
|
]
|
359
357
|
}
|
@@ -12,6 +12,7 @@ if (!defined('APPLICATION_ENV')) define('APPLICATION_ENV', getenv('APPLICATION_E
|
|
12
12
|
// prep some data
|
13
13
|
$db_cnf = Yaml::parse(file_get_contents(__DIR__.'/../../../config/cnf.yml'));
|
14
14
|
$db = (object) $db_cnf['dbs']['default'][APPLICATION_ENV];
|
15
|
+
$apache = empty($cnf['apache']) ? $cnf['vhost'][APPLICATION_ENV] : $cnf['apache'][APPLICATION_ENV];
|
15
16
|
|
16
17
|
// what conf are we using
|
17
18
|
require APPLICATION_ENV . '.settings.php';
|
@@ -349,11 +349,9 @@
|
|
349
349
|
},
|
350
350
|
"scripts": {
|
351
351
|
"post-update-cmd": [
|
352
|
-
"cp -rp vendor/drupal/drupal/. public/",
|
353
352
|
"rm -rf public/.gitignore"
|
354
353
|
],
|
355
354
|
"post-install-cmd": [
|
356
|
-
"cp -rp vendor/drupal/drupal/. public/",
|
357
355
|
"rm -rf public/.gitignore"
|
358
356
|
]
|
359
357
|
}
|
@@ -12,6 +12,7 @@ if (!defined('APPLICATION_ENV')) define('APPLICATION_ENV', getenv('APPLICATION_E
|
|
12
12
|
// prep some data
|
13
13
|
$db_cnf = Yaml::parse(file_get_contents(__DIR__.'/../../../config/cnf.yml'));
|
14
14
|
$db = (object) $db_cnf['dbs']['default'][APPLICATION_ENV];
|
15
|
+
$apache = empty($cnf['apache']) ? $cnf['vhost'][APPLICATION_ENV] : $cnf['apache'][APPLICATION_ENV];
|
15
16
|
|
16
17
|
// what conf are we using
|
17
18
|
require APPLICATION_ENV . '.settings.php';
|
@@ -349,11 +349,9 @@
|
|
349
349
|
},
|
350
350
|
"scripts": {
|
351
351
|
"post-update-cmd": [
|
352
|
-
"cp -rp vendor/drupal/drupal/. public/",
|
353
352
|
"rm -rf public/.gitignore"
|
354
353
|
],
|
355
354
|
"post-install-cmd": [
|
356
|
-
"cp -rp vendor/drupal/drupal/. public/",
|
357
355
|
"rm -rf public/.gitignore"
|
358
356
|
]
|
359
357
|
}
|
@@ -12,7 +12,7 @@ if (!defined('APPLICATION_ENV')) define('APPLICATION_ENV', getenv('APPLICATION_E
|
|
12
12
|
// prep some data
|
13
13
|
$cnf = Yaml::parse(file_get_contents(__DIR__.'/../../../config/cnf.yml'));
|
14
14
|
$db = (object) $cnf['dbs']['default'][APPLICATION_ENV];
|
15
|
-
$apache = $cnf['apache'][APPLICATION_ENV];
|
15
|
+
$apache = empty($cnf['apache']) ? $cnf['vhost'][APPLICATION_ENV] : $cnf['apache'][APPLICATION_ENV];
|
16
16
|
|
17
17
|
// what conf are we using
|
18
18
|
require APPLICATION_ENV . '.settings.php';
|
@@ -349,11 +349,9 @@
|
|
349
349
|
},
|
350
350
|
"scripts": {
|
351
351
|
"post-update-cmd": [
|
352
|
-
"cp -rp vendor/drupal/drupal/. public/",
|
353
352
|
"rm -rf public/.gitignore"
|
354
353
|
],
|
355
354
|
"post-install-cmd": [
|
356
|
-
"cp -rp vendor/drupal/drupal/. public/",
|
357
355
|
"rm -rf public/.gitignore"
|
358
356
|
]
|
359
357
|
}
|
@@ -12,6 +12,7 @@ if (!defined('APPLICATION_ENV')) define('APPLICATION_ENV', getenv('APPLICATION_E
|
|
12
12
|
// prep some data
|
13
13
|
$db_cnf = Yaml::parse(file_get_contents(__DIR__.'/../../../config/cnf.yml'));
|
14
14
|
$db = (object) $db_cnf['dbs']['default'][APPLICATION_ENV];
|
15
|
+
$apache = empty($cnf['apache']) ? $cnf['vhost'][APPLICATION_ENV] : $cnf['apache'][APPLICATION_ENV];
|
15
16
|
|
16
17
|
// what conf are we using
|
17
18
|
require APPLICATION_ENV . '.settings.php';
|
@@ -7,6 +7,7 @@
|
|
7
7
|
/db_dumps
|
8
8
|
/tmp/*
|
9
9
|
/composer.phar
|
10
|
+
/config/cnf-local.yml
|
10
11
|
|
11
12
|
# components tracked by composer
|
12
13
|
/public/assets/*
|
@@ -14,4 +15,8 @@
|
|
14
15
|
|
15
16
|
# project files
|
16
17
|
*.sublime-workspace
|
17
|
-
*.sublime-project
|
18
|
+
*.sublime-project
|
19
|
+
|
20
|
+
# files to keep
|
21
|
+
!.gitkeep
|
22
|
+
!.keep
|
@@ -0,0 +1,18 @@
|
|
1
|
+
# project framework
|
2
|
+
/.bundle
|
3
|
+
/vendor
|
4
|
+
/log/*
|
5
|
+
/backups/*
|
6
|
+
/db_dumps
|
7
|
+
/tmp/*
|
8
|
+
.sass-cache
|
9
|
+
/vendor/ruby
|
10
|
+
/config/cnf-local.yml
|
11
|
+
|
12
|
+
# project files
|
13
|
+
*.sublime-workspace
|
14
|
+
*.sublime-project
|
15
|
+
|
16
|
+
# files to keep
|
17
|
+
!.gitkeep
|
18
|
+
!.keep
|
@@ -0,0 +1,18 @@
|
|
1
|
+
# project framework
|
2
|
+
/.bundle
|
3
|
+
/vendor
|
4
|
+
/log/*
|
5
|
+
/backups/*
|
6
|
+
/db_dumps
|
7
|
+
/tmp/*
|
8
|
+
.sass-cache
|
9
|
+
/vendor/ruby
|
10
|
+
/config/cnf-local.yml
|
11
|
+
|
12
|
+
# project files
|
13
|
+
*.sublime-workspace
|
14
|
+
*.sublime-project
|
15
|
+
|
16
|
+
# files to keep
|
17
|
+
!.gitkeep
|
18
|
+
!.keep
|
@@ -8,7 +8,7 @@
|
|
8
8
|
"phpmailer/phpmailer" : "dev-master",
|
9
9
|
"silverstripe/bootstrap-forms" : "dev-master",
|
10
10
|
"undefinedoffset/sortablegridfield" : "dev-master",
|
11
|
-
"unclecheese/betterbuttons" : "dev-master",
|
11
|
+
"unclecheese/betterbuttons" : "dev-master",
|
12
12
|
"azt3k/abc-silverstripe" : "dev-master",
|
13
13
|
"azt3k/abc-silverstripe-mailer" : "dev-master",
|
14
14
|
"nathancox/minify" : "dev-master",
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bonethug
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.88
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- azt3k
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-08-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -324,6 +324,7 @@ files:
|
|
324
324
|
- bin/thug
|
325
325
|
- bonethug.gemspec
|
326
326
|
- config/backup.rb
|
327
|
+
- config/cnf-local.yml
|
327
328
|
- config/cnf.yml
|
328
329
|
- config/deploy.rb
|
329
330
|
- config/schedule.rb
|
@@ -405,8 +406,10 @@ files:
|
|
405
406
|
- skel/project_types/php/bower.json
|
406
407
|
- skel/project_types/php/composer.json
|
407
408
|
- skel/project_types/php/lib/Thug/Conf/Load.php
|
409
|
+
- skel/project_types/rails3/.gitignore
|
408
410
|
- skel/project_types/rails3/Gemfile
|
409
411
|
- skel/project_types/rails3/README.md
|
412
|
+
- skel/project_types/rails4/.gitignore
|
410
413
|
- skel/project_types/rails4/Gemfile
|
411
414
|
- skel/project_types/rails4/README.md
|
412
415
|
- skel/project_types/rails4/app/assets/fonts/.keep
|