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

Update readme for 0.9.8 #725

Merged
merged 4 commits into from
Aug 2, 2018
Merged

Update readme for 0.9.8 #725

merged 4 commits into from
Aug 2, 2018

Conversation

TadCordle
Copy link
Contributor

To be merged after 0.9.8 release.

@TadCordle TadCordle added this to the v0.9.9 milestone Jul 27, 2018
@@ -311,6 +320,43 @@ Configure credential helpers to use by specifying them as a `credHelper` for the
</configuration>
```

#### Using Specific Credentials

You can specify credentials directly in the <auth> parameter for the `from` and/or `to` images. In the example below, `to` credentials are retrieved from the `REGISTRY_USERNAME` and `REGISTRY_PASSWORD` environment variables.
Copy link
Member

Choose a reason for hiding this comment

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

Place <auth> in the black quotes. (Otherwise not visible at all.)

Copy link
Member

Choose a reason for hiding this comment

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

Perhaps worth mentioning to use this as a last resort, as the plain password is entered into the file? (The command line apporach is not so different, as people on the same system can see them too.)

<image>gcr.io/my-gcp-project/my-app</image>
<auth>
<username>${env.REGISTRY_USERNAME}</username>
<password>${env.REGISTRY_PASSWORD}</password>
Copy link
Member

Choose a reason for hiding this comment

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

Aha, this is the way to get env variables. Very good to know.

`-Djib.to.auth.username` | Username for target image registry.
`-Djib.to.auth.password` | Password for target image registry.

e.g. `mvn package jib:build -Djib.to.auth.username=user -Djib.to.auth.password=pass`
Copy link
Contributor

Choose a reason for hiding this comment

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

Let's prefer to use compile instead of package for example code.


e.g. `mvn package jib:build -Djib.to.auth.username=user -Djib.to.auth.password=pass`

**Note** This method of authentication should be used only as a last resort, as it is insecure to make your password visible in plain text.
Copy link
Contributor

Choose a reason for hiding this comment

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

nit: colon after Note

@TadCordle
Copy link
Contributor Author

Should be good to merge once the Maven release is done.

@chanseokoh if you want, you can also add what you'd mentioned here #643 (comment)

@TadCordle TadCordle changed the title Add auth to maven readme Update readme for 0.9.8 Aug 1, 2018
@chanseokoh
Copy link
Member

@chanseokoh if you want, you can also add what you'd mentioned here #643 (comment)

Thanks for the reminder. I'll do it after fixing #767.

@TadCordle TadCordle merged commit 320b73b into master Aug 2, 2018
@TadCordle TadCordle deleted the readme-auth branch August 2, 2018 12:55
coollog pushed a commit that referenced this pull request Aug 2, 2018
* Add auth to maven readme
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.

3 participants