User Tools

Site Tools


juju-centos

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
juju-centos [2015/05/05 23:03]
bteleaga
juju-centos [2015/05/13 15:34] (current)
Line 1: Line 1:
 ======= Using Juju and MaaS with CentOS ======= ======= Using Juju and MaaS with CentOS =======
  
-This page will describe how you can test running CentOS under Juju. This has been just merged so full support is not yet hereSome of the known issues are: no support for yum mirrors/proxiesno mongo tools(which implies no backups amongst other things). However most of the functionality of Juju should be here.+Initial support has landed in Juju's master branch for CentOS 7 and is planned to be released with version 1.24. Keep in mind that this is an initial release and there are slight differences from using Juju with Ubuntu, which will be discussed later on.
  
-First off, to get started you should follow our other two tutorials:+To start off, you should follow our previous two tutorials on setting up our testing environment:
  
-http://wiki.cloudbase.it/maas+[[http://wiki.cloudbase.it/maas|MaaS installation guide]]
  
-http://wiki.cloudbase.it/juju+[[http://wiki.cloudbase.it/juju|Juju installation guide]]
  
-This should give you a ready to go MaaS and Juju environment. Make sure you can bootstrap a trusty state machine before following the next steps to make debugging easier.+This will give you a ready to go MaaS and Juju environment. Make sure you can bootstrap a trusty state machine before following the next steps to make debugging easier.
  
-  * Now we need to prepare a CentOS image. Get the maas-image-builder+===== Generating MaaS images for CentOS 7 =====
  
-  $ bzr branch lp:maas-image-builder + There is a nice project made available by Canonical that will facilitate the creation of a new CentOS image compatible with MaaS. We are using MaaS to test this, because it's the easiest way to have a locally working testing environment. Due to limited support for container-based CentOS deplyments, we cannot use the local provider yet. More details on that will be provided as they arise.
-  $ cd maas-image-builder +
-  # python setup.py install+
  
-  * You may need to change the python-stevedore dependency to stevedore in setup.py for the installation to work. Once the image builder is installed, you need to make sure kvm works on the ubuntu machine that you're building the image on. Have a look at https://help.ubuntu.com/community/KVM/Installation for a guide on checking if it's enabled and installing it if necessary.+Lets get a local copy of maas-iumagebuilder:
  
-  * Run the command for creating the image+  bzr branch lp:maas-image-builder 
 +  cd maas-image-builder 
 +  python setup.py install
  
-:!: This will probably take a very long time. You can do the rest of the juju configuration in the meantimeHowever, before bootstrapping a node with CentOS, the image should be uploaded to MaaS.+You may need to change the python-stevedore dependency to stevedore in setup.py for the installation to workOnce the image builder is installed, you need to make sure KVM works on the Ubuntu machine that you're building the image on. Have a look at [[https://help.ubuntu.com/community/KVM/Installation|this guide]] for instructions on checking if it's enabled and installing it if necessary.
  
-   # maas-image-builder -o centos7-amd64-root-tgz centos --edition 7+  * Run the command for creating the image:
  
-  * Import the image in MaaS+  maas-image-builder -o centos7-amd64-root-tgz centos --edition 7
  
-  # maas <session-name> boot-resources create title=centos7 name=centos7 architecture=amd64/generic content@=centos7-amd64-root-tgz+:!: This will probably take a very long time. You can pass on to configuring Juju, but make sure you **stop before** issuing the `juju boostrap` command and come back here to upload the image to MaaS.
  
-  * While the image is uploading, you can create the tools and make them available to the MaaS machines. You do not need to create the trusty ones if they're already there.+  * Import the image in MaaS:
  
-  $ mkdir -p ~/.juju/tools/releases +  maas <session-name> boot-resources create title=centos7 name=centos7 architecture=amd64/generic content@=centos7-amd64-root-tgz
-  $ cd ~/.juju/tools/releases +
-  $ cp ~/golang/bin/jujud* . +
-  $ tar -czf juju-1.24-centos7-amd64.tgz jujud +
-  $ tar -czf juju-1.24-trusty-amd64.tgz jujud +
-  $ rm jujud+
  
-  * If you followed the previous tutorials you may have already generated the metadata. In that case there may be some bugs, so it is better to remove it first.+===== Create jujud agent tools =====
  
-  rm -rf ~/.juju/tools/streams+  * While the image is uploading, you can create the tools and make them available to the MaaS machines. You don't need to create the trusty ones if they're already there. 
 + 
 +  mkdir -p ~/.juju/tools/releases 
 +  cd ~/.juju/tools/releases 
 +  cp ~/golang/bin/jujud* . 
 +  tar -czf juju-1.24-centos7-amd64.tgz jujud 
 +  tar -czf juju-1.24-trusty-amd64.tgz jujud 
 +  rm jujud 
 + 
 +  * If you've followed our previous tutorial on installing Juju, you may have already run `juju-metadata generate-tools`. In that case, in order to avoid any issues, please remove the previously created metadata by running the following command: 
 + 
 +  rm -rf ~/.juju/tools/streams
  
   * Generate the metadata and make it available locally   * Generate the metadata and make it available locally
  
-  juju-metadata generate-tools +  juju-metadata generate-tools 
-  cp -r ~/.juju/tools /var/www/html +  cp -r ~/.juju/tools /var/www/html 
-  chmod -R 755 /var/www/html/tools+  chmod -R 755 /var/www/html/tools
      
 +===== Editing your environments.yaml =====
 +
  
   * Now you should edit the environments.yaml file in ~/.juju. Make maas the default provider. Then in the section for maas configuration set:   * Now you should edit the environments.yaml file in ~/.juju. Make maas the default provider. Then in the section for maas configuration set:
Line 66: Line 74:
   juju bootstrap   juju bootstrap
  
-  * Once this is complete you can deploy Juju charms on either Ubuntu, CentOS or Windows(provided you followed the previous tutorials fully). +  * Once this is complete you can deploy Juju charms on either Ubuntu, CentOS or Windows(provided you followed the previous tutorials fully). 
 + 
 +===== Limitations ===== 
 + 
 +While these issues are present in this initial release, we are working on remedying them as soon as possible. Some may take longer then others, but we do want to have 1:1 feature set on all supported platforms. 
 + 
 +  * no support for yum mirrors/proxies. At the moment the same mirror used for apt proxies is used for yum as well. 
 +  * no mongo tools(which implies no backups, amongst other inconveniences) 
juju-centos.1430856216.txt.gz · Last modified: 2015/05/05 23:03 by bteleaga