Skip to content

Commit

Permalink
centos7: add PYTHONPATH and serverspec path
Browse files Browse the repository at this point in the history
  • Loading branch information
juju4 committed Aug 12, 2018
1 parent e36df77 commit 44a1630
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tasks/misp-add-user.yml
Expand Up @@ -3,6 +3,8 @@
#- debug: var=list
- name: add user {{ user.email }}
command: "{{ python3_bin }} ./add_user.py -e {{ user.email }} -o {{ user.org }} -r {{ user.role }} chdir={{ misp_rootdir }}/PyMISP/examples"
environment:
PYTHONPATH: /usr/local/lib/python3.6/site-packages
when: list.stdout.find(user.email) == -1 and user.email is defined
register: out
#- debug: var=out
Expand Down
3 changes: 3 additions & 0 deletions tasks/misp-add-users.yml
Expand Up @@ -46,12 +46,15 @@
chdir: "{{ misp_rootdir }}/PyMISP/examples"
environment:
debug: True
PYTHONPATH: /usr/local/lib/python3.6/site-packages
register: test
changed_when: false
ignore_errors: true

- name: list current users
command: "{{ python3_bin }} ./users_list.py chdir={{ misp_rootdir }}/PyMISP/examples"
environment:
PYTHONPATH: /usr/local/lib/python3.6/site-packages
register: listusers
changed_when: false

Expand Down
2 changes: 2 additions & 0 deletions test/integration/default/serverspec/mispmodules_spec.rb
Expand Up @@ -3,6 +3,8 @@
# Required by serverspec
set :backend, :exec

set :path, '/usr/local/bin:$PATH'

describe command("pip3 freeze") do
its(:stdout) { should match /cybox/ }
its(:stdout) { should match /pymisp/ }
Expand Down

0 comments on commit 44a1630

Please sign in to comment.