[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: build-debian-cloud python version preview



On 1 August 2013 07:32, olivier sallou <olivier.sallou@gmail.com> wrote:
>
>
>
> 2013/7/31 Anders Ingemann <anders@ingemann.de>
>>
>> On 31 July 2013 11:23, olivier sallou <olivier.sallou@gmail.com> wrote:
>>>
>>>
>>>
>>>
>>> 2013/7/31 Anders Ingemann <anders@ingemann.de>
>>>>
>>>> On 31 July 2013 07:59, olivier sallou <olivier.sallou@gmail.com> wrote:
>>>>>
>>>>> What is your "rule" to decide what is in plugins and what is in
>>>>> providers tasks ?
>>>>>
>>>>> I'd like to add a task to install a list of packages provided by user
>>>>> in the manifest (2 things in fact, packages from Debian repo, and locally
>>>>> provided packages). Should I create a plugin or a new task in my provider?
>>>>>
>>>>> Thanks
>>>>>
>>>>> Olivier
>>>>
>>>>
>>>> I was planning to do something along those lines as well. This is
>>>> definitely a plugin, since it is not something that is required to get a
>>>> machine running.
>>>> It sounds like you need two plugins: One to install a list of packages
>>>> from the main repo (or a user provided repo) and one to install deb packages
>>>> directly from a given path, correct?
>>>
>>>
>>> I think so yes. I have already created a plugin to do so. So we put in
>>> plugins all that is not mandatory to get a "base" image running.
>>>
>>> Thanks
>>>
>>> Olivier
>>>
>>>
>>>
>>> --
>>>
>>> gpg key id: 4096R/326D8438  (keyring.debian.org)
>>>
>>> Key fingerprint = 5FB4 6F83 D3B9 5204 6335  D26D 78DC 68DB 326D 8438
>>
>>
>>
>> https://github.com/osallou/build-debian-cloud/commit/237069b9416e0568ed1beab39fe222f9f3b5635b
>> Hah! Good use of my "library" functions. I am very open to suggestions on
>> that part. I think sed_i() is really useful. Any clue on how to make the
>> rwxr_xr_x part less.. verbose?
>
> Well, it is fine for me.
>
> We definitely need however to put common tasks together. Indeed, plugins
> need to set *after* (or before) elements to be placed in the workflow.
> If I want to be placed for example  after GenerateLocale,I have to import:
>
> from providers.ec2.tasks.locale import GenerateLocale
>
> This makes the plugin work only for one provider.
>
>
>
> --
>
> gpg key id: 4096R/326D8438  (keyring.debian.org)
>
> Key fingerprint = 5FB4 6F83 D3B9 5204 6335  D26D 78DC 68DB 326D 8438

And one more time for the mailing list as well ^^

> This makes the plugin work only for one provider.
Ah, no you would just add the task from the other provider as well.
Tasks in the 'after' and 'before' properties are ignored if they are
not added to the tasklist, so you can simply write:
after=[providers.ec2.tasks.locale.GenerateLocale,
providers.one.tasks.locale.GenerateLocale]

I am not sure whether a 'requiredAfter' is needed.


Reply to: