csirtgadgets/bearded-avenger-deploymentkit

Easybutton script does not run

Closed this issue · 9 comments

Hey guys,

I'm trying an install on RHEL 7.3, should that work? I'm testing out v3, it seems pretty awesome! I've gotten the install to almost finish in the last few weeks, but it's failed before it finishes successfully. Now when I try to execute the easybutton.sh script, I get:

[user@server bearded-avenger-deploymentkit-3.0.0a4]$ sudo bash easybutton.sh 
Checking for an Internet connection
http://github.com appears to be available via HTTP

The output seems to be informational, but the script does not continue to run, so I'm wondering if there is something that I'm missing?

Hmmm, now I tried running the bootstrap.sh script in the centos7 directory, and it fails on the Task check for CentOS. Seems like I may need CentOS?

i've only tested with CentOS 73, have signed up for a RHEL developer lic so i could do some RHEL testing [when someone kicked me] which hasn't happened until now :)

which should look a bit like the CentOS Linux section below it.

if you've got the cycles to mess with it a bit we can bat it back and forth a little. if not and you can leverage CentOS for a bit (been testing with cent73 so it should work the same), may be able to bump the RHEL specific bits up the queue a little.. it should only be a few tweaks:

https://github.com/csirtgadgets/bearded-avenger-deploymentkit/blob/master/easybutton.sh#L68
https://github.com/csirtgadgets/bearded-avenger-deploymentkit/blob/master/centos7/roles/centos7/vars/main.yml#L6
https://github.com/csirtgadgets/bearded-avenger-deploymentkit/blob/master/centos7/roles/centos7/tasks/check.yml#L9

to tell both the easy button and ansible "oh yea, accept wva RHEL tells you too"

that make sense?

Hey Wes! Thanks for the reply.

I just went to the centos7 directory and ran sudo bash bootstrap.sh and it seemed to be working quite well until I got to the below task that Ansible failed on.

TASK [centos7 : systemd env file] **********************************************
task path: /home/user/bearded-avenger-deploymentkit-3.0.0a4/centos7/roles/centos7/tasks/services.yml:3
fatal: [localhost]: FAILED! => {"changed": false, "failed": true, "msg": "AnsibleUndefinedVariable: 'cif_hunter_advanced' is undefined"}
	to retry, use: --limit @/home/user/bearded-avenger-deploymentkit-3.0.0a4/centos7/site.retry

PLAY RECAP *********************************************************************
localhost                  : ok=35   changed=14   unreachable=0    failed=1  

i just pushed cifv3.0.0a22 and the deployment kit 3.0.0a5 should fix that (i ran into it today too solving some other issues, and fixed it accordingly). pushed the fixes mid day today so you might have just missed it(?)

Get ready for some crazy log files lol. Everything seems to work great until the script gets to

TASK [bearded-avenger : run tests] *********************************************
task path: /home/user/bearded-avenger-deploymentkit-3.0.0a5/roles/bearded-avenger/tasks/dist.yml:23

And then I get lots of Ansible errors. I sent the error to you in email...it's very long!

is this CentOS73 ? and can you paste in how you ran the easy button? i'm assuming you just ran the easybutton, but want to be sure so i can try to re-create it.

also- sometimes the vagrant ISO of 73 i use can be slightly diff than the master iso depending on which one you're using (in which i didn't see any errors in the release testing). link me which one you're downloading so i can see if there are major diffs.

This is RHEL 7.3. To get around some of the dependency checks, I just went directly into the centos7 directory and ran sudo bash bootstrap.sh

I'm running release 3.0.0a5

As far as the ISO that I'm using...that's complicated, it's a "gold image" built by our systems support team, so who knows what configurations they changed on it (I'm hoping not much).

ah ok. then i need to go back and spin up a RHEL instance, part of which may be having to write some rules for the subscription activation piece(?). i'm assuming you did that before you ran the EB? or does your GM have that baked in?

The RHEL server that I'm using has already been registered and activated. We use RHEL here as a default, so that's all handled by our systems support team on server build.

Let me know what/if I can do to help out with the testing, I'm willing and interested!

give this a shot

https://github.com/csirtgadgets/bearded-avenger-deploymentkit/archive/fix/redhat.zip
https://github.com/csirtgadgets/bearded-avenger-deploymentkit/pull/14/files

ignore the Vagrantfile_rhel73 file, but you can see how i bootstrapped my vm, reg'd with the RHEL overlords, etc and then how i triggered the easybutton.

i tested it a few times and it appears to work ok. most of teh changes are detecting 'RedHat' properly and fixing how the "extras" get installed (vs CentOS).

the error you saw was mostly python-dateutil being out of date on RHEL7 (it had 1.5 and it needed 2.4), which i fixed too. i need to re-test on CentOS to see if i ended up breaking anything there..