move dependencies to binary or deb packages
This commit is contained in:
parent
1b8fa5a7b3
commit
50dd651fab
@ -3,8 +3,9 @@
|
||||
- 127.0.0.1
|
||||
become: yes
|
||||
vars:
|
||||
pwn_hostname: "pwnagotchi"
|
||||
pwn_version: "master"
|
||||
pwn_hostname: "{{ lookup('env', 'PWN_HOSTNAME') | default('pwnagotchi', true) }}"
|
||||
pwn_version: "{{ lookup('env', 'PWN_VERSION') | default('master', true) }} "
|
||||
bettercap_query: "assets[?contains(name, 'armv6l')].browser_download_url"
|
||||
|
||||
tasks:
|
||||
|
||||
@ -57,6 +58,7 @@
|
||||
- git
|
||||
- build-essential
|
||||
- python3-pip
|
||||
- unzip
|
||||
- gawk
|
||||
- libopenmpi-dev
|
||||
- libatlas-base-dev
|
||||
@ -87,6 +89,25 @@
|
||||
- fonts-dejavu
|
||||
- fonts-dejavu-core
|
||||
- fonts-dejavu-extra
|
||||
- python3-crypto
|
||||
- python3-requests
|
||||
- python3-yaml
|
||||
- python3-smbus
|
||||
- python3-inkyphat
|
||||
- python3-numpy
|
||||
- python3-pil
|
||||
- python3-tweepy
|
||||
- python3-opencv
|
||||
- python3-termcolor
|
||||
- python3-astor
|
||||
- python3-backports.weakref
|
||||
- python3-keras-applications
|
||||
- python3-keras-preprocessing
|
||||
- python3-six
|
||||
- python3-protobuf
|
||||
- python3-wrapt
|
||||
- python3-wheel
|
||||
- python3-mock
|
||||
|
||||
- name: configure dphys-swapfile
|
||||
file:
|
||||
@ -113,16 +134,48 @@
|
||||
state: started
|
||||
enabled: yes
|
||||
|
||||
- name: build bettercap
|
||||
command: go get -u github.com/bettercap/bettercap
|
||||
environment:
|
||||
GOPATH: /root/go
|
||||
GOROOT: /usr/lib/go
|
||||
- name: acquire python3 pip target
|
||||
command: "python3 -c 'import sys;print(sys.path.pop())'"
|
||||
register: pip_target
|
||||
|
||||
- name: install bettercap
|
||||
copy:
|
||||
src: /root/go/bin/bettercap
|
||||
dest: /usr/bin/bettercap
|
||||
- name: install pip packages that are not architecture tied
|
||||
pip:
|
||||
name: "{{ packages }}"
|
||||
extra_args: "--no-deps --extra-index-url=https://www.piwheels.hostedpi.com/simple/ --prefer-binary --no-cache-dir --platform=armv6l --target={{ pip_target.stdout }}"
|
||||
vars:
|
||||
packages:
|
||||
- absl-py
|
||||
- enum34
|
||||
- gast
|
||||
- google_pasta
|
||||
- opt_einsum
|
||||
- tensorboard
|
||||
- scapy
|
||||
- gym
|
||||
- stable-baselines
|
||||
- file_read_backwards
|
||||
- tensorflow_estimator
|
||||
|
||||
- name: install grpcio
|
||||
command: "pip3 install --no-deps --extra-index-url=https://www.piwheels.hostedpi.com/simple/ --no-cache-dir --prefer-binary --platform=armv6l --only-binary=:all: --target={{ pip_target.stdout }} https://www.piwheels.hostedpi.com/simple/grpcio/grpcio-1.24.1-cp37-cp37m-linux_armv6l.whl"
|
||||
|
||||
- name: install tensorflow
|
||||
command: "pip3 install --no-deps --extra-index-url=https://www.piwheels.hostedpi.com/simple/ --no-cache-dir --prefer-binary --platform=armv6l --only-binary=:all: --target={{ pip_target.stdout }} https://storage.googleapis.com/tensorflow/raspberrypi/tensorflow-1.14.0-cp34-none-linux_armv6l.whl"
|
||||
|
||||
- name: fetch bettercap release information
|
||||
uri:
|
||||
url: https://api.github.com/repos/bettercap/bettercap/releases/latest
|
||||
return_content: yes
|
||||
register: bettercap_release
|
||||
|
||||
- name: download and install bettercap
|
||||
unarchive:
|
||||
src: "{{ bettercap_release.content | from_json | json_query(bettercap_query) | first }}"
|
||||
dest: /usr/bin
|
||||
remote_src: yes
|
||||
exclude:
|
||||
- README.md
|
||||
- LICENSE.md
|
||||
mode: 0755
|
||||
|
||||
- name: clone bettercap caplets
|
||||
@ -151,10 +204,6 @@
|
||||
path: /tmp/pwnagotchi
|
||||
state: absent
|
||||
|
||||
- name: install python modules
|
||||
pip:
|
||||
requirements: /root/pwnagotchi/scripts/requirements.txt
|
||||
|
||||
- name: create cpuusage script
|
||||
copy:
|
||||
dest: /usr/bin/cpuusage
|
||||
|
Loading…
x
Reference in New Issue
Block a user