Git Product home page Git Product logo

ansible_proxmox_hetzner's Introduction

Proxmox on Hetzner BareMetal with ansible

I made this project just for fun, it allows you to create a proxmox host on Hetzner BareMetal

Features

  • Debian full crypted ROOT partition
  • Install OPNsense as a router. Fake the MAC Address if tge primary Interface and bridged to WAN
  • Autoinstall OPNsense (still in progress..)
  • Create Backup of OPNsense after setup
  • Create Cloud-INIT Images
  • Install Proxmox Backup Server

Requirements

  • ansible-galaxy collection install community.hrobot - Need for Hetzner API
  • Tested on Hetzner Bare Metal EX43 at HEL1 - last run 19.10.2022

Variables

  • hetzner_pbs_setup [default: true ]: Install Proxmox Backup Server
  • hetzner_pve_autorescue [default: true ]: Set rescue mode automaticly and generate SSH Key if not present
  • hetzner_pve_hetzner_api_user [default: secret ]: Hetzner API user
  • hetzner_pve_hetzner_api_pass [default: secret ]: Hetzner API password
  • hetzner_pve_luks_pass [default: secret ]: Luks encryption password
  • hetzner_pve_ssh_keys [default: secret ]: Your SSH Pubkey to login (openssh,busybox boot) - If no SSH Key is provided, ansible will create a new one at ~/.ssh/id_ed25519_ansible
  • hetzner_pve_acme_mail [default: [email protected] ]: Mail address for acme by letsencrypt
  • hetzner_pve_acme_domain [default: vmhost.domain.com ]: fqdn from your vmhost - must reachable from external
  • hetzner_pve_storagebox_server: storagebox / cifs account to automount
  • hetzner_pve_custom_packages: list of custom packages to install
  • hetzner_pve_setup_opnsense [default: true]: Provision a OPNsense vm Firewall
  • hetzner_pve_setup_opnsense_force [default: true]: Destroy the old vm and recreate
  • hetzner_pve_setup_opnsense_enable_ipv6 [default: false]: Enable IPV6
  • hetzner_pve_setup_opnsense_settings_lan_dhcpd [default: true]: Start DHCP on LAN Bridge
  • hetzner_pve_setup_opnsense_user [default: ansible]: Create a ansible user for ansible
  • hetzner_pve_network_lan_subnet [default: 24"]: Internal LAN Subnet
  • hetzner_pve_network_lan_ip [default: "192.168.49.2"]: Internal LAN IP for Proxmox
  • hetzner_pve_network_vm_lan_ip [default: "192.168.49.254"]: Internal LAN IP for OPNsense
  • hetzner_pve_network_vm_lan_dhcp_from [default: "192.168.49.100"]: OPNsense DHCP range start
  • hetzner_pve_network_vm_lan_dhcp_to [default: "192.168.49.150"]: OPNsense DHCP range end

Howto

  • ansible-playbook playbook.yml -i inventory/hosts

  • When playbook finished

    Please change OPNsense password!!!
    Gui is only reachable by {{ ipify_public_ip  }}
    
    OPNsense GUI: https://{{ ansible_host }}
        Username: root
        Password: opnsense
    
    Proxmox GUI: https://{{ ansible_host }}:{{ hetzner_pve_setup_opnsense_fwd_proxmox_gui_port }}
        Username: root
        Password: <yoursecret>
    

Todos

  • Testing and improvements

thanks to https://github.com/extremeshok/xshok-proxmox

ansible_proxmox_hetzner's People

Contributors

atai avatar kpma1985 avatar

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.