Coder Social home page Coder Social logo

maas-juju-sandbox's Introduction

MAAS Juju Sandbox

Prepare a local environment using KVM virtual machines as the 'bare metal', ready for maas-installation before deployment with Juju.

maas-installation is a related project to install and configure the MAAS server, and add the nodes.

This project assumes to configure these two virsh NAT networks on the host machine:

  • 192.168.123.0/24 as the private network
  • 192.168.124.0/24 as the public network

Install and Configure Virtual Networks and Machines

On the host machine

  • scripts/00_install-host.sh to prepare the host machine, including creation of virsh networks
  • scripts/01_create-images.sh to download the latest cloud image, create VM disks and seed disk
  • scripts/02_define-machines.sh to define the VMs in virsh
  • scripts/03_generate-secrets.sh to generate the secrets and templates files to be used with maas-installation

MAAS Server Configuration

  • The maas0 VM is defined in scripts/02_define-machines.sh
  • maas0 gets its configuration from maas0-seed.img, created by scripts/01_create-images.sh
    • maas0/user-data stores the password to be set for the ubuntu user
    • maas0/meta-data configures networking

Initial Environment

Start maas0

  • virsh start maas0
    • virsh console maas0 if you'd like to watch it boot
  • ssh -o StrictHostKeyChecking=no -l ubuntu 192.168.123.2
  • Secrets files to be used with maas-installation have been created in ./maas-installation/

Using the mass-installation project code on maas0, install and configure MAAS

  • Use the generated secrets as the maas-installation/secrets/ files
  • During installation, maas-installation/scripts/install-mass.sh also configures MAAS 'Global Kernel Parameters' to set "console=ttyS0" for virsh console
  • Add the nodes listed in maas-installation/secrets/host-inventory.txt to MAAS
    • maas-installation/scripts/maas-add-hosts.sh -d
  • Add this maas cloud to Juju
    • juju add-cloud maas-cloud ${generated_secrets}/maas-clouds.yaml
    • juju add-credential maas-cloud ('maas-oath', when prompted, is the API key from maas-region apikey --username=maas-root)

maas-juju-sandbox's People

Stargazers

 avatar  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.