Skip to content

compile in docker multistage  #180

@garanews

Description

@garanews

Hello,
would like to know what are the right lib to copy after compiled yara && yara-python from sources.

FROM base-builder as yara-builder
RUN cd /tmp/ \
  && git clone --recursive https://github.com/VirusTotal/yara.git \
..
..
&& make install \
..
  && git clone --recursive https://github.com/VirusTotal/yara-python \
..
...
  && python setup.py install \

at the end :

COPY --from=yara-builder /usr/local/lib/python3.8/site-packages/yara_python-4.1.0-py3.8-linux-x86_64.egg /usr/local/lib/python3.8/site-packages/yara_python-4.1.0-py3.8-linux-x86_64.egg
COPY --from=yara-builder /usr/local/lib/libyara* /usr/local/lib/

but if I try in python to import yara I get ModuleNotFoundError: No module named 'yara'
(Instead if I try inside docker image to follow same step I used to compile, it works with any issue)

There is any other library/file to copy from compiler stage to the final stage?
Thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions