- Rundeck

Date: 06 June 2013

Server: , Channel: #rundeck

14:29:15 Kzim


16:24:41 Alex-SF

hi kho

16:24:43 Alex-SF

hi KZim

16:25:18 DinMamma


16:25:21 DinMamma


16:26:09 DinMamma

Is there any way(hackish or not) to get rundeck to execute tasks on a remote server that would survice a network issue etc?

16:26:42 DinMamma

If I issue a “yes” on a server, and then restart my rundeck server(it runs in a container, quick enough to bring back up :)) my yes-process obviously dies on the host.

16:26:53 DinMamma

I need yes to survice a restart of my rundeck-server.

16:28:23 DinMamma

Or network issue, or anything in between,

16:28:40 DinMamma

Im going to kick off long running processes that are not allowed to fail due to such things.

16:29:02 DinMamma

Using cron right now to kick them off, but would be nice with a ceteralized place etc.

16:37:09 Alex-SF

hi DinMamma

16:37:18 DinMamma


16:37:55 Alex-SF

so you want to execute a task on a remote node, kind of like a background task

16:38:14 Alex-SF

so i guess there’s a couple of points to make there

16:38:21 DinMamma

Yes, exactly.

16:38:35 Alex-SF

#1 is that the ssh dropped connection could propagate a terminate signal. that of course you don’t want

16:38:51 Alex-SF

because that will essentially interrupt your remote process

16:39:31 Alex-SF

so it’s like you want to trigger a managed process on a remote node. I say managed in the sense of “watched over”

16:40:07 DinMamma


16:40:13 Alex-SF

funny thing is in winrm the idea of a session is more persistent than it is with ssh

16:40:26 Alex-SF

i.e., in winrm you create a session that you can reconnect to.

16:40:56 DinMamma

I could use screen ofc, but I would rather not want to use that.

16:41:14 Alex-SF

so, this probably sounds like overkill but i do know of cases where people run another rundeck (like it was that watching process).

16:41:35 Alex-SF

so one rundeck calls another rundeck. the local rundeck manages the process

16:41:39 DinMamma

Ah yeah, just hit the api endpoints.

16:41:41 DinMamma

Thats quite nice.

16:41:42 Alex-SF

we should think of a lighter wait way

16:42:15 Alex-SF

but rundeck is small (50MB ). some users have asked about stripping rundeck down so it could be an agent with the same API set

16:42:29 Alex-SF

i kind of like that idea

16:42:31 DinMamma

That would be really cool.

16:43:03 DinMamma

Especially if the agent kind of stores its jobs locally, so they would be executed even if there is a network outage or watherever is using the cron feature.

16:43:06 Alex-SF

it solves lots of problems too. for example, the rundeck server could crash or get portioned from the network. When it comes back it could reconnect to the other ones

16:43:10 Alex-SF


16:43:26 Alex-SF

kind of a federated model

16:43:55 Alex-SF

btw, i know of a couple users that are doing this kind of thing in windows environments because they don’t want to use winrm

16:44:17 Alex-SF

so they put rundeck on each of the windows nodes and have a “master” rundeck call the api like a NodeExecutor

16:46:17 simon_

Blargh, battery died.

16:46:23 simon_

What was the last lines you wrote Alex-SF?

16:46:24 Alex-SF

darn that battery!

16:46:53 Alex-SF

oh about setting up rundeck like a remote agent in a windows environment because winrm couldn’t be worked out

16:47:10 simon_

I dont know any Java im afraid, and I dont have time to learn. But if there were any specs for what an agent would have to provide to be able to speak to the rundeck-server I could write one in Python.

16:47:35 Alex-SF

you could write a node executor plugin in python

16:47:45 simon_

Because this would be really useful.

16:47:50 Alex-SF

let me find a link

16:48:17 Alex-SF

firstly this is pretty cool to know about:

16:48:47 simon_

Oh, neato!

16:48:57 Alex-SF

and this

16:49:09 Alex-SF

yah these plugins can be written in script or java

16:49:16 Alex-SF

i write lots of plugins in bash :)

16:50:23 Alex-SF

let me know if you get stuck. we might want to do a online google hangout to teach this stuff if it’s helpful

16:51:03 simon_

Ok, Ill have a read and see if I can figure something out.

16:51:12 simon_

In the meantime Ill just stick to cron then :)

16:51:20 Alex-SF


17:03:32 damonedw

Rundeck community google hangout starting now:

17:10:35 simon_


17:10:44 simon_

I dont have a mic in this computer.

17:12:46 damonedw

simon_: what training topic would you be interested in? (for online free training)

17:13:28 simon_

damonedw: mostly about the architecture of rundeck I guess, and it would be cool with like “hello world plugin” hangout.

17:14:49 damonedw

simon_: any particular thing about the arch? overview? how to scale?

17:15:27 simon_

Just a high level overwiew, it can be a bit daunting to dive into a big codebase without a high level overview of where things live and if there are any design decisions one should know of.

17:17:06 simon_

Btw, Ive written a chef-cookbook for rundeck which automagically add nodes from a node search if anyone is interested

17:17:19 Alex-SF

holy moly. ya that is good

17:33:48 Kzim

hello i just discovered rundeck but i have many windows machines is there a good integration ?

17:34:21 Alex-SF

hi kzim

17:34:33 Alex-SF

the key part is the winrm plugin to make it possible

17:36:22 Kzim

Alex-SF, okay i’ll check that i’ ve seen that it’s one year old. i wanted to be sure that this is still fully functionnal :)

17:36:40 Alex-SF

yah, it’s still active.

17:36:56 Alex-SF

we recently made an update to have it use a newer underlying library

17:40:33 Kzim

great ! thx

17:47:35 Kzim

Alex-SF, i see that i can create form for job with like dropdown meny. can i pupulate this json from Chef for example ?

17:49:56 Alex-SF

yes, but you’d have to write a little CGI wrapper

17:50:26 Alex-SF

so essentially this CGI like wrapper would call the Chef search and return back the options JSON

17:55:04 Kzim

Alex-SF, i’m allowed to use what language to do that ? :)

18:04:43 Alex-SF

you could write a cgi in shell script

18:04:59 Alex-SF

but it does require something else to run the cgi. what scripting language do you like ?

18:07:04 Kzim

python, bash,ruby things like that

18:10:58 Alex-SF

ok. so you could write a cgi script that uses one of those languages like that

18:13:47 Kzim

that’ s great. so let me take a example and then i;ll leave you to install rundeck :)

18:14:21 Alex-SF

it would be nice for us to have a working example where you could just drop stuff into

18:15:00 Kzim

can rundeck is good to orchestrate a mongodb cluster creation for example ? install 3 server wait so that they are up then configure the replicaset then pop a mongoS, then wait and create the cluster and the user and destroy the mongos process

18:24:43 simon_

Kzim: I would rather use Chef/Puppet for that.

18:25:35 simon_

That way you dont need to do anything really, just use the manifest/cookbook and it will figure everything out by itself.

18:27:35 Kzim

simon_, we use Chef but Chef has no orchestration

18:28:01 simon_

Ah, sorry, didnt see orchestartion there.

18:28:59 Kzim

it’s a simple one but i’ll have to know wwhen every node are up then when the replicat set is configured for example

18:30:31 simon_

Are you running mongo in the cloud(tm) or on physical hardware? I think RightScale and other similar companies tries to solve these issues.

18:31:14 simon_

Our mongo-setup is on physical machines and very static(we add nodes to the cluster when we need more space) so the chef-recipes has been good enough for us.

18:33:36 simon_

Alrighty, I need to go home. Se yall later

18:40:04 Kzim


19:05:11 Kzim

Alex-SF, can i limit a user to a certain project or job ?

19:06:18 Alex-SF

Kzim: yes you can with an aclpolicy

19:06:42 Alex-SF

you can allow it on a per-user or per-usergroup basis

19:07:20 Kzim

wow i have amny things to read. it’s not in the GUI i assume

19:07:21 Alex-SF

19:07:37 Alex-SF

unfortunately, no. but it is a powerful dsl

19:18:21 Kzim

Alex-SF, so to user are managed in a flat file ? do you have good practice to version every file or ?

19:18:39 Kzim

well nevermind it was a stupid question

19:18:51 Alex-SF

just generally to manage them in an SCM and the provisioning packages them up

19:30:25 Kzim

Alex-SF, i’ve seen that you we can get any value from a Chef-server but can i tag a node with information in stored locally in the node ?

19:30:59 Alex-SF

you are asking if you can tag a node in rundeck locally?

19:31:48 Kzim

let’s say on each server i have a /etc/role file with a string in there. now i want to display that string in rundeck and filter servers based on it

19:33:15 Alex-SF

ok so that file, /etc/role, is a value that states the nodes role. Is that a chef role too?

19:33:37 Alex-SF

i should say, does chef know that information too

19:47:00 Kzim

Alex-SF, could be both yes

19:47:12 Kzim

some of those information will not be on chef

19:47:28 Kzim

on the Chef server. and perhaps we will use Chef solo

19:47:50 Alex-SF

ok, well you could maintain node info in another model source. Rundeck merges them together using the node name as the key

19:48:25 Alex-SF

for example, you could have a minimal set of node metadata that contains the role assignment.

19:48:36 Alex-SF

here’s a simple example

19:49:46 Alex-SF

you could have a chef server supplying the data it knows about as a URL model source via the chef-rundeck service. you could have another model source, maybe in a yaml/xml file that overlays the role info

19:49:58 Alex-SF

so your project would have 2 model sources

19:50:32 Kzim

i see intresting

20:02:26 Kzim

Alex-SF, to you have a good tuto for Chef plugin ?

20:04:34 Dink

Any have an ideas why I keep getting the follow:

20:04:36 Dink


20:04:42 Dink


20:05:36 Dink

sorry mangled remote copy/paste

20:05:38 Dink

Jun 6 16:00:09 w-d sshd[30309]: Accepted publickey for rsync from ::ffff: port 53874 ssh2

20:05:39 Dink

Jun 6 16:00:09 w-d sshd[30314]: Received disconnect from ::ffff: 3: com.jcraft.jsch.JSchException: Auth cancel

20:08:07 Dink

I can ssh using publickey fine

20:11:23 Alex-SF

Dink: can you make sure the correct key is being chosen? usually that’s the issue for me

20:11:36 Alex-SF

e.g., the one i use from the CLI is different than one used by rundeck

20:13:09 Dink

is it the same one in

20:17:36 Dink

hmm added they key again and it worked this time, strange

20:18:02 Alex-SF

added the key to the remote’s authorized?

20:26:58 Alex-SF

Kzim: we could totally benefit from a chef plugin tutorial

20:55:57 Dink

Alex-SF: yeah maybe it was a bad copy/paste originally. idk

22:25:25 travis-ci

[travis-ci] dtolabs/rundeck#271 (development - be79533 : Greg Schueler): The build passed.

22:25:25 travis-ci

[travis-ci] Change view :…be7953333cba

22:25:25 travis-ci

[travis-ci] Build details :