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

Adding documentation about secrets and tokens #311

Open
wants to merge 16 commits into
base: main
Choose a base branch
from
Open

Conversation

germa89
Copy link
Contributor

@germa89 germa89 commented May 17, 2023

This PR aims to document the usage of secrets and tokens in the orgs.

It add the following sections:

  • Organization secrets
    • Actions secrets
    • Dependabot secrets
  • Organization tokens
    • GithHub tokens
    • PyPI tokens
    • Other tokens
  • Organization bot

The idea is to have secrets and tokens.

secrets can be used to store tokens, in that case, the secrets table will have a "value" pointing to the corresponding token. Remember that tokens can have names (and descriptions), and we should use that to identify the tokens rather than the secret itself.

One I have access to the bot, I will have access to the list of permissions of each bot tokens. Then I will fill the token table.

@germa89 germa89 marked this pull request as draft May 17, 2023 10:02
@germa89 germa89 self-assigned this May 17, 2023
@github-actions github-actions bot added the documentation Improvements or additions to documentation label May 17, 2023
@germa89
Copy link
Contributor Author

germa89 commented May 18, 2023

The core of the PR is done. Two things:

  • Fix emojis not being render
  • Fix the classic tokens table with all the tokens.

Feel free to review for format and approach.

@germa89 germa89 requested a review from PipKat May 18, 2023 16:19
@germa89 germa89 marked this pull request as ready for review May 18, 2023 16:19
@germa89
Copy link
Contributor Author

germa89 commented May 18, 2023

DO NOT MERGE YET

Copy link
Member

@RobPasMue RobPasMue left a comment

Choose a reason for hiding this comment

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

LGTM. Minor comments

doc/source/how-to/continuous-integration.rst Outdated Show resolved Hide resolved
doc/source/how-to/continuous-integration.rst Outdated Show resolved Hide resolved
doc/source/how-to/continuous-integration.rst Outdated Show resolved Hide resolved
| Full control of codespaces. | |
+-------------------------------------------------------------------------------------+------------------------+
| **codespace:secrets** | |:x:| |
| Ability to create, read, update, and delete codespace secrets. | |
Copy link
Member

Choose a reason for hiding this comment

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

Solve Vale issues. You will need to add both Codespace and codespace. Same goes for Codespaces and codespaces.

doc/source/how-to/continuous-integration.rst Outdated Show resolved Hide resolved
doc/source/how-to/continuous-integration.rst Outdated Show resolved Hide resolved
**************

The value of the ``PYPI_TOKEN`` token is unique for each repository.
This token is used for authentication when uploading libraries to the public PyPI index.
Copy link
Contributor

Choose a reason for hiding this comment

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

@ansys/pyansys-core We could specify/remember how to get this token maybe. I don't know if it is relevant here.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

No idea....

``TWINE_TOKEN``
***************

The ``TWINE_TOKEN`` token is used for authentication when uploading libraries to PyPI.
Copy link
Contributor

Choose a reason for hiding this comment

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

@germa89 @RobPasMue I would specify the difference with the PYPI_TOKEN described above.

Copy link
Contributor Author

@germa89 germa89 Jun 16, 2023

Choose a reason for hiding this comment

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

I'm not super convinced of its difference.

~~~~~~~~~~~~~~~~~~~~~~~~~~

+-------------------------------------+------------------------------------+---------------------------------------+-------------------------------------------+----------------------------------------------------------------------------------------------+
| **Secret** | **Repository access** | **Token** | **Value** | **Description** |
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
| **Secret** | **Repository access** | **Token** | **Value** | **Description** |
| **Secret** | **Repository access** | **Token** | **Value** | **description** |

| | A user's followers. | |
+----------------------------------------------------------------+----------------------------------------+
| | **GPG keys** | No access |
| | View and manage a user's GPG keys. | |
Copy link
Member

@PipKat PipKat Jun 13, 2023

Choose a reason for hiding this comment

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

Will users know what a GPG key is? I don't! (Thank goodness for Google! Let readers search for an answer if they are clueless like me!

| **read:audit_log** | |:x:| |
| Read access of audit log. | |
+-------------------------------------------------------------------------------------+------------------------+
| **codespace** | |:x:| |
Copy link
Member

Choose a reason for hiding this comment

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

So, codespace is lower case here in this section, if this influences your response to the capitalization question posed earlier?

Copy link
Contributor Author

@germa89 germa89 Jun 16, 2023

Choose a reason for hiding this comment

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

Definitely Github needs a Kathy.

I need to update this yes.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'm going to go with "C"odespace(s)

Copy link
Member

Choose a reason for hiding this comment

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

@germa89 Virtually all stye guides say not to use (s) but rather to use the plural form instead.

``HUGO_THEME_TOKEN``
********************

The ``HUGO_THEME_TOKEN`` token is used to ... # todo: to be added
Copy link
Member

Choose a reason for hiding this comment

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

We don't want the unfinished stuff visible in the public doc, do we?!

Copy link
Contributor Author

Choose a reason for hiding this comment

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

No no... in fact, this part needs to be deleted. Because it is not used by (almost) any repo.

Co-authored-by: Roberto Pastor Muela <[email protected]>
Co-authored-by: Maxime Rey <[email protected]>
Co-authored-by: Kathy Pippert <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants