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

(doc) docker docs "Test it locally" section not working as expected (I assume) #2172

Closed
silentpete opened this issue Aug 1, 2024 · 3 comments · Fixed by #2173
Closed

(doc) docker docs "Test it locally" section not working as expected (I assume) #2172

silentpete opened this issue Aug 1, 2024 · 3 comments · Fixed by #2173
Assignees
Labels
bug Something isn't working documentation Improvements or additions to documentation

Comments

@silentpete
Copy link

Change in the documentation

Hello,
When I follow the current hub.docker.com documentation and I get to the Call the API curl post, I get the following back.

{"message":"missing key in request header"}

I do not think this is the intended outcome you'all want first time consumers to experience...

TTYL,
Peter

Extras Info

go feature flag docker docs command outputs:

vagrant@peter(~) $ curl https://raw.githubusercontent.com/thomaspoignant/go-feature-flag/main/cmd/relayproxy/testdata/config/valid-file.yaml -o goff-proxy.yaml
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100   379  100   379    0     0   1592      0 --:--:-- --:--:-- --:--:--  1592
vagrant@peter(~) $ docker run \
  -p 1031:1031 \
  -v $(pwd)/goff-proxy.yaml:/goff/goff-proxy.yaml \
  gofeatureflag/go-feature-flag:latest
█▀▀ █▀█   █▀▀ █▀▀ ▄▀█ ▀█▀ █ █ █▀█ █▀▀   █▀▀ █   ▄▀█ █▀▀
█▄█ █▄█   █▀  ██▄ █▀█  █  █▄█ █▀▄ ██▄   █▀  █▄▄ █▀█ █▄█

     █▀█ █▀▀ █   ▄▀█ █▄█   █▀█ █▀█ █▀█ ▀▄▀ █▄█
     █▀▄ ██▄ █▄▄ █▀█  █    █▀▀ █▀▄ █▄█ █ █  █ 

GO Feature Flag Relay Proxy
_____________________________________________
{"level":"info","ts":1722534439.5128477,"msg":"flag added","key":"new-admin-access"}
{"level":"info","ts":1722534439.5129137,"msg":"flag added","key":"flag-only-for-admin"}
{"level":"info","ts":1722534439.5134733,"caller":"api/server.go:115","msg":"Starting go-feature-flag relay proxy ...","address":"0.0.0.0:1031","version":"1.32.0"}
{"level":"warn","ts":1722534450.873377,"caller":"middleware/zap.go:68","msg":"Client error","remote_ip":"172.17.0.1","latency":"144.986µs","host":"localhost:1031","request":"POST /v1/feature/flag-only-for-admin/eval","status":400,"size":44,"user_agent":"curl/7.76.1","request_id":""}

curl output

vagrant@peter(~) $ curl -X 'POST' \
  'http://localhost:1031/v1/feature/flag-only-for-admin/eval'  -H 'accept: application/json'  -H 'Content-Type: application/json' \
  -d '{ "user": { "key": "[email protected]", "anonymous": true, "custom": { "admin": true, "email": "[email protected]" }}, "defaultValue": "false"}'
{"message":"missing key in request header"}
@silentpete silentpete added documentation Improvements or additions to documentation needs-triage A priority should be added to the issue labels Aug 1, 2024
@thomaspoignant thomaspoignant added bug Something isn't working and removed needs-triage A priority should be added to the issue labels Aug 1, 2024
@thomaspoignant
Copy link
Owner

This is clearly not desired.
This may be due to the fact that some API keys are defined in the configuration file downloaded in the example.

I will fix that tomorrow as soon as I have access to a computer.

@thomaspoignant
Copy link
Owner

thomaspoignant commented Aug 2, 2024

@silentpete this is now fixed and released in dockerhub with new links.
Thanks a lot for raising it 🙏

@silentpete
Copy link
Author

Thank you @thomaspoignant !!

btw, I was, poorly, just being light hearted about the desired outcome ;)

Thank you so much for getting this fixed!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants