From the course: Learning GitHub Actions
Unlock the full course today
Join today to access over 24,200 courses taught by industry experts.
Using secrets - GitHub Tutorial
From the course: Learning GitHub Actions
Using secrets
- [Instructor] We've seen how we can add environment variables to workflows, but sometimes we need to store sensitive information like passwords or API keys. To do that, we need to use a secret. Unlike environment variables initialized in a workflow file, secrets are stored as encrypted values in your GitHub repositories settings. After a secret is stored, it can't be viewed or edited. To change a secret, you have to delete it and recreate it. Secrets also come with a few limits. Workflows are limited to 100 secrets and secrets are limited to 64 kilobytes in size. If you need to store secrets that are larger than 64 kilobytes, you can encrypt them as files, store them in the repository and then store the decryption key as a secret in the workflow. But if you don't want to deal with that kind of workaround, keep your secrets short and sweet. You can access secrets in your workflows using the secrets context in YAML…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
(Locked)
Use an action from the Marketplace4m 6s
-
(Locked)
Use an action from a repository2m 25s
-
(Locked)
Passing arguments to an action4m 6s
-
(Locked)
Using environment variables5m 10s
-
(Locked)
Using secrets4m 1s
-
(Locked)
Using artifacts4m 7s
-
(Locked)
Manage pull requests3m 30s
-
(Locked)
Challenge: Develop a workflow that creates an artifact57s
-
(Locked)
Solution: Develop a workflow that creates an artifact8m 6s
-
(Locked)
-
-
-