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

circle.yml: deploy non-master branches #1535

Merged
merged 1 commit into from
May 28, 2016

Conversation

alban
Copy link
Contributor

@alban alban commented May 22, 2016

By default, non-master branches are not deployed on the Docker Hub. With
this patch, you can enable this feature by setting the environment
variable DEPLOY_BRANCH in the circle configuration.

It will not be tagged with the "latest" tag but instead derive the tag
from the branch name. Since "/" are not allowed in Docker tag names, all
"/" are replaced by "-".

When testing code in Scope, I use circle to build the Docker image but I
don't want to always use my "master" branch for development.

/cc @alepuccetti

@tomwilkie
Copy link
Contributor

ERROR: http://dl-4.alpinelinux.org/alpine/edge/testing: temporary error (try again later)
WARNING: Ignoring APKINDEX.24c95890.tar.gz: No such file or directory
ERROR: unsatisfiable constraints:
  runit (missing):
    required by: world[runit]
The command '/bin/sh -c echo "http://dl-4.alpinelinux.org/alpine/edge/testing" >>/etc/apk/repositories &&   apk add --update bash runit conntrack-tools iproute2 util-linux curl &&     rm -rf /var/cache/apk/*' returned a non-zero code: 1
make: *** [scope.tar] Error 1

Look like you need to hit retry, I'd guess this is a spurious error.

@alban alban force-pushed the alban/deploy_branch branch from a163242 to 6351655 Compare May 22, 2016 17:23
@alban
Copy link
Contributor Author

alban commented May 22, 2016

Rebased on master (with #1534 merged). It seems to pass with the other mirror dl-3.alpinelinux.org.

branch: /^((?!master).)*$/ # not the master branch
commands:
- >
test -z "DEPLOY_BRANCH" || test -z "${DOCKER_USER}" || (

This comment was marked as abuse.

This comment was marked as abuse.

@alban alban force-pushed the alban/deploy_branch branch from 6351655 to ece09b3 Compare May 22, 2016 18:32
@alban
Copy link
Contributor Author

alban commented May 22, 2016

Updated. But the build fails now. I don't know why:

./common/sanitize ./probe ./probe/controls ./probe/docker ./probe/overlay ./xfer

can't load package: package github.com/weaveworks/scope/xfer: cannot find package "github.com/weaveworks/scope/xfer" in any of:

    /usr/local/go/src/github.com/weaveworks/scope/xfer (from $GOROOT)

    /go/src/github.com/weaveworks/scope/xfer (from $GOPATH)

Makefile:100: recipe for target 'tests' failed

@alban alban force-pushed the alban/deploy_branch branch from ece09b3 to a0d9df2 Compare May 27, 2016 23:00
By default, non-master branches are not deployed on the Docker Hub. With
this patch, you can enable this feature by setting the environment
variable DEPLOY_BRANCH in the circle configuration.

It will not be tagged with the "latest" tag but instead derive the tag
from the branch name. Since "/" are not allowed in Docker tag names, all
"/" are replaced by "-".

When testing code in Scope, I use circle to build the Docker image but I
don't want to always use my "master" branch for development.
@alban
Copy link
Contributor Author

alban commented May 28, 2016

Rebased on master and Circle has built it fine.

@tomwilkie
Copy link
Contributor

Thanks! Sorry I didn't get back to you; LGTM

@tomwilkie tomwilkie merged commit b20e292 into weaveworks:master May 28, 2016
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.

2 participants