Skip to content
Snippets Groups Projects
Select Git revision
  • bed8bf666117e32911a7b5b6b3fb2cf20f1fe416
  • master default protected
  • v1.14.7
  • v1.14.6
  • v1.14.5
  • v1.14.4
  • v1.14.3
  • v1.14.2
  • v1.14.1
  • v1.14.0
  • v1.13.2
  • v1.13.1
  • v1.13.0
  • v1.12.1
  • v1.12.0
  • v1.11.1
  • v1.11.0
  • v1.10.0
  • v1.9.2
  • v1.9.1
  • v1.9.0
  • v1.8.4
22 results

README-group.md

Blame
    • Rafael Guterres Jeffman's avatar
      099eb96b
      Add support for managing idoverrideusers in ipagroup. · 099eb96b
      Rafael Guterres Jeffman authored
      The group CLI option `idoverrideusers` was not supported by
      ansible-freeipa, and this patch adds support to it.
      
      Tests require an AD trust, and a user `aduser@ad.ipa.test` to exist, or
      the user name must be provided (variable, CLI)  through `test_ad_user`.
      
      A new test playbook was added:
      
          tests/group/test_group_idoverrideuser.yml
      099eb96b
      History
      Add support for managing idoverrideusers in ipagroup.
      Rafael Guterres Jeffman authored
      The group CLI option `idoverrideusers` was not supported by
      ansible-freeipa, and this patch adds support to it.
      
      Tests require an AD trust, and a user `aduser@ad.ipa.test` to exist, or
      the user name must be provided (variable, CLI)  through `test_ad_user`.
      
      A new test playbook was added:
      
          tests/group/test_group_idoverrideuser.yml
    Vagrantfile 5.25 KiB
    # -*- mode: ruby -*-
    # # vi: set ft=ruby :
    
    require 'fileutils'
    
    Vagrant.require_version ">= 1.8.0"
    
    CONFIG = File.join(File.dirname(__FILE__), "vagrant/config.rb")
    
    COREOS_URL_TEMPLATE = "https://storage.googleapis.com/%s.release.core-os.net/amd64-usr/current/coreos_production_vagrant.json"
    
    SUPPORTED_OS = {
      "coreos-stable" => {box: "coreos-stable",      bootstrap_os: "coreos", user: "core", box_url: COREOS_URL_TEMPLATE % ["stable"]},
      "coreos-alpha"  => {box: "coreos-alpha",       bootstrap_os: "coreos", user: "core", box_url: COREOS_URL_TEMPLATE % ["alpha"]},
      "coreos-beta"   => {box: "coreos-beta",        bootstrap_os: "coreos", user: "core", box_url: COREOS_URL_TEMPLATE % ["beta"]},
      "ubuntu"        => {box: "bento/ubuntu-16.04", bootstrap_os: "ubuntu", user: "vagrant"},
      "centos"        => {box: "bento/centos-7.3",   bootstrap_os: "centos", user: "vagrant"},
    }
    
    # Defaults for config options defined in CONFIG
    $num_instances = 3
    $instance_name_prefix = "k8s"
    $vm_gui = false
    $vm_memory = 1536
    $vm_cpus = 1
    $shared_folders = {}
    $forwarded_ports = {}
    $subnet = "172.17.8"
    $os = "ubuntu"
    # The first three nodes are etcd servers
    $etcd_instances = $num_instances
    # The first two nodes are masters
    $kube_master_instances = $num_instances == 1 ? $num_instances : ($num_instances - 1)
    $local_release_dir = "/vagrant/temp"
    
    host_vars = {}
    
    if File.exist?(CONFIG)
      require CONFIG
    end
    
    # All nodes are kube nodes
    $kube_node_instances = $num_instances
    
    $box = SUPPORTED_OS[$os][:box]
    # if $inventory is not set, try to use example
    $inventory = File.join(File.dirname(__FILE__), "inventory") if ! $inventory
    
    # if $inventory has a hosts file use it, otherwise copy over vars etc
    # to where vagrant expects dynamic inventory to be.
    if ! File.exist?(File.join(File.dirname($inventory), "hosts"))
      $vagrant_ansible = File.join(File.dirname(__FILE__), ".vagrant",
                           "provisioners", "ansible")
      FileUtils.mkdir_p($vagrant_ansible) if ! File.exist?($vagrant_ansible)
      if ! File.exist?(File.join($vagrant_ansible,"inventory"))
        FileUtils.ln_s($inventory, $vagrant_ansible)
      end
    end
    
    if Vagrant.has_plugin?("vagrant-proxyconf")
        $no_proxy = ENV['NO_PROXY'] || ENV['no_proxy'] || "127.0.0.1,localhost"
        (1..$num_instances).each do |i|
            $no_proxy += ",#{$subnet}.#{i+100}"
        end
    end
    
    Vagrant.configure("2") do |config|
      # always use Vagrants insecure key
      config.ssh.insert_key = false
      config.vm.box = $box