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

Badges "not authorized" in v2.0 #610

Closed
drnic opened this issue Aug 29, 2016 · 16 comments
Closed

Badges "not authorized" in v2.0 #610

drnic opened this issue Aug 29, 2016 · 16 comments

Comments

@drnic
Copy link
Contributor

drnic commented Aug 29, 2016

http://engineering.pivotal.io/post/concourse-badges/ came out just in time for v2.0, where the API and authorization changed.

I guessed that I need to include /teams/main in the URL; but when I try to get the badge for a public job I get:

$ curl -k https://ci.vsphere.starkandwayne.com/api/v1/teams/main/pipelines/dingo-postgresql-release/jobs/rc/badge
not authorized

A bug in new teams; or something I need to enable to support public badges?

/cc @cunnie

@concourse-bot
Copy link
Collaborator

Hi there!

We use Pivotal Tracker to provide visibility into what our team is working on. A story for this issue has been automatically created.

The current status is as follows:

This comment, as well as the labels on the issue, will be automatically updated as the status in Tracker changes.

@vito
Copy link
Member

vito commented Aug 29, 2016

Seems OK for me: https://ci.concourse.ci/api/v1/teams/main/pipelines/main/jobs/atc/badge

Make sure you've run expose-pipeline for the pipeline to be public.

Also: I completely forgot about the badge API endpoint; we probably should've at least kept that working. Crap.

@drnic
Copy link
Contributor Author

drnic commented Aug 29, 2016

Awesome. expose-pipeline did the trick

On Mon, Aug 29, 2016 at 11:44 AM +1000, "Alex Suraci" notifications@github.com wrote:

Seems OK for me: https://ci.concourse.ci/api/v1/teams/main/pipelines/main/jobs/atc/badge

Make sure you've run expose-pipeline for the pipeline to be public.

Also: I completely forgot about the badge API endpoint; we probably should've at least kept that working. Crap.


You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or mute the thread.

@vito vito closed this as completed Aug 31, 2016
@emcniece
Copy link

emcniece commented Apr 1, 2017

Is there any way to have public badges for private pipelines?

@mbana
Copy link

mbana commented Mar 12, 2018

^ just wondering if anyone has a workaround for this.

is there a view-only mode so if one does decide to make it public, others can't start a build or some operation that modifies that state in any way?

@emcniece
Copy link

@mbana nope, nothing official yet.

I made a deploy job that pushes the badges to an S3 bucket as a workaround 😅

@cunnie
Copy link
Contributor

cunnie commented Mar 13, 2018

@mbana I use expose-pipeline but require auth to trigger a build, which allows people to see my badges but they can't view any job outputs or trigger builds or anything (read-only, with a limited read)

For example, if you browse to https://ci.nono.io/ you can see my Concourse server and if you browse to https://sslip.io/ you can see the badge being displayed, but you won't be able to trigger a build or see job output without logging in first. I believe that's what you're looking for. Here's my Concourse manifest: https://github.com/cunnie/deployments/blob/69116c060e1bc9ce72e168bdbc55709546bf14aa/concourse-ntp-pdns-gce.yml#L29

vito added a commit that referenced this issue Mar 28, 2018
Submodule src/github.com/miekg/dns 0c23f842..22cb769f:
  > use a local variable to calculate rtt (#656)
  > [msg] Add UnpackRRWithHeader (#643)
  > fix: panicing on options parsing. (#642)
  > Test that Shutdown does not surface closed errors (#624)
  > Release 1.0.4
  > Fix for CVE-2017-15133 TCP DOS (#631)
  > Add dnscrypt-proxy and rpdns to the list of users (#628)
  > Fix TCP Shutdown 'use of closed network connection' (#623)
  > Release: plain push is also needed
  > Release 1.0.3
  > Ignore malformed UDP datagrams without headers (#622)
  > Fixes #613 & #619 (#621)
  > Revert "Fixes #613 (#617)" (#620)
  > ClassANY: don't convert CLASS255 to ANY (#618)
  > Fixes #613 (#617)
  > test: remove net tests (#616)
  > Release 1.0.1
  > Don't use untrusted lengths from Header to pre-allocate (#610)
  > Unpack: return header (#608)
  > Fix issue #605 (#606)
  > relative include: now tested! (#602)
  > Allow $INCLUDE to reference relative file (#598)
  > Add size-hex: modifier for len() (#599)
  > Some linter fixes from Go report card. (#601)
  > Add codecov yaml to not fail the build (#600)
  > Lint: use ignore-this on generated files (#596)
  > Add semver (#595)
  > Use and vendor golang.org/x/net/ipv4 and golang.org/x/net/ipv6 (#594)
  > EDNS0 client subnet: drop draft option (#589)
  > Add support for TKEY RRs (#567)
  > Modified clientconfig to match ndots0 (#590)
  > 458+dep (#591)
  > Include missing types when for DNSSEC sig verify (#587)
  > Implement CSYNC (#585)
  > Remove idn/ (#584)
  > Spelling fixes (#583)
  > Add fuzzing framework (#580)
  > Fuzzing the text parser: a few fixes (#579)
  > Test: rework concurrentExchange (#576)
  > TSIG name must be presented in canonical form (#574)
  > cleanup: remove debug.Printf from scanner (#573)
  > txt parser: fix goroutine leak (#570)
  > Server: drop inflight waitgroup (#561)
  > Tests: add ListenAndServe tests (#562)
  > Revert "server: drop graceful handling (#546)" (#560)
  > server: drop graceful handling (#546)
  > util.TrimDomainName() fails when origin doesn't end in dot (#559)
  > Tests updates (#556)
  > readme: small bunch updates (#554)
  > golint fixes (#553)
  > Add goreportcard badge (#552)
  > codecov: add shield to README (#551)
  > codecov: add test coverage (#550)
  > Cleanup: gofmt -w -s *.go (#548)
  > Test: remove all Logf/Log (#547)
  > Make compress generate output stable and edns.go formatting (#542)
  > Document SetTsig() needs to be final RRset change (#544)
  > Change quilt.io link in the README to kelda.io (#539)
  > Add Apex in Users (#538)
  > Optimize CompareDomainName (#535)
  > Allow parsing resolv.conf from io.Reader (#532)
  > Fix EDNS0_SUBNET compatibility with dig (#530)
  > Fix EDNS Extended RCODE (#517)
  > Fix IXFR may end prematurely (#512) (#507)
  > Simplify compressed length code (#527)
  > Go version bump in CI (#534)
  > Fix DialTimeout always using udp (#526)
  > Redesigned Client API around net.Dialer (#511)
  > Correctly set the Source IP to the received Destination IP (#524)
  > Correctly parse omitted TTLs and relative domains (#513)
  > Implement EDNS(0) Padding option code (#520)
  > scan: Fix $INCLUDE arguments to parseZone (#508)
  > Fix TSIG bug releated to ID substitution (#504)
  > variable shadowing of token (#503)
  > document RCodes from the IANA registry (#499)
  > Fix ignored err variables. (#498)
  > Add ExchangeContext methods. (#497)
  > xfr: return sane error when !RcodeSuccess (#496)
  > Added dnsperf (#494)
  > Added new user (#495)
@mohsen0
Copy link

mohsen0 commented Aug 1, 2019

The option to only expose the badge publicly would have made this feature useful
since GitHub forces the embedded picture in the readme go through its proxy

@vito
Copy link
Member

vito commented Aug 1, 2019

@mohsen0 Good point. I think that should probably be opened as a new issue though. Comments on resolved issues tend to not go anywhere.

@apolegoshko
Copy link

apolegoshko commented Mar 5, 2020

Why it's closed ? And will it be implemented ?

@taylorsilva
Copy link
Member

@apolegoshko I think #5252 fixes this

@apolegoshko
Copy link

@taylorsilva 👍

@itsouvalas
Copy link

@mbana I use expose-pipeline but require auth to trigger a build, which allows people to see my badges but they can't view any job outputs or trigger builds or anything (read-only, with a limited read)

For example, if you browse to https://ci.nono.io/ you can see my Concourse server and if you browse to https://sslip.io/ you can see the badge being displayed, but you won't be able to trigger a build or see job output without logging in first. I believe that's what you're looking for. Here's my Concourse manifest: https://github.com/cunnie/deployments/blob/69116c060e1bc9ce72e168bdbc55709546bf14aa/concourse-ntp-pdns-gce.yml#L29

Heya there @cunnie, great workaround you got there. I understand its been quite sometime since your update, but, is there a chance you could elaborate further on what yielded the user experience demonstrated?

That said +1 on the thread/feature 😃

@cunnie
Copy link
Contributor

cunnie commented Apr 8, 2022

@itsouvalas :

Heya there @cunnie, great workaround you got there. I understand its been quite sometime since your update, but, is there a chance you could elaborate further on what yielded the user experience demonstrated?

I would say that typing the command yielded the user experience demonstrated:

fly -t nono expose-pipeline -p sslip.io

@itsouvalas
Copy link

Thanks for the update @cunnie! I must have mixed it up with the 401 Unauthorized you get from u2date-integration. sslip.io still has unit and dns-servers... unless there is more to it and it is hidden from plain sight, though fly -t nono expose-pipeline -p sslip.io alone I'm (almost) certain doesn't do that...

@cunnie
Copy link
Contributor

cunnie commented Apr 8, 2022

... 401 Unauthorized you get from u2date-integration.

Yeah, u2date is a weird pipeline because it only has 1 job, so browsing to the pipeline brings you to that one job, which you can't see any output because although I've exposed the pipeline, I haven't made the jobs public.

Here's the URL to retrieve the badge for u2date pipeline: <[401 Unauthorized you get from u2date-integration.](https://ci.nono.io/api/v1/teams/main/pipelines/u2date/jobs/integration/badge)>

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

No branches or pull requests

10 participants