Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow the GH bridge to run without a server (and use a local Git directly) #577

Merged
merged 5 commits into from
Jun 1, 2017

Conversation

samoht
Copy link
Member

@samoht samoht commented May 20, 2017

For instance, you could do:

$ datakit-bridge-github -r samoht/test -d git:///tmp/foo
Starting datakit-bridge-github %%VERSION%% (*:rw)...
Connecting to git:///tmp/foo [github-metadata].

And then:

$ tree /tmp/foo
.
└── samoht
    └── test
        ├── pr
        │   └── 32
        │       ├── base
        │       ├── head
        │       ├── state
        │       └── title
        └── ref
            ├── heads
            │   ├── adassad
            │   │   └── head
            │   ├── bar
            │   │   └── head
            │   ├── master
            │   │   └── head
            │   ├── samoht-patch-1
            │   │   └── head
            │   ├── test
            │   │   └── head
            │   ├── test2
            │   │   └── head
            │   ├── toto
            │   │   └── head
            │   └── yyy
            │       └── head
            └── tags
                └── titi
                    └── head

16 directories, 13 files

You can then edit the Git repo, and when you commit changes they are reflected directly to GitHub.

This is useful to run the bridge with one command and does not require
to have a DataKit server running.

Signed-off-by: Thomas Gazagnaire <[email protected]>
The current default is sensible when running in Docker: it was not
when run as a normal binary.

Signed-off-by: Thomas Gazagnaire <[email protected]>
@samoht
Copy link
Member Author

samoht commented Jun 1, 2017

The last failure is due to https://github.com/moby/datakit/blob/master/ci/src/cI_docker.ml#L125

From @talex5 on slack:

Ah, maybe we need a third case:

  • No FROM override => pull
  • Locally-build from => don't pull
  • Published image => pull

@samoht
Copy link
Member Author

samoht commented Jun 1, 2017

I am not super fond on how to specify the type of the endpoint, but let's change that in a subsequent PR if that's needed.

@samoht samoht merged commit 6b6f78f into moby:master Jun 1, 2017
@samoht samoht deleted the bridge-git branch June 1, 2017 11:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant