This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<VirtualHost *:80> | |
ServerName boyu | |
ServerAlias boyu | |
# Point this to your public folder of project | |
DocumentRoot /u/apps/boyu/current/public | |
ErrorDocument 503 /system/maintenance.html | |
RewriteEngine On |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Set the log level to ALL. | |
log :level => :all | |
rack "/u/apps/erp/current/config.ru" do | |
# Set the host and / or port that this rack application will | |
# be available on. This defaults to "0.0.0.0:9090" | |
listen 10000 | |
# Set the host names that this rack application wll be available | |
# on. This defaults to "*" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh -e | |
# kirk rails app | |
# | |
# start service for rails app | |
set -e | |
USER=rails | |
NAME=kirk | |
HOME=/home/$USER |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
配置外部访问帐号密码 | |
本地登录mysql | |
mysql -u root -p | |
执行 | |
grant all on *.* to rails@'client_ip' identified by 'password' with grant option; | |
例子:所有局域网客户端都可访问 | |
grant all on *.* to root@'192.168.0.%' identified by 'root' with grant option; | |
例子:为boyu数据库设置用户boyu |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
HOST=127.0.0.1 | |
USER=root | |
PASS=root | |
# DB="db1 db2 ..." | |
DB="erp" | |
DATE=$(date "+%Y-%m-%d") | |
BACKDIR=/home/rails/backup |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ref: http://nathanhoad.net/deploy-from-a-git-tag-with-capistrano | |
Deploy from a Git tag with Capistrano | |
Are you using Capistrano and Git and want to easily deploy from Git tags? It couldn't be simpler | |
Using Git, tag a new release: | |
git tag -a 09.10.02.01 -m "Tagging a release" | |
You can use git tag to list your tags: |
NewerOlder