GithubHelp home page GithubHelp logo

theobori / minimal-config Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 46 KB

๐Ÿ’ฝ Minimal Debian configuration managed with Ansible playbook

License: MIT License

Shell 66.57% Jinja 33.43%
ansible-playbook configuration debian

minimal-config's Introduction

๐Ÿ’ฝ minimal-config

ansible-lint

Minimal dependencies and configuration used on Debian system.

๐Ÿ“– How to build and run ?

  1. Install the dependencies
    • ansible
    • ansible galaxy dependencies
ansible-galaxy install -r requirements.yml
  1. Configure a vault password (a filepass is better)
  2. Configure an inventory
  3. Configure a playbook
    1. Inventory (if needed)
    2. Replace variables
    3. Encrypt the needed ones
  4. Run the playbook
ansible-playbook \
   -i inventory.yml \
   --vault-password-file .vault_pass \
   main.yml

We assume you run the playbook as root.

โš ๏ธ knockd risks

In this configuration, we are using knockd to manage the openSSH firewall (ufw) rules. It can be very risky. If you want to be safe you can exclude the knockd task by commenting the following line in roles/security/tasks/main.yml:

- include_tasks: knockd.yml

And then add a rule for ufw that allow you SSH connections.

โ„น๏ธ Roles and variables

Roles

  • nickjj.docker: Setup and configure Docker + docker-compose.
  • weareinteractive.ufw: Setup the firewall and configure it.
  • base: Install basics needed packages for the other roles.
  • profile: Setup some default configuration for new users.
  • security: Setup system security tools/services like ssh, knockd, etc.
  • shell: Setup a shell environment with fish + tmux .

Variables

SSH

  • ssh_identity_key_path: SSH public key used to auth.
  • ssh_port: Change the default SSH port.

Port knocking

  • knockd_open_ssh_seq: Knockd open SSH (should be encrypted).
  • knockd_close_ssh_seq: knockd close SSH (should be encrypted).
  • knockd_tmp_open_ssh_seq: Temporary open SSH (should be encrypted).
  • knockd_opts: knockd CLI arguments used by the service.

minimal-config's People

Contributors

theobori avatar

Watchers

 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.