A Gamers Grind / XFGN / LM
Status
  • 🖥️www.agamersgrind.com
  • 🏙️--- Public Files ---
    • 👋Welcome, friends
    • ⛑️I need help!
    • ☕Buy me a Coffee
  • 📚Guides
    • Mini Guides
      • Valheim FPS Boost
      • Redirect domain to Google Site
      • Docker Compose
        • 'All' Compose File
        • Add Health Check to Container
        • Mount NFS Share to Container
        • Map hostname to container
    • Portainer and GitOps
      • Set up GitHub
      • Install Portainer
      • Create your first GipOps Compose file
      • Deploy your first GitOps stack
      • Managing your production compose files
    • Cloudflare
      • Domains
      • Generate an API Key
      • Tunnel
        • Create a Tunnel
        • Create a Proxy (Public Hostname)
        • Access Groups & Authentication
      • Dynamic DNS
    • Pterodactyl
      • Creating a new Panel
      • Creating a new Wings node
      • Join servers via domain
      • Configuring your Node Database
      • Server Best Practices & Suggestions
      • Troubleshooting
  • 🎮Game Servers
    • Valheim Public
    • Valheim Private
    • MultiMC (Minecraft)
    • CreateCraft (Minecraft)
    • Insurgency Sandstorm
  • ⚔️AGG Moderation
    • ❔Creating a new Server
    • Approving Valheim Application
  • 🗄️Internal Documentation
Powered by GitBook
On this page
  • What is a Stack?
  • Deploy your Stack

Was this helpful?

  1. Guides
  2. Portainer and GitOps

Deploy your first GitOps stack

PreviousCreate your first GipOps Compose fileNextManaging your production compose files

Last updated 1 year ago

Was this helpful?

What is a Stack?

Stacks is how Portainer handles Docker Compose files, which are infrastructure as code documents for spinning up multiple containers, volumes and networks in 1 go.

Most docker container developers now provide example compose files with their projects. Its also possible to Google and find examples online


For example, you may have a service that has a separate container for

  • a database

  • a web app

  • back end compute

The database and back end compute may be on Network 1, while the web app is on Network 2.

All 3 containers have access to the same 'config' volume, but the database and webapp have their own unique volumes

The database and backend need the same credentials to the 2 systems can talk, but the web app has separate credentials for the gui. These are environmental variables


Instead of manually setting up and inputting environmental variables, networks and volumes for each container this can all be written into the compose and and span up in 1 click. This also makes the set up system agnostic.

Deploy your Stack

In this practice, we're going to deploy the Ombi compose file we created in Create your first GipOps Compose file

  1. Log into Portainer

    1. If you set up Edge Agents, click on the host you want Ombi to exist on

  2. On the left hand menu, select 'Stacks'

  3. Click on 'Add stack'

    1. Give your stack a name (eg "ombi")

    2. Build method = Repository

    3. Tick 'Authentication'

      • Username = Github Email

    4. Repository URL = the URL of your repo + .git (eg "https://github.com/trentnbauer/agg.local.git_"_)

    5. Compose path = docker-compose/ombi.yml

    6. Tick 'Automatic updates' You should see a page similar to this,\

    7. Scroll down to the 'environment variables' section and add the following variables

      • TZ

      • BASE_URL

      • PORT_HTTP

    8. Provide a base url, if you are using one (not required)

    9. Provide the port that Ombi will use

    10. Click on 'Deploy the stack'

If you have any issues, refer to the Notifications tab at the top of the page;

Provide your TZ per the

Most Portainer errors can be resolved with a simple Google search but I also have my own

📚

Time Required

30 Minutes

Difficulty

Low

'tz identifier' here
troubleshooting list here
Pro tip - you can use the Fetch interval to delay updates on some services. An example I have of this is my redundant Cloudflare Tunnel containers. One server updates every 15 minutes, the other updates every 24hours. They both use the same compose file. This means if an update breaks the 15m instance, then 24h is still live for me to roll back
Personal Access Token