pouta.csc.fi

Using and operating an OpenStack IaaS

Peter Jenkins

Poll

Show of hands

Used a virtual machine?

Used IaaS?

Heard of CSC?

Heard of Pouta?

  • Company is 41 years old
  • FUNET, supercomputers, data archives, datacenters
  • Cloud (IaaS) services for 3 years
  • Now providing general public cloud: Pouta
  • OpenStack based cloud. Hosted in Kajaani, Finland
  • Focus on high performance hardware

Demo

https://pouta.csc.fi

https://sui.csc.fi

Nice demo?

  • Is it reliable?
    • It's quite reliable, but no service can deliver 100% uptime
  • How do you recover from inevitable faliures?
  • Backups? Have you tested recovery?
  • Would you recover or rebuild?

Ansible: create an instance


---
- name: Pouta ansible demo
  hosts: localhost
  gather_facts: false

  vars:
    pouta_username: "{{ lookup('env','OS_USERNAME') }}"
    pouta_password: "{{ lookup('env','OS_PASSWORD') }}"
    tenant_name: "{{ lookup('env','OS_TENANT_NAME') }}"
    auth_url: "{{ lookup('env','OS_AUTH_URL') }}"

    pouta_tiny: 1a0f1143-47b5-4e8a-abda-eba52ae3c5b9
    pouta_centos65: 62f023f2-0983-41ba-8dc4-59b9d5cd32d1

    # These will need changing.
    demo_key: demo
    demo_security_groups: default,demo
    demo_floating_ip: 86.50.168.144
    demo_network: 09c9a0ff-72aa-4172-ae16-4fa8d738b15e

  tasks:
    - name: Create a virtual machine
      nova_compute:
        state: present
        name: pouta-demo
        login_username: "{{ pouta_username }}"
        login_password: "{{ pouta_password }}"
        login_tenant_name: "{{ tenant_name }}"
        auth_url: "{{ auth_url }}"
        image_id: "{{ pouta_centos65 }}"
        key_name: "{{ demo_key }}"
        flavor_id: "{{ pouta_tiny }}"
        security_groups: "{{ demo_security_groups }}"
        nics:
          - net-id: "{{ demo_network }}"
        floating_ips:
          - "{{ demo_floating_ip }}"
		

Ansible: Configure a web server


---
- name: Configure demo instance to be a webserver
  hosts: demo
  remote_user: cloud-user
  sudo: yes

  vars:
    demo_photo: kajaani.jpg
    demo_greeting: "Hello from Kajaani!"

  tasks:
   - name: Install a webserver
     yum: name=httpd state=present

   - name: Deploy demo web page
     template: src=templates/demo.html.j2 dest=/var/www/html/index.html owner=apache group=apache mode=0644

   - name: Copy a picture of Kajaani
     copy: src=resources/kajaani.jpg dest=/var/www/html/kajaani.jpg owner=apache group=apache mode=0644

   - name: Configure firewall
     template: src=templates/iptables.j2 dest=/etc/sysconfig/iptables owner=root group=root mode=0600
     notify:
       - reload iptables

   - name: Start apache
     service: name=httpd state=started enabled=yes

  handlers:
    - name: reload iptables
      service: name=iptables state=reloaded
		

view recording

End

Peter Jenkins


Twitter: @peterjenkins

Email: peter.jenkins@csc.fi

Ansible demo on github

This presentation

Create PDF version