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

Port flag is ignored #234

Closed
lukehinds opened this issue Mar 25, 2021 · 4 comments · Fixed by #396
Closed

Port flag is ignored #234

lukehinds opened this issue Mar 25, 2021 · 4 comments · Fixed by #396
Labels
good first issue Good for newcomers

Comments

@lukehinds
Copy link
Member

Port flag is ignored.

go run cmd/server/main.go serve --port 6962 
2021-03-25T09:25:34.084Z	INFO	app/root.go:100	Using config file: /root/rekor/rekor-server.yaml
2021-03-25T09:25:34.093Z	INFO	app/serve.go:70	Loading support for pluggable type 'rekord'
2021-03-25T09:25:34.093Z	INFO	app/serve.go:71	Loading version '0.0.1' for pluggable type 'rekord'
2021-03-25T09:25:34.093Z	INFO	app/serve.go:70	Loading support for pluggable type 'rpm'
2021-03-25T09:25:34.093Z	INFO	app/serve.go:71	Loading version '0.0.1' for pluggable type 'rpm'
2021-03-25T09:25:34.105Z	INFO	restapi/server.go:231	Serving rekor server at http://127.0.0.1:3000
@lukehinds
Copy link
Member Author

same appears to be the case for host

go run cmd/server/main.go serve --host a.b.c.d 
2021-03-25T09:38:58.030Z	INFO	app/root.go:100	Using config file: /root/rekor/rekor-server.yaml
2021-03-25T09:38:58.039Z	INFO	app/serve.go:70	Loading support for pluggable type 'rekord'
2021-03-25T09:38:58.039Z	INFO	app/serve.go:71	Loading version '0.0.1' for pluggable type 'rekord'
2021-03-25T09:38:58.039Z	INFO	app/serve.go:70	Loading support for pluggable type 'rpm'
2021-03-25T09:38:58.039Z	INFO	app/serve.go:71	Loading version '0.0.1' for pluggable type 'rpm'
2021-03-25T09:38:58.051Z	INFO	restapi/server.go:231	Serving rekor server at http://127.0.0.1:3000

@lukehinds lukehinds added the good first issue Good for newcomers label Mar 25, 2021
@puerco
Copy link
Member

puerco commented Jul 12, 2021

Just to get familiar with the codebase, as looking into this issue over the weekend but I was wondering if #339 will supersede it. WDYT @bobcallaway ?

@bobcallaway
Copy link
Member

Just to get familiar with the codebase, as looking into this issue over the weekend but I was wondering if #339 will supersede it. WDYT @bobcallaway ?

no, I don't think it will supersede it. I think the issue here is that we have two command line args for port and one is stomping over the other:

server.Port = int(viper.GetUint("rekor_server.port"))
overwrites the value of the arg --port with the value of --rekor_server.port

@hectorj2f
Copy link

I created a PR to handle this issue here #396 :).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants