Browse Source

config deploy

pull/1/head
Nicolae Claudius 13 years ago
parent
commit
6e34962367
  1. 1
      .gitignore
  2. 0
      config/database.mysql.sample.yml
  3. 10
      config/deploy.rb
  4. 9
      config/nginx.conf.sample
  5. 16
      config/nginx.sample.conf
  6. 8
      config/settings.sample.yml
  7. 8
      config/settings.yml
  8. 5
      doc/README_FOR_APP

1
.gitignore vendored

@ -9,4 +9,5 @@ config/database.yml
config/settings.local.yml
config/settings/*.local.yml
config/environments/*.local.yml
config/settings.yml
public/assets

0
config/database.yml.mysql.sample → config/database.mysql.sample.yml

10
config/deploy.rb

@ -21,7 +21,8 @@ role :app, domain # This may be the same as your `Web` server
role :db, domain, :primary => true # This is where Rails migrations will run
# role :db, "your slave db-server here"
after 'deploy:update_code', 'deploy:symlink_db'
after 'deploy:update_code', 'deploy:symlink_database_yml'
after 'deploy:update_code', 'deploy:symlink_settings_yml'
load 'deploy/assets'
@ -48,7 +49,12 @@ namespace :deploy do
end
desc "Symlinks the database.yml"
task :symlink_db, :roles => :app do
task :symlink_database_yml, :roles => :app do
run "ln -nfs #{deploy_to}/shared/config/database.yml #{release_path}/config/database.yml"
end
desc "Symlinks the settings.yml"
task :symlink_settings_yml, :roles => :app do
run "ln -nfs #{deploy_to}/shared/config/settings.yml #{release_path}/config/settings.yml"
end
end

9
config/nginx.conf.sample

@ -1,9 +0,0 @@
server {
listen 80;
server_name domain.com;
location / {
root /var/www/apps/entrydns/current/public;
passenger_enabled on;
}
}

16
config/nginx.sample.conf

@ -0,0 +1,16 @@
server {
listen 213.229.74.105:80;
server_name entrydns.net;
server_name www.entrydns.net;
# max body size
client_max_body_size 1m;
location / {
proxy_set_header X-Forwarded-Server $host;
proxy_set_header X-Forwarded-Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_pass http://127.0.0.1;
}
}

8
config/settings.sample.yml

@ -0,0 +1,8 @@
default_ttl: 3600
min_ttl: 60
ns:
- ns1.entrydns.net
- ns2.entrydns.net
# - ns3.entrydns.net
# - ns4.entrydns.net
default_prio: 10

8
config/settings.yml

@ -1,8 +0,0 @@
default_ttl: 2000
min_ttl: 1000
ns:
- ns1.ourdomain.com
- ns2.ourdomain.com
- ns3.ourdomain.com
- ns4.ourdomain.com
default_prio: 10

5
doc/README_FOR_APP

@ -1,2 +1,3 @@
Use this README file to introduce your application and point to useful places in the API for learning more.
Run "rake doc:app" to generate API documentation for your models, controllers, helpers, and libraries.
# Simple API
curl -H "Accept: application/json" -X PUT -d "" http://entrydns/records/modify/TOKEN

Loading…
Cancel
Save