1. 27 Apr, 2015 2 commits
    • Kirill Smelkov's avatar
      helloworld: Turn it into real web-service · 7cd2f953
      Kirill Smelkov authored
      Implement a simple "hello world" web server in Python and hook it into
      SlapOS infrastructure, so that newcomers can see how to implement
      SlapOS services:
      
          - start service from under etc/service/
          - add promise for service monitoring
          - publish connection url
      
      TODO IPv4 frontend
      ------------------
      
      For now the service is only accessible via IPv6, because SlapOS provides
      an unique ipv6-address to every computer partition, and provided IPv4
      addresses have non-global scope and can be used only for organizing
      internal subservices.
      
      The way we handle IPv4 publish - is through explicit additional IPv4
      frontend - TODO add example how to do it.
      
      TODO monitoring
      ---------------
      
      Currently in SlapOS for a service in order to be monitorable, the
      service needs to explicitly extend from monitoring stack:
      
          http://git.erp5.org/gitweb/slapos.git/blob/HEAD:/stack/monitor/README.txt
      
      TODO - add example how to do it.
      
      Cc: Jérome Perrin <jerome@nexedi.com>
      7cd2f953
    • Kirill Smelkov's avatar
      helloworld: Listening on partition IPv4 address makes sense only for internal services · 85e6a1da
      Kirill Smelkov authored
      Because partition IPv4 address(es) are not global ones - i.e. 10.0.12.57
      - so we cannot expose a service through them to the world without
      additional frontent proxy.
      
      So let's leave only IPv6 listening address in the example.
      
      Cc: Jérome Perrin <jerome@nexedi.com>
      85e6a1da
  2. 26 Apr, 2015 1 commit
    • Kirill Smelkov's avatar
      Revert "hello-world: add IP examples" · 05bfbb9d
      Kirill Smelkov authored
      This reverts the essence of commit 854e4766:
      
      Changing there
      
          ${instance-parameter:ipv6-random}
      
      to
      
          ${instance-parameter:global-ipv6}
      
      was wrong - slapos.cookbook:slapconfiguration recipe, which is leveraged
      by [instance-parameter] section does not define global-ipv6:
      
          http://git.erp5.org/gitweb/slapos.git/blob/HEAD:/slapos/recipe/slapconfiguration.py?js=1#l70
      
      - only ipv6 as "Set of IPv6 addresses (of partition)" and ipv6-random
      "One of the IPv6 addresses".
      
      Trying to instantiate a helloworld SR inside webrunner:
      
          ---- 8< ---- (instance.log)
          ...
          [2015-04-26 11:56:20,133] INFO Error: Referenced option does not exist: instance-parameter global-ipv6
          ...
      
      and the same error while instantiating helloworld SR without slaprunner
      under local slapproxy.
      
      ~~~~
      
      The global-ipv6 is helpfully injected by slapos.cookbook:softwaretype
      recipe into [slap-network-information] section:
      
          http://git.erp5.org/gitweb/slapos.git/blob/HEAD:/slapos/recipe/softwaretype.py?js=1#l164
      
      but unfortunately only if that slapos.cookbook:softwaretype recipe is
      activated - i.e. when we have several software types and we support switching
      between them, which is not the case for helloworld (and it's a pity that
      such fundamental network-configuration is only optionally provided by SlapOS).
      
      ~~~~
      
      So let's switch back to ${instance-parameter:ipv6-random} - this way
      helloworld instance can be instantiated again.
      
      Cc: Jérome Perrin <jerome@nexedi.com>
      05bfbb9d
  3. 23 Apr, 2015 6 commits
  4. 22 Apr, 2015 1 commit
    • Alain Takoudjou's avatar
      kvm: can now accept parameters external-disk-format, cpu-options and numa · 2d79471e
      Alain Takoudjou authored
      kvm_run script can now create external disk with specified format (qcow2, raw, etc...)
      if kvm external disk is created it will never be replaced, even if user
      reduce the number of disk with parameter 'external-disk-number' or change the
      'external-disk-format' value. All created disk will be added to qemu run command.
      
      numa option can be used to create [fake] numa nodes and expose them to the guest
      OS instance. In this case it is important to know the host cpu topology and where
      the instance will be allocated.
      
      cpu-options are additional parameters like sockets=1,cores=5,threads=1
      in this case if cpu-count parameter is 1 qemu options will be:
      -smp 1,sockets=1,cores=5,threads=1
      2d79471e
  5. 20 Apr, 2015 9 commits
  6. 18 Apr, 2015 1 commit
  7. 17 Apr, 2015 4 commits
  8. 16 Apr, 2015 3 commits
  9. 15 Apr, 2015 3 commits
  10. 14 Apr, 2015 3 commits
  11. 10 Apr, 2015 7 commits