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

Linode support #144

Merged
merged 15 commits into from
Jan 20, 2021
Merged

Linode support #144

merged 15 commits into from
Jan 20, 2021

Conversation

qdm12
Copy link
Owner

@qdm12 qdm12 commented Jan 17, 2021

Fixes #143

@qdm12 qdm12 force-pushed the linode branch 4 times, most recently from 47c7190 to 0a0cfdf Compare January 17, 2021 17:06
internal/settings/linode.go Show resolved Hide resolved
}
r.Header.Set("Content-Type", "application/json")
r.Header.Set("Authorization", "Bearer "+l.token)
r.Header.Set("oauth", "domains:read_only")

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I may be mistaken, but given we're using a personal access token, I don't think we need to define oauth headers?

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey thanks for the review 👍

That's what they have on their documentation.
You can probably define tokens with different kind of permissions.
It might not work if you don't precise which permission you want, but I can't test it for sure, I don't have an account 😉

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good! When creating the token, I had to assign permissions to it, but better to go with what the documentation says :)

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh interesting which permissions? Are these the same as in the code? So I can add these to the Linode documentation.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Go to setting and API Tokens:
Screen Shot 2021-01-17 at 6 56 51 PM

API Tokens Tab:
Screen Shot 2021-01-17 at 6 57 38 PM

Add Personal Access Token.
Screen Shot 2021-01-17 at 6 53 54 PM

I have a token with domains set, with read and write privileges, set to never expire

@qdm12 qdm12 force-pushed the linode branch 2 times, most recently from a87609a to a9928d0 Compare January 19, 2021 22:58
@qdm12 qdm12 merged commit 180092f into master Jan 20, 2021
@qdm12 qdm12 deleted the linode branch January 20, 2021 23:31
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

Successfully merging this pull request may close these issues.

Feature request: Add Linode as a DNS provider
2 participants