-
Notifications
You must be signed in to change notification settings - Fork 11
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
rust-client: add api-key & listen_multi_addresses #23
Merged
Merged
Changes from 2 commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
9352c9c
rust-client: add api-key & listen_multi_addresses
elenaf9 1ea1d34
.github/workflows: enable ci again
elenaf9 50253b0
rust-client: read API_KEY from env variable
elenaf9 fa50278
rust-client: make rounds configurable
elenaf9 3b6dae2
Merge branch 'main' of github.com:dennis-tra/punchr into rust-client/…
elenaf9 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,35 +1,33 @@ | ||
# Based on https://github.com/actions-rs/meta/blob/master/recipes/quickstart.md | ||
|
||
# commented out until this works again | ||
name: Cargo check | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
check: | ||
name: Check | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout sources | ||
uses: actions/checkout@v2 | ||
|
||
- name: Install stable toolchain | ||
uses: actions-rs/toolchain@v1 | ||
with: | ||
profile: minimal | ||
toolchain: stable | ||
override: true | ||
|
||
- name: Run cargo check | ||
uses: actions-rs/cargo@v1 | ||
with: | ||
command: check | ||
args: --manifest-path=rust-client/Cargo.toml | ||
|
||
# name: Cargo check | ||
# | ||
# on: | ||
# push: | ||
# branches: | ||
# - main | ||
# pull_request: | ||
# branches: | ||
# - main | ||
# | ||
# jobs: | ||
# check: | ||
# name: Check | ||
# runs-on: ubuntu-latest | ||
# steps: | ||
# - name: Checkout sources | ||
# uses: actions/checkout@v2 | ||
# | ||
# - name: Install stable toolchain | ||
# uses: actions-rs/toolchain@v1 | ||
# with: | ||
# profile: minimal | ||
# toolchain: stable | ||
# override: true | ||
# | ||
# - name: Run cargo check | ||
# uses: actions-rs/cargo@v1 | ||
# with: | ||
# command: check | ||
# args: --manifest-path=rust-client/Cargo.toml | ||
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we should pass a secret via a command line argument. This is problematic due to:
/proc
.Instead I would use either an environment variable or a file where the file path can be passed as an argument.
What do you think @elenaf9?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point. Reading it from env variable now (50253b0). If it is not present I am logging a warning but still continuing, in case that we ever decide to (temporarily?) disable auth again. Can also change it in a follow up PR to throw an error, if you think that makes more sense.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Given that it is a mechanism for the server to establish trust to the client and not the other way around, I think defaulting to not using the API key is fine here. 👍