Create your GitHub Repo
Last updated
If you have a pre-existing repo you wish to use, feel free to skip this section
Your Github repo will be where you store your docker compose files, and anything else you wish to store alongside it. Placing these files in Github makes the risk of losing your compose files to a dead harddrive impossible.
You can also store your Ansible playbooks in there too Ansible
Follow GitHubs documentation on creating a repo
Recommended: Set your repo as private
I would recommend creating a Private repo as this hides it from the public internet. The advantage of this is it reduces the risk of leaking credentials, API keys etc if you accidentally save them into a file on the repo. The best way to secure your repo is to use variables and secrets
Version history is always there, so if you accidentally save a password or API key its saved forever. The only way to remove it is to delete the repo.
If you are using a public repo, skip this section
As your repo is private, you will need to create a PAC for Portainer to use and access the repo
Click on your profile in the top right, then select Settings
On the left, click on Developer Settings
Click on Personal Access Tokens, then 'Tokens (classic)'
Click on 'Generate new token', then select 'Classic'
Input the below information

Scroll down and click on 'Generate Token'
Save your PAC to your password vault
Last updated