# SwitchTower rake deply failure on DreamHost

**URL:** <https://www.ruby-forum.com/t/switchtower-rake-deply-failure-on-dreamhost/74582>\
**Category:** Rails\
**Created:** [February 28, 2006, 7:46am UTC](https://www.ruby-forum.com/t/switchtower-rake-deply-failure-on-dreamhost/74582 "2006-02-28T07:46:47Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![i8ramin](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/e36b37/32.png) [@i8ramin](https://www.ruby-forum.com/u/i8ramin)\
**Post date:** [February 28, 2006, 7:46am UTC](https://www.ruby-forum.com/t/switchtower-rake-deply-failure-on-dreamhost/74582/1 "2006-02-28T07:46:47Z")

</div>

## I’ve been following some tutorials on how to get switchtower working on dreamhost. I got the setup to work just fine, but the rake deploy doesn’t work. I get the following error. any ideas?

> rake deploy  
> (in /home/.interim/i8ramin/work/yaram.com)  
> loading configuration  
> /home/i8ramin/.gems/gems/switchtower-1.0.1/lib/switchtower/recipes/standard.rb  
> loading configuration ./config/deploy.rb

- executing task deploy  
\*\* transaction: start

- executing task update\_code

- querying latest revision…

- executing “if [[ ! -d  
/home/i8ramin/domains/yaram.com/releases/20060228064451 ]]; then\n  
svn co -q -r5 [http://repo.yaram.com/svn/trunk](http://repo.yaram.com/svn/trunk)  
/home/i8ramin/domains/yaram.com/releases/20060228064451 &&\n  
(test -e /home/i8ramin/domains/yaram.com/revisions.log || touch  
/home/i8ramin/domains/yaram.com/revisions.log && chmod 666  
/home/i8ramin/domains/yaram.com/revisions.log) && echo `date +\"%Y-%m-%d %H:%M:%S\"` $USER 5 20060228064451 \>\>  
/home/i8ramin/domains/yaram.com/revisions.log;\n fi”  
servers: [“[yaram.com](http://yaram.com)”]  
Password: \*\*\*\*\*\*\*\*\*\*

- [update\_code] rolling back

- executing “rm -rf  
/home/i8ramin/domains/yaram.com/releases/20060228064451”  
servers: [“[yaram.com](http://yaram.com)”]  
[[yaram.com](http://yaram.com)] executing command  
command finished  
rake aborted!  
command “if [[ ! -d  
/home/i8ramin/domains/yaram.com/releases/20060228064451 ]]; then\\n  
svn co -q -r5 [http://repo.yaram.com/svn/trunk](http://repo.yaram.com/svn/trunk)  
/home/i8ramin/domains/yaram.com/releases/20060228064451 &&\\n  
(test -e /home/i8ramin/domains/yaram.com/revisions.log || touch  
/home/i8ramin/domains/yaram.com/revisions.log && chmod 666  
/home/i8ramin/domains/yaram.com/revisions.log) && echo `date +\"%Y-%m-%d %H:%M:%S\"` $USER 5 20060228064451 \>\>  
/home/i8ramin/domains/yaram.com/revisions.log;\\n fi” failed  
on [yaram.com](http://yaram.com)

Exit 1

---

<div class="post-metadata">

**Author:** ![i8ramin](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/e36b37/32.png) [@i8ramin](https://www.ruby-forum.com/u/i8ramin)\
**Post date:** [February 28, 2006, 4:45pm UTC](https://www.ruby-forum.com/t/switchtower-rake-deply-failure-on-dreamhost/74582/2 "2006-02-28T16:45:31Z")

</div>

Ramin,

I already replied to you directly, but I figured I’d post the answer  
here as well in case anyone else is running up against this.

The symptom of the issue is the following bit in the output:

\*\* [out :: [yaram.com](http://yaram.com)] if: Expression Syntax.

This is your shell rejecting the “if” syntax that SwitchTower is  
using, and it means that you are not using a POSIX compatible shell  
on your remote host(s). Probably you have something like csh or tcsh  
configured right now. In order to use ST, you’ll need to change your  
remote host to use something like bash, ksh, or zsh–basically any  
shell that understands POSIX shell syntax.

Hope that helps,

Jamis

---

<div class="post-metadata">

**Author:** ![i8ramin](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/e36b37/32.png) [@i8ramin](https://www.ruby-forum.com/u/i8ramin)\
**Post date:** [February 28, 2006, 4:52pm UTC](https://www.ruby-forum.com/t/switchtower-rake-deply-failure-on-dreamhost/74582/3 "2006-02-28T16:52:01Z")

</div>

Jamis B. wrote:

> Ramin,
> 
> I already replied to you directly, but I figured I’d post the answer  
> here as well in case anyone else is running up against this.
> 
> The symptom of the issue is the following bit in the output:
> 
> \*\* [out :: [yaram.com](http://yaram.com)] if: Expression Syntax.
> 
> This is your shell rejecting the “if” syntax that SwitchTower is  
> using, and it means that you are not using a POSIX compatible shell  
> on your remote host(s). Probably you have something like csh or tcsh  
> configured right now. In order to use ST, you’ll need to change your  
> remote host to use something like bash, ksh, or zsh–basically any  
> shell that understands POSIX shell syntax.
> 
> Hope that helps,
> 
> Jamis

I actually was using tcsh. I will switch to bash now and try again.  
Thank you so much for your assistance.
