GithubHelp home page GithubHelp logo

raonigabriel / portainer_ddns Goto Github PK

View Code? Open in Web Editor NEW
0.0 3.0 0.0 726 KB

A docker-compose stack to get portainer running on your home pc, featuring ddns and https

License: Apache License 2.0

CSS 94.24% HTML 5.76%
caddy ddns docker docker-compose docker-ui home-server lets-encrypt portainer portainer-ce reverse-proxy self-hosted ssl-certificates

portainer_ddns's Introduction

portainer_ddns

A docker-compose stack to get portainer running on your home pc / cloud vm, featuring ddns and https

Features


Environment variables (change them to your values)

  • CADDY_CERT_EMAIL=[email protected]
  • CADDY_HOSTNAME_PORTAINER=myportainer.ddns.net
  • CADDY_HOSTNAME_SITE=mysite.sytes.net

You need to set those ENV variables on your host. You can add them just for one single command or permanently. I will use the first approach.


Guide

  1. Get yourself a dynamic-dns pointing to your public internet IP address. For this example, I will be using https://www.noip.com as my provider and my custom hostnames will be: myportainer.ddns.net and mysite.sytes.net

Create a new A record for myportainer.ddns.net pointing to your external IP.

Create a new CNAME record for mysite.sytes.net pointing to myportainer.ddns.net

  1. Make sure your home pc is getting assigned a static IP address from your router. The following step depends on this.

For this demo, imagine that your router IP address is 192.168.0.1 and your pc IP address is 192.168.0.2

This is also known as static IP address or IP reservation. This varies depending on the device model and manufacturer, but you can take a look on this guide here

  1. Add 2 port forwarding rules from the external world to you home pc:

[EXTERNAL] 80 -> 192.168.0.2:80

[EXTERNAL] 443 -> 192.168.0.2:443

  1. Make sure you have docker and docker-compose installed

  2. Clone this repo

$ git clone https://github.com/raonigabriel/portainer_ddns.git
  1. Start the stack, passing the variables BEFORE the docker-compose command
$ cd portainer_ddns
$ [email protected] CADDY_HOSTNAME_PORTAINER=myportainer.ddns.net CADDY_HOSTNAME_SITE=mysite.sytes.net docker-compose up -d
  1. Browse to your portainer at https://myportainer.ddns.net or your site at https://mysite.sytes.net

portainer_ddns's People

Contributors

raonigabriel avatar

Watchers

 avatar  avatar  avatar

portainer_ddns's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.