You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+34Lines changed: 34 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -146,3 +146,37 @@ Licensing
146
146
---------
147
147
148
148
PHP malware scanner is [licensed](https://github.com/scr34m/php-malware-scanner/blob/master/LICENSE.txt) under the GNU General Public License v3.
149
+
150
+
Docker Usage
151
+
-----------
152
+
153
+
You can also run the scanner using Docker:
154
+
155
+
1. Build the image:
156
+
```bash
157
+
docker build -t php-malware-scanner .
158
+
```
159
+
160
+
2. Scan a directory:
161
+
```bash
162
+
docker run -v /path/to/scan:/code php-malware-scanner -d /code
163
+
```
164
+
165
+
For example, to scan a WordPress installation:
166
+
```bash
167
+
docker run -v /var/www/html:/code php-malware-scanner -d /code -j 6.4.1
168
+
```
169
+
170
+
Common usage with flags:
171
+
```bash
172
+
# Show only infected files (hide OK status)
173
+
docker run -v /path/to/scan:/code php-malware-scanner -d /code -k
174
+
175
+
# Show comments for matched patterns
176
+
docker run -v /path/to/scan:/code php-malware-scanner -d /code -c
177
+
178
+
# Show MD5 hashes and continue after first match
179
+
docker run -v /path/to/scan:/code php-malware-scanner -d /code -m -s
180
+
```
181
+
182
+
The `/code` directory inside the container is where your files will be mounted for scanning.
0 commit comments