Skip to content

Commit 74014e9

Browse files
authored
Merge pull request #35 from fosslight/temp3
Add a Dockerfile
2 parents f21f2fe + 16ebe84 commit 74014e9

File tree

2 files changed

+37
-0
lines changed

2 files changed

+37
-0
lines changed

Dockerfile

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
# Copyright (c) 2022 LG Electronics Inc.
2+
# SPDX-License-Identifier: Apache-2.0
3+
FROM ubuntu:20.04
4+
5+
RUN apt-get update && apt-get install sudo -y
6+
RUN ln -sf /bin/bash /bin/sh
7+
8+
COPY . /app
9+
WORKDIR /app
10+
11+
ENV DEBIAN_FRONTEND=noninteractive
12+
13+
RUN apt-get -y install build-essential
14+
RUN apt-get -y install python3 python3-distutils python3-pip python3-dev
15+
RUN apt-get -y install python3-intbitset python3-magic
16+
RUN apt-get -y install libxml2-dev
17+
RUN apt-get -y install libxslt1-dev
18+
RUN apt-get -y install libhdf5-dev
19+
RUN apt-get -y install bzip2 xz-utils zlib1g libpopt0
20+
RUN apt-get -y install gcc-10 g++-10
21+
RUN pip3 install --upgrade pip
22+
RUN pip3 install .
23+
RUN pip3 install dparse
24+
25+
ENTRYPOINT ["/usr/local/bin/fosslight"]

README.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ SPDX-License-Identifier: Apache-2.0
3535
- [Ex 1. Local Source Analysis](#ex-1-local-source-analysis)
3636
- [Ex 2. Download Link and analyze](#ex-2-download-link-and-analyze)
3737
- [📁 Result](#-result)
38+
- [🐳 How to run using Docker](#-how-to-run-using-docker)
3839
- [👏 How to report issue](#-how-to-report-issue)
3940
- [📄 License](#-license)
4041

@@ -111,6 +112,17 @@ $ tree
111112
- FOSSLight_Report-[datetime].xlsx : OSS Report format file that outputs source code analysis, binary analysis, and dependency analysis results.
112113
- fosslight_raw_data_[datetime] directory: Directory in which raw data files are created as a result of analysis
113114

115+
## 🐳 How to run using Docker
116+
1. Build image using Dockerfile.
117+
```
118+
$docker build -t fosslight .
119+
```
120+
2. Run with the image you built.
121+
ex. Output: /Users/fosslight_source_scanner/test_output, Path to be analyzed: tests/test_files
122+
```
123+
$docker run -it -v /Users/fosslight_source_scanner/test_output:/app/output fosslight -p tests/test_files -o output
124+
```
125+
114126
## 👏 How to report issue
115127

116128
Please report any ideas or bugs to improve by creating an issue in [fosslight_scanner repository][cl].

0 commit comments

Comments
 (0)