/srv/irclogs.ubuntu.com/2015/02/27/#cloud-init.txt

faizalHi14:24
faizalAny one online14:25
faizalNeed a help14:25
strikovfaizal: Just ask. You'll get the answer (sooner or later) if someone knows it :)14:27
faizalOk14:27
faizalWe are using cloud init to create users in all our servers. .I have written the cloud config script and uploaded it to s3. ..then I wrote a wrapper shell script which will download the cloud config script from the s3 and will run the command "cloudinit init "14:31
faizalOur plan is to put this wrapper script in cron job and run every 30 min14:32
faizalSo if we want to add a user we will just edit the cloud config script and upload to s314:32
faizalThe problem I am facing is14:33
faizalWhen I run the script manually it is working fine14:33
faizalBut from cron job it is showing some error14:34
Odd_Blokefaizal: Can you pastebin the error somewhere?14:34
faizalWhere can I paste14:36
Odd_Blokefaizal: http://paste.ubuntu.com/14:36
Odd_Blokefaizal: (It's worth noting that cloud-init is designed to run when initialising a server, it's not really intended for this use case.)14:36
Odd_BlokeBut I'm happy to see if I can unblock you.14:36
faizalPasted14:38
Odd_Blokefaizal: You need to give us the link. :)14:38
faizal1044949214:38
faizalCan you see14:39
Odd_Blokefaizal: I can; in future just put the whole URL in the channel. :)14:40
Odd_Blokefaizal: And could you also paste your configuration?14:40
faizalOk14:40
faizalhttp://paste.ubuntu.com/10449576/14:44
Odd_Blokefaizal: Which user was failing to create?14:45
faizalWhen i run the command manually the user is getting created14:46
faizalBut from crontab it Is showing error14:47
faizalIt is not creating any user when running from cronjob14:49
Odd_Blokefaizal: Sorry, let me rephrase: all of the users in that configuration have already been created, so I'm not sure what in the configuration is causing failure.14:50
faizalI added a new user named "newuser" in the cloud config and ran the script from cronjob14:52
faizalThat newuser is not getting created when running from cronjob but is getting created when running manually14:53
Odd_Blokefaizal: Oh, you know what, this is probably a PATH issue.14:53
Odd_Blokefaizal: You'll have useradd in your PATH when you run it manually, but PATH won't be set in cron.14:54
faizalohh14:54
faizalSo how to fix14:55
faizalAny clue14:55
Odd_Blokefaizal: Set PATH in your crontab.14:56
faizalCan you tell me how. ..I  am just a beginner in Linux14:57
faizalGot it15:02
faizalThanks odd_bloke15:02
faizalIts working fine now15:02
Odd_Blokefaizal: :)15:03
faizalYou saved my weekend15:03
Odd_Blokefaizal: You might want to look at configuration management software rather than cloud-init for this sort of ongoing usecase.15:03
Odd_Blokefaizal: But I'm glad I could help. :)15:03
faizalYeah15:03
larsksOdd_Bloke++ :)15:03
faizalThis was a task from my manger and I am a new joinee15:04
faizalYou saved me15:04
faizal:-)15:05
smoserwell, as faizal has quit, it doens't help so much, but with cloud-init 2.0 we do want to have some mechanism for accomplishing what he wants.15:24
Odd_Blokesmoser: Presumably we'd want to be able to do it against a cloud's metadata source.15:25
Odd_Bloke(Rather than an arbitrary source, like faizal was using)15:26
smoserone way or another, information in some format would get to cloud-init and it would act on it.15:31
smoseri odnt think s3 is terrible, its a datastore, and can be addressed over https also.15:31
smoserso : cloud-init set-config https://foo.bar/wark15:32
smoserdoesn't seem so bad.15:32
smoserbut it is treating cloud-init like puppet in a lot of ways.15:32
smoserand i'm not so sure how far down this hole we'll go15:32
Odd_BlokeYeah, that would be my concern.15:43
harmwmy god, the Horizon spice console is looking horrible19:54
harmw:p19:54
harmwsmoser: was cirros building on 14.04, or still at 12?20:45
smoseri think 0.3 builds on 12.0420:45
harmwhm hm20:45
harmwok20:45
smoserbut i think i mvoed it to 14.04 in a 0.4 branch20:45
harmwI want to setup a new builvm, to get back to playing with it a littl20:46
harmwand as much as I'd like to play in docker, I'm going the qemu-way first :p20:46
smoseri think i'd go from lp:~smoser/cirros/buildroot-upgrade20:48
harmwah yeas, I was looking for that20:48
harmwand that builds on 14?20:48
harmwsmoser: wasn't there some magic just-build-the-damn-thing script?21:13
harmw(or did I create that myself, once)21:13
smoserlooking21:17
smoserhttp://bazaar.launchpad.net/~smoser/cirros/buildroot-upgrade/view/head:/doc/create-release.txt21:17
harmwlooking that,didn't you make  build-release or something?21:18
harmwoh21:18
harmwstupid 21:19
harmwthats actually being refrenced from inside that .txt21:19
harmwVER=0.3.3 && ./bin/build-release $VER 2>&1 | tee build-$VER.log21:23
harmwok21:24
smoserright.21:24
harmwhm, what's this... the vm is suffering from bitrot, so it seems21:24
smoserthe vm ?21:25
harmwinstance21:25
smoseryou just launch new ones all the time :)21:25
harmwno no, I have one ubuntu 1404 instance :)21:26
harmwand it's corrupting my downloads21:26
harmwhm, mtu 1450 seems to go better (instead of 1400)21:28
harmwsmoser: you have access to some PPC64 hardware right?21:33
harmwthats IBM PowerPC, right?21:33
smoseri do, yeah.21:33
smoserhttps://code.launchpad.net/~smoser/cirros/powerpc at one point was close.21:34
harmwwe have Power6 and 7 at work21:34
harmwwould it be conventient to have access to either one of those archs to build, say, cirros?21:35
smoserwell, cirros is cross-building.21:40
smoserso it would build on x86_64 is fine.21:40
smoseri think that both of those arches should support 'ppc64 kernel'21:40
smoserat somepoint i'd like to have a ppc64el one also, and that would only run on power821:41
harmwok21:41
harmwbut those are all crosscompiled21:42
smoserright. buildroot is always crosscompile21:56
smoserso from a build perspective, powerX are not terribly useful21:57
smoserbut for testing they are21:57
harmwyup21:57
smoseri got to run. later man. have fun.22:01
harmw:)22:01

Generated by irclog2html.py 2.7 by Marius Gedminas - find it at mg.pov.lt!