Tuesday, May 3, 2016

#498 Installing Puppet on IaaS



I download puppet enterprise from
here

I then copy the file across to my vm via pscp.

The format of the cmd is as follows -
pscp -i "C\yourPrivateKeyDirectory\yourPrivateKey.ppk" puppet-enterprise-2016.1.1-el-6-x86_64.tar.gz opc:YourVMIPAddress/yourTargetDirectory/yourTargetFile

Now I extract the tarball -












I now install - sudo ./puppet-enterprise-installer











I get the following message -







I create the following security application to open up port 3000 and
8140 -







Here is my Security List -




My Compute Service instance is added to this security list -









I now create the 2 security rules -

























and similar for ncpuppet8140.





I point my browser to my https://MyVM:3000

























Click Let's get started!

Then choose Monolithic








































Get a cup of coffee or chamomile tea...












Login









































Monday, May 2, 2016

#497 ICS --> Facebook adapter

I do the required setup at developers.facebook.com














This step is documented here

I then create a connection in ICS based on the Facebook adapter.
I enter the required info -













And click Provide Consent.













You should then see the above message.

Now I create an Integration -

Note: You cannot drop the FB adapter as a source/trigger -

Connection with invoke as a role cannot be configured to trigger.Drag and drop a connection with role as trigger.

So now I drop it as a target/Invoke -






































Note the operations available.




















Thursday, April 28, 2016

#496 - IaaS / PaaS Partner Roundtable hits Warsaw

Great event and a magnificent location, affording great city views.

Great resonance from the participants, especially in respect of 
Public Cloud Machine.







































Public Cloud Machine whitepaper here




Wednesday, April 27, 2016

#495 IaaS - Deploying Docker on Oracle Compute Service



We all know docker - Build, Ship and run anywhere.
So how does this work with Oracle Compute Cloud Service?


Docker containers are essentially lightweight virtualized environments, containing everything you need to run your app.

Step 1 Install docker

Here I install docker on my vm.

Firstly, I update the yum repository.
More info on yum here

Make sure that you are UEK 4.x compatible.

If not, then update -

[ol6_UEKR4]
name=Latest Unbreakable Enterprise Kernel Release 4 for Oracle Linux $releasever ($basearch)
baseurl=http://public-yum.oracle.com/repo/OracleLinux/OL6/UEKR4/$basearch/
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-oracle
gpgcheck=1
enabled=1

[ol6_UEKR3_latest]
name=Latest Unbreakable Enterprise Kernel for Oracle Linux $releasever ($basearch)
baseurl=http://public-yum.oracle.com/repo/OracleLinux/OL6/UEKR3/latest/$basearch/
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-oracle
gpgcheck=1
enabled=0

[ol6_UEK_latest]
name=Latest Unbreakable Enterprise Kernel for Oracle Linux $releasever ($basearch)
baseurl=http://public-yum.oracle.com/repo/OracleLinux/OL6/UEK/latest/$basearch/
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-oracle
gpgcheck=1
enabled=0


copy the above to your /etc/yu.repos.d/public-yum-ol6.repo file

then run sudo yum update

Once this is complete, then install docker -

sudo yum install docker-engine









Step 2 -Start docker

sudo service docker start






do the sanity test -
sudo docker run hello-world


















Now, let's run an Ubuntu container -

docker run -it ubuntu bash
















docker containers are stored here -






Good article on getting started with docker available here


Thursday, April 21, 2016

#494 IaaS - Rapid provisioning of vms thru Orchestration




What is Orchestration?

From the Oracle docs (Bold/Italic) -

An orchestration defines the attributes and interdependencies of a collection of compute, networking, and storage resources in Oracle Compute Cloud Service. You can use orchestrations to automate the provisioning and lifecycle operations of an entire virtual compute topology.
For example, you can use orchestrations to create and manage a collection of instances hosting a multitiered application stack with all the necessary networking, storage, and security settings.

Some Terminology up front

oplan - Object plan, the primary building block of an orchestration. 
An orchestration can have up to 10 oplans.

obj_typeAn object type refers to the Oracle Compute Cloud Service resource that you want to create. 

Here is the list of valid obj_types - 



objects - The objects attribute defines the properties or characteristics of the the Oracle Compute Cloud Service resource that you want to create, as specified by the obj_type attribute.

For example, if you want to create a storage volume, the obj_type would be storage/volume, and the objects would include size and bootable. If you want to create an instance, the obj_type would be launchplan, and the objects would include instances, along with instance-specific attributes, such as imagelist and shape.



You can create relationships between different oplans, e.g. one plan to create the instance, the other to create the storage volume.

Simple Example 

This simple example will have 2 parts -

  1. Instance Orchestration to manage my VM instance
  2. Volume Orchestration to manage storage volumes

From what I said earlier, would could also include a master that ties the other 2 together via a relationship.

So what does it look like?

Let's start with the volume orchestration -

I begin with a screenshot of the UI for creating Storage Volumes -



Here is the equivalent orchestration -

"description": "NiallC Simple orchestration plan for volume creation",
"name": "/Compute-YourIdentityDomain/yourUser/volumeCreation",
"oplans": [
{
"label": "NiallC-StorageVolumes",
"obj_type": "storage/volume",
"ha_policy": "monitor",
"objects": [
{
"name": "/Compute-YourIdentityDomain/yourUser/ncvol2",
"size": "2G",
"index": 1,
"properties":["/oracle/public/storage/default"]



Now, let's look at the instance orchestration -
Again, here is the creation UI -
















Here is the equivalent orchestration -

{
"description": "NiallC orchestration plan for instance creation",
"name": "/Compute-YourIdentityDomain/yourUser/instanceCreation",
"oplans": [
{
"label": "NiallCInstances",
"obj_type": "launchplan",
"ha_policy": "active",
"objects": [
{
"instances": [
{
"imagelist" : "/oracle/public/OL-6.6-20GB-x11-RD",
"label": "NC-Instance",
"storage_attachments": [
{
"index": 1,
"volume": "/Compute-YourIdentityDomain/yourUser/ncvol2"
}
],
"networking": {
"eth0": {
"seclists": [
"/Compute-usorclptsc52741/default/default"
],
"nat": "ippool:/oracle/public/ippool"
}
},
"shape": "oc3",
"sshkeys": [
"/Compute-YourIdentityDomain/yourUser/nc-pub-key"
]
}
]
}
]
}
]
}































I upload these  2 orchestrations and start the volumeCreation -



The status then changes to ready -


I check in the storage tab, my volume has been created.





I now start the instance orchestration -

















I check for the Instance and here it is -








Wednesday, April 20, 2016

#493 IaaS - Adding Storage Volumes to a running instance



We begin with a refresher -

A temporary, non-persistent storage volume is associated with your Compute Cloud instance on creation. Your instance boots from this nonpersistent storage volume.

What if you want to save applications or data on your instance?
Then you must create a persistent storage volume and attach it to your instance.
If necessary, you can also specify a bootable storage volume. Using a bootable storage volume
allows you to save any configurations made to your instance at OS level.
This allows you to delete from instance and create it again without losing your OS configurations.































Once created, we can attach it to one of our instances, from the previous post.




















Please note: 

The disk number you specify here determines the device name.

The disk attached at
index 1 is named /dev/xvdb,
the disk at index 2 is /dev/xvdc,
the disk at index 3 is /dev/xvdd, etc.







Now I ssh into my vm.















Note disk xvdc above.

Now I create a disk partition -

sudo fdisk /dev/xvdc
















I now create a file system - sudo mkfs -t ext3 /dev/xvdc1

Now mount - sudo mount -t ext3 /dev/xvdc1 /u01