"Is it possible to pull a local repo to a remote machine?" Not directly.
You could check out locally and use the synchronize module instead. On Tue, Jul 15, 2014 at 11:10 AM, mvermaes <[email protected]> wrote: > The docs for the module don't specifically mention local repos, but I > can't see anything that would prevent it and it worked for me. I think you > just need to remove the trailing .git in the repo specification. Try: > > - name: pull the code > git: repo=file:///home/username/myproject/ dest=/var/www > > > On Tuesday, July 15, 2014 6:14:23 PM UTC+8, [email protected] wrote: >> >> I do not have remote git repo, only a local one. Is it possible to pull a >> local repo to a remote machine? >> >> I tried the following: >> >> - name: pull the code >> git: repo=file:///home/username/myproject/.git dest=/var/www >> >> and got an error: >> >> stderr: fatal: '/home/username/myproject/.git' does not appear to be a >> git repository >> fatal: Could not read from remote repository. >> >> >> >> >> >> -- > You received this message because you are subscribed to the Google Groups > "Ansible Project" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To post to this group, send email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/ansible-project/68471377-4f6d-4df9-91f2-f88d2824da48%40googlegroups.com > <https://groups.google.com/d/msgid/ansible-project/68471377-4f6d-4df9-91f2-f88d2824da48%40googlegroups.com?utm_medium=email&utm_source=footer> > . > > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/CA%2BnsWgx6pzQUtop%2BbF%3DtH8hN4VYzhJR-BcHhgC-%2Bm3_z6eijVw%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
