LinuxMCE Forums

General => Users => Topic started by: klovell on July 06, 2012, 11:07:13 pm

Title: Cloud intergration
Post by: klovell on July 06, 2012, 11:07:13 pm
Hello,

First, this is a real post, I’m NOT a bot!  Although that's exactly what a bot would say...

I did a very quick search and nothing came up so I'm posting.  I'm just sharing a open source software that I just come across that you all will LOVE! Owncloud!! I have it running in a VM and as a linuxMCE/Dianemo user this would make a perfect integration into LinuxMCE or Dianemo.  It's probably something that should make it onto a feature list for a future release.  LinuxMCE and Dianemo both already (as far as I know) have all the minimum requirements to run it so just download, extract it to the www folder and configure it.  In theory it should live and integrate just fine into LinuxMCE/Dianemo.  To really make it sexy, you should modify the code of Owncloud or MCE so they use the same data structure.  As a user of both systems I don't see why you couldn't just use symlinks for the OWNcloud data directory to get the job done.  Also since both systems will be using the same database and owncloud is PHP based it should be really easy to intergrate the user setup process into MCE (providing you know PHP... I couldn't do it).

I'm not looking for help implementing this, I already have a rock solid stable owncloud system and I'm not going to mess with it.  I've been using it for a few months now and from day one I thought this would be an awesome addition to MCE, Every day I believe more and more that this as feature you all absolutely will want!!

Once you check out the feature list and/or take owncloud for a spin I know you'll love it and agree so have fun.  Google owncloud for more information.  I do not work for or represent owncloud. I use it, I use linuxMCE and Dianemo, and I see an untapped potential.

Title: Re: Cloud intergration
Post by: JaseP on July 07, 2012, 12:09:05 am
It shouldn't be hard to create a LinuxMCE software device for this, that launches a web browser instance for this. It's a web-app compatible software package. I don't even think you'd need to integrate the databases, just give Owncloud the proper permissions to access/alter files, and switch it over to using LinuxMCE's player devices instead of Owncloud's default ones...

This really does something a bit different from LinuxMCE. It's more a personal file storage system than anything more along the lines of what LinuxMCE does. It's kinda like a personal Google Drive, more than anything else. Yes, there are areas where LinuxMCE could benefit from its features, but more as a plugin to the normal LinuxMCE use case, than any kind of major re-work any merger might require.
Title: Re: Cloud intergration
Post by: tschak909 on July 07, 2012, 01:02:02 am
Cool. code it. We'll help with support.

-Thom
Title: Re: Cloud intergration
Post by: tschak909 on July 07, 2012, 01:08:13 am
and I do mean that in the most pragmatic way possible... A lot of us devs are strapped for time as we work on different parts of the system...

BUT, we will bend over backwards to answer intelligent questions about the system, and its inner workings.

Those who have done development work know that I am true to my word here, I bend over backwards for those who help.

So...

Figure out how far you want to integrate this in,
do the research as to what would need to be done to make it happen OUTSIDE of LinuxMCE,
then, talk to US and we'll tell you how to make it PART of LinuxMCE.

This is the most efficient way to get new features in that we want.

-Thom
Title: Re: Cloud intergration
Post by: JaseP on July 07, 2012, 01:57:54 am
I'll take a look at Owncloud,... I was going to look into setting up very basic integration with Google+ services, like mail and Google Talk/Voice, eventually anyway,... and the kind of thing I responded to klovell about is only one extra layer of stuff...

Basically, I want to explore having the system eventually be able to do some things like push driving directions to a phone or tablet based on a scheduled event, or reach out and send reminders via email or SMS... That's a long way off... But playing with Owncloud is a step in that direction.

For now, I'll just look at getting it to run on the core and seeing if I can use a lightweight browser, like Midori, to launch into the web client of the thing from a LinuxMCE menu item... That'll be a decent start. Hopefully, it's SQL backend is compatible with the version running on LinuxMCE 10.04.
Title: Re: Cloud intergration
Post by: tschak909 on July 07, 2012, 02:08:21 am
We do have a DCE_Browser in the source tree that needs to be finished. This is a web browser with no UI intended to be used by Orbiter.

-Thom
Title: Re: Cloud intergration
Post by: golgoj4 on July 07, 2012, 02:12:45 am
We do have a DCE_Browser in the source tree that needs to be finished. This is a web browser with no UI intended to be used by Orbiter.

-Thom

speaking of which, who do i have to %(#! to get a screen made for it. Thats literally what the hold up is at the moment. Im happy to do the rest of the work, but i think all devs here are well aware of how sqlcvs and i get along.

Cloud integration sounds cool. as thom said, people who ask get answers. I think he gave me a semester of c++ training in #dev when i started qOrbiter.
Title: Re: Cloud intergration
Post by: tschak909 on July 07, 2012, 02:15:09 am
Oh yes, and the DCE_Browser uses WebKit...

-Thom
Title: Re: Cloud intergration
Post by: JaseP on July 07, 2012, 02:33:56 am
We do have a DCE_Browser in the source tree that needs to be finished. This is a web browser with no UI intended to be used by Orbiter.

-Thom

Thanks, but the no UI part scares me a little,... especially if Owncloudnturns out to have not "exit" function. And I really loathe the on-screen keyboard and 10-foot UI exit buttons... No offense to whomever originally coded them or anything, but they're fugly.
Title: Re: Cloud intergration
Post by: tschak909 on July 07, 2012, 06:09:20 am
Sometimes I seriously want to throttle you. :)

The reason there is no UI is because ORBITER would provide the UI.

Seriously, when are you guys going to STOP using duct tape and ACTUALLY LEARN HOW TO MAKE PROPER NEW FEATURES FOR THE SYSTEM? I'm getting very tired of this half assed shit.

For myself, I put in the time to study how this system actually works and why, because I wanted to add features to it, instead of gabbing on about "oh wouldn't it be cool if this were...", and so did golgoj4.

Here's the difference, he put in the work, and asked me questions, I answered them, he learned, and now, he is single handedly writing a replacement for Orbiter roughly 1 year later. JUST THINK OF WHAT YOU COULD ACTUALLY DO, IF YOU FUCKING DID IT, INSTEAD OF TALKING ABOUT DOING IT!!!!!!!!!

or l3top, who has done more plumbing work to make this system easy to install than just about anyone else in the last four years in the last 6 months alone! why is it this way? BECAUSE HE GOT TIRED OF JUST TALKING ABOUT IT AND FUCKING DID IT!

STOP JUST TALKING AND ACTUALLY DO IT!

oh? and you think the on screen keyboard is fugly? fine. ok. SO FIX IT. EITHER DO SOMETHING OR JUST GO THE FUCK AWAY!

-Thom
Title: Re: Cloud intergration
Post by: klovell on July 07, 2012, 06:46:06 am
For this entire post MCE refers to LinuxMCE/Dianemo.

I guess you can integrate Owncloud however you want but I had a different idea in mind.  Since MCE provides all users with a “stomping ground” for all types of data for use inside the house and Owncloud provides users with a “stomping ground” for all types of data remotely, to me it made sense to combine the two.  The other day I was at the playground with my son and he was being extra cute so I started to record him with my phone.  My phone automatically uploaded the video to owncloud while I was recording it.  I then used my droid orbiter to play the video for my wife on the living room TV while I was still at the playground.  I don’t care who you are that right there is cool shit.  When I download music from google play to my phone it’s automatically, in real time, available for me to play in any room of my house.   

To add more to this I also use subsonic, Another application that should be integrated into MCE.  100% doable, and there is an app in owncloud for subsonic so you can use subsonic from owncloud.  Basically any movie (have to donate to stream video) or song I can play in MCE I can stream to my phone or to any pc (inside or outside the house).  That’s the type of integration I’m talking about. 
MCE allows you to interact with multiple systems in the home from one location (any orbiter).  Owncloud wraps up all your web services into one package.  The attached screen shot is what our owncloud looks like.  Between owncloud and subsonic I can’t tell you enough how well it completes my system.  I love my system and I personally like that it’s on a separate physical box than MCE so I can take down one without affecting the other.  For these reasons I personally wouldn’t use it on MCE even if it was integrated so I have no way to help dev or test.  Not to be a jerk but I don’t need it integrated into MCE but I’m confident that you all will want it integrated into MCE.  I really hope someone can grab this and run with it, trust me guys, MCE needs this! 

(https://cloud.lovellfam.net/media/public.php?service=files&token=f7e314d08e5f556fd02ec5d4cd0e8cf50064f048&file=/Web%20shares/Forums/Images/linuxmce-owncloud.png)
Title: Re: Cloud intergration
Post by: klovell on July 07, 2012, 06:51:24 am
It would be very easy to use Owncloud alongside MCE but I think it should be integrated.  If you want to test it I would suggest using SQLlite vs mysql for Owncloud.  This way you’re not playing around with the MCE database and incase MCE doesn’t use 5.x which is the minimum version required you’re covered.    Also, I’m not sure about the new version of Owncloud but the second to last release has a bug where if you manually add files and folders to the user data folder without using owncloud it caused problems displaying data on the web.  SQLite doesn’t have that problem.

So:
Get Sqlite on your core.

Extract owncloud to the www dir, set the permissions as per the owncloud website.

When you access the site for the first time select SQlite and use the same MCE user folders as the data folder.  This is where symlinks come in.  From my understanding of MCE, you’ll have to create a “oc-data” folder (literally just made that name up, call it whatever you want), in that folder you’ll see all the folders for your MCE users.  You’ll have to use the names folders and not the user_1 folder.

When you create your owncloud users make sure the names are exactly the same as MCE users.   Both MCE and owncloud name the users data folders the same so it’s easy to trick both systems to use the same folder.  Owncloud doesn’t “manage” the data the way MCE does so you shouldn’t run into corruption issues (I haven’t).

Do yourself a favor, don't be cheap, spend the $69 per year and get an SSL cert.  If that's a bank breaker you probably shouldn't be worried about home automation anyway. 
Title: Re: Cloud intergration
Post by: davegravy on July 07, 2012, 06:55:00 am
Off-topic, but I just want to know if the censored word in your image is "porn" or "sperm"
Title: Re: Cloud intergration
Post by: klovell on July 07, 2012, 07:04:36 am
Off-topic, but I just want to know if the censored word in your image is "porn" or "sperm"

HAHA, It's the name of my financial institution, but let's go with porn.  ;D
Title: Re: Cloud intergration
Post by: tschak909 on July 07, 2012, 07:10:03 am
Seriously, are none of you listening to what I'm saying?

LOOK AT OUR EXISTING ARCHITECTURE, UNDERSTAND IT, THEN EXTEND IT TO FIT THE FEATURES WANTED, INSTEAD OF DUCT TAPING OVER THEM!

-Thom
Title: Re: Cloud intergration
Post by: klovell on July 07, 2012, 07:36:13 am
Seriously, are none of you listening to what I'm saying?

LOOK AT OUR EXISTING ARCHITECTURE, UNDERSTAND IT, THEN EXTEND IT TO FIT THE FEATURES WANTED, INSTEAD OF DUCT TAPING OVER THEM!

-Thom

Hey man I understand what you're saying.  You need to know OC and MCE in order to integrate them.  I just provided a way to test OC so you can integrate. 

Like I said, I already have this running.  It works awesome for me. If I had to create a Pros and Cons list for MCE, the fact that all the systems that make MCE is on one box and is almost impossible to seperate will be number one on my CON list.  It's not a dig at MCE, I 100 million percent understand why all the systems are balled into one appliance but I can afford mutiple server, I couldn't care less about the electric bill, and I'm used to managing multiple servers in an environment.  In my setup Owncloud, MCE, and my nas are on seperate boxes and I wouldn't have it any other way.  If it's a band aid, so be it.  I can take down MCE for a day or two with out losing cloud access and vise versa.  For that matter my nas is clustered so I can even take down the nas with out affecting MCE or the Cloud.

However, in keeping with the nature of MCE and the way the vast majority of you use it, owncloud seems like a perfect addidion to the family.  I'm mearly making a suggestion here, I could have kept it to myself but I really think it would be a great asset to MCE.  You couldn't possible expect me to dissmantle whats working for me to help build something I wont use. 
Title: Re: Cloud intergration
Post by: Marie.O on July 07, 2012, 09:28:19 am
klovell,

well said.
Title: Re: Cloud intergration
Post by: JaseP on July 08, 2012, 05:24:47 pm
Seriously, are none of you listening to what I'm saying?

LOOK AT OUR EXISTING ARCHITECTURE, UNDERSTAND IT, THEN EXTEND IT TO FIT THE FEATURES WANTED, INSTEAD OF DUCT TAPING OVER THEM!

-Thom

Dude,... Baby steps,... seriously... You (meaning me or another non-developer, not you personally) can't just jump in and throw something in there without understanding it first. Klovell has Owncloud working, separately, but I've never played with the thing,... I need to experiment with it. I haven't had time.

And, I've asked about how I might ditch the onscreen keyboard, and have gotten no response (seriously, absolutely zero,... crickets)...

There is nothing in the wiki that describes the system architecture in any meaningful way. It's a bit like trying to play chess without anyone explaining how the pieces move. And every time someone asks a question people jump down their throats.

Plus, klovell has got a point about separable systems. It's the very reason I use a MCV Vera versus using LinuxMCE to do the Z-wave dirty work. I personally would rather have Owncloud running on the Core, but his thing works for him...

On top of all that, I've got all my normal obligations, plus a father in the hospital, which I'm sure you can relate to... So, I haven't had time to schedule a bathroom break, let alone work on any of my projects.

I'll look into getting this thing running, but it'll take time (I don't even have my ATA set up yet). Anyone is welcome to beat me to the punch ...
Title: Re: Cloud intergration
Post by: JaseP on July 08, 2012, 05:49:48 pm


Will any of the following packages conflict with anything that LinuxMCE is running??:

   apache2 php5 php5-json php-xml php-mbstring php5-zip php5-gd

and/or:

   php5-sqlite curl libcurl3 libcurl3-dev php5-curl php-pdo

The first are packages required by Owncloud. The second are recommended packages.
Title: Re: Cloud intergration
Post by: klovell on July 09, 2012, 02:51:29 am

Will any of the following packages conflict with anything that LinuxMCE is running??:

   apache2 php5 php5-json php-xml php-mbstring php5-zip php5-gd

and/or:

   php5-sqlite curl libcurl3 libcurl3-dev php5-curl php-pdo

The first are packages required by Owncloud. The second are recommended packages.

Create a phpinfo.php page  to see if LinuxMCE already meets the minimum requirements.  I ran it on my Dianemo system and it looks like it's already capable of accepting owncloud.  If linux MYSQL is like windows mysql (I can't see why it would be different), I don't see why the 2 db's couldn't co-exist.  When using mysql you can pick the name and path of the db during initial setup.  As I said before though, I would use SQlite for testing just so I don't break MCE.

Code: [Select]
<?php

// Show all information, defaults to INFO_ALL
phpinfo();

?>



I'm willing to help i'm just not going to blow away my system to do it so my help will be limited.  From configuring this and using it for some time i've already identified a few caveats and workarounds that will have to be addressed when integration time comes.  I don't think they're huge issues since who ever does the integration would be touching these areas of oc anyway.  For example, the web interface pulls in hidden files, so to reduce clutter you'll want to apply filters when the site scans the data folder.  From what I gather that should be pretty easy for anyone who knows php. 

Let me know if you have any questions about OC and how i'm using it.  Send me a PM, i'm not on the forums much but I get emails when people PM me.