Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I was wondering if anyone knows of a way to deploy to Rackspace Cloud Sites via Git-push?

I contacted the Rackspace support and all they can tell me is that I might be able to as long as I don't need root access. Is that something that's possible?

I can't seem to find anything on Google, but I thought I would at least double check, as i'm only familiar with pushing to GitHub & Heroku.

share|improve this question
add comment

2 Answers 2

up vote 2 down vote accepted

Rackspace cloud sites doesn't allow git upload, only FTP upload is allowed.

share|improve this answer
1  
Correct. (SFTP is supported too) The other answers are confusing Cloud Sites and Cloud Servers. If you want to push via Git to a PaaS, you could try something like Appharbor. –  CoreyH May 2 '12 at 17:15
    
I looked into Appharbor and it seems to only do .net apps. Has anyone used www.deployhq.com ? That is the only deploy specific PaaS I can find on Google. Any others I should check out? –  SkinnyGeek1010 May 3 '12 at 22:22
    
You could make it part of your post-recieve hook in git to upload via SFTP then. Allowing you to "deploy via git push". I use this method for my blog. git-scm.com/book/ch7-3.html –  Joseph Kern May 9 '12 at 18:51
add comment

I am assuming you have git installed on your instance.

On the server create a repo for a server with "--bare"

[server:~/]$ mkdir app.git
[server:~/]$ cd app.git
[server:~/app.git]$ git init --bare

On the client clone, commit, and push:

[client:~/]$ git clone ssh://<username>@<servername>/~/app.git app
[client:~/]$ cd app
[client:~/app]$ touch readme.rst
[client:~/app]$ git add readme.rst
[client:~/app]$ git commit -am"Initial commit" 
[client:~/app]$ git push origin master

Now your code has been pushed to the server. What you can do from here is up to you.

Additional note: git is a distributed version control system, which means there is little difference between a "client" and a "server". In this case, there is no extra service running on your server, you only need ssh access, git does the rest.

share|improve this answer
    
Thank you for your comment. I have deleted my answer to remove the noise. –  VonC May 9 '12 at 20:11
    
That was unnecessary, it was a fine answer. –  Joseph Kern May 9 '12 at 20:44
1  
... a fine answer for a Cloud Server, not a Cloud Site as specified in the OP's question. –  VonC May 9 '12 at 21:28
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.