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

Use image with tag 0.1.0 not canary #124

Merged
merged 1 commit into from Apr 18, 2018

Conversation

Projects
None yet
2 participants
@potsbo
Copy link
Contributor

commented Apr 18, 2018

WHY

After following the installation guide published at https://appscode.com/products/guard/0.1.0/setup/install/, I could not manage to get the container start

pod status

guard-5c566f688b-j2mk2 0/1 CrashLoopBackOff 12 37m

log of the pod

Error: unknown flag: --tls-ca-file
Usage:
  guard run [flags]

Flags:
      --ca-cert-file string   File containing CA certificate
      --cert-file string      File container server TLS certificate
  -h, --help                  help for run
      --key-file string       File containing server TLS private key
      --ops-addr string       Address to listen on for web interface and telemetry. (default ":56790")
      --web-address string    Http server address (default ":9844")

Global Flags:
      --alsologtostderr                  log to standard error as well as files
      --analytics                        Send analytical events to Google Guard (default true)
      --log_backtrace_at traceLocation   when logging hits line file:N, emit a stack trace (default :0)
      --log_dir string                   If non-empty, write log files in this directory
      --logtostderr                      log to standard error instead of files (default true)
      --stderrthreshold severity         logs at or above this threshold go to stderr (default 2)
  -v, --v Level                          log level for V logs (default 0)
      --vmodule moduleSpec               comma-separated list of pattern=N settings for file-filtered logging

I believe this is because I was using an image with the tag canary, which has not been updated for 4 months according to https://hub.docker.com/r/appscode/guard/tags/ .
Changing canary to 0.1.0 worked for me.

WHAT

I changed default tag from canary to 0.1.0.

NOTE

I don't mind closing this PR to fix installation guide or some deploy flow,
because I really don't know this is the cause.
(Maybe canary should be updated more often? or maybe I did something wrong)

@tamalsaha tamalsaha merged commit b62ae5d into appscode:master Apr 18, 2018

1 check failed

continuous-integration/travis-ci/pr The Travis CI build failed
Details
@tamalsaha

This comment has been minimized.

Copy link
Member

commented Apr 18, 2018

Thanks @potsbo

@tamalsaha

This comment has been minimized.

Copy link
Member

commented Apr 18, 2018

Actually, I think this pr should not be merged. Did you build guard from source @potsbo ?

tamalsaha added a commit that referenced this pull request Apr 18, 2018

tamalsaha added a commit that referenced this pull request Apr 18, 2018

@potsbo

This comment has been minimized.

Copy link
Contributor Author

commented Apr 18, 2018

No, go get github.com/potsbo/guardfails, so does go get github.com/appscode/guard
I think that is not because of my PR though.

@tamalsaha

This comment has been minimized.

Copy link
Member

commented Apr 19, 2018

@potsbo , we use Go's linker variable to inject version number from Git tag when we cut a release. https://blog.cloudflare.com/setting-go-variables-at-compile-time/

Image: fmt.Sprintf("%s/guard:%v", opts.PrivateRegistry, stringz.Val(v.Version.Version, "canary"))

Here, the v.Version.Version is the git tag number and if you use the Guard cli binary from our github release page, you will see that the generated image is using 0.1.0 tag. If you build the code yourself, then it just uses canary, which is a common tag we use for development.

go get github.com/appscode/guard fails because, go get does not object the vendor folder and builds from whatever binary it can find in GOPATH. So, to build it from source follow the steps below:

$ mkdir -p $(go env GOPATH)/src/github.com/appscode
$ cd $(go env GOPATH)/src/github.com/appscode
$ git clone https://github.com/appscode/guard
$ cd guard
$ go install -v

$ guard -h
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.