ebu / OSCIED

Open Source Cloud Infrastructure for Encoding and Distribution
Other
16 stars 2 forks source link

PlugIt: Transform.transform_task.apply_async a besion d'un user #84

Closed the-glu closed 11 years ago

the-glu commented 11 years ago

Actuellement, je fait un faux user. Il me faudrait une option de configuration avec une URL, histoire de pouvoir utiliser l'API plugit pour récupérer un user.

=> David: Tu peux me rajouter la dite option dans ton système de configuration ? Merci :)

davidfischer-ch commented 11 years ago

Please see comments of commit 997765014bf4979e175cf33f4e12e77635e96689

davidfischer-ch commented 11 years ago

What are the options you want in configuration ?

Please provide me with keys and values, for example auth_api_url = "http://big-brother.com/".

the-glu commented 11 years ago

PLUGIT_API_URL = 'http://127.0.0.1:5656/plugit/UGvmxwbDkHWnWUstvpwFRjwNTmCVeqjk/3/'

In prod. I will make an SSH tunnel as I use my local machine to work ^^

Can you show me how to get the value and how to change it ? Thanks !

davidfischer-ch commented 11 years ago

Ok, I will tell you this little story ...

Make charm aware of this option:

Charm config-changed hook must save option's value for orchestra daemon:

Charm may toggle standalone mode based on value of _plugit_apiurl

Ok, I will do it myself, please be patient.

davidfischer-ch commented 11 years ago

One question, is it PlugIt API or EBU-io ?

the-glu commented 11 years ago

PlugIt API

davidfischer-ch commented 11 years ago

It is not an easy task to update local_config.pkl of actually running orchestra. I may need to destroy oscied-orchestra service and re-deploy the new charm as I not yet implement upgrade hook !

Do you saved all you modifications into this repository ?

the-glu commented 11 years ago

Yes. Don't destroy the instance however ^^ (Or tell me so I can umount my mounts)

davidfischer-ch commented 11 years ago

Okay, but the loading of the config from local_config.pkl will fail at least if you do not mod it manually to add the good option, good luck !

the-glu commented 11 years ago

? If you need to destroy the instance do it, just tell me ^^

davidfischer-ch commented 11 years ago

The only concern is that : old OrchestraConfig -> local_config.pkl -> new OrchestraConfig = fail I will download local_config.pkl from the instance and mod it by myself.

Please, stop orchestra screen and let me play with for few minutes.

davidfischer-ch commented 11 years ago

Of course, send latest version of the code to the unit now.

davidfischer-ch commented 11 years ago

Ok, I hacked new_local_config.pkl.

You may stop orchestra, switch local_config.pkl <-> new_local_config.pkl, ensure latest version of the code and restart orchestra. Of course, you may need to cheat a little bit by hacking Orchestra config loading to set config.plugit_api_url = 'http://' manually [actions.py main()]

the-glu commented 11 years ago

Mokay. I see the new config value, but I didn't understand the rest, I let you add it correctly and will use config.plugit_api_url to dev :)

davidfischer-ch commented 11 years ago

Please read actions.py -> main() to check the hack.

the-glu commented 11 years ago

Should be ok now. I don't know why you pass the users to tasks, especialy if it's only to test if the user is valid.. I removed tests, in git and on publisher and transcoder server.

davidfischer-ch commented 11 years ago

Hello, that looks fine.