mirror of
https://github.com/b4tman/docker-squid.git
synced 2026-02-04 14:05:01 +00:00
Compare commits
75 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
bb5513fac9
|
|||
|
20ef8cf8be
|
|||
|
|
a6b68820a9 | ||
| d1e2082f73 | |||
| 70ac196b86 | |||
|
|
15cf0f1674 | ||
|
|
72ef256dfe | ||
|
|
74a4ac3993 | ||
|
f709ee39b4
|
|||
|
a3b428e958
|
|||
|
0ca618e4a0
|
|||
|
|
cf301af570 | ||
| 483a6c83de | |||
| 4e7b30df68 | |||
|
|
6b9adeb25a | ||
|
|
63fcfbd66f | ||
|
a9785a47bc
|
|||
| 8394735252 | |||
|
5092f79c09
|
|||
| f49f923a2b | |||
|
bbf973390f
|
|||
|
|
9e3ce9a7e4 | ||
|
b15fe81ac6
|
|||
| e2bc962b39 | |||
|
e513e356c7
|
|||
| af1abd0039 | |||
|
|
b462213727 | ||
|
|
d1a9592a3f | ||
|
127d9c258c
|
|||
|
88f5272b9e
|
|||
|
c057771360
|
|||
|
|
56930ae938 | ||
|
34910856c7
|
|||
|
82982b2ac5
|
|||
|
88a2d623e4
|
|||
|
7388c631e8
|
|||
|
06757f1033
|
|||
|
2398325ccb
|
|||
|
aabc247a2b
|
|||
|
9f6c88ad96
|
|||
|
7ae134af14
|
|||
|
d26782c0b3
|
|||
|
e4d312e05e
|
|||
|
b5e86101ef
|
|||
|
2a8b885fad
|
|||
|
63c7ba99e9
|
|||
|
7ac8996e39
|
|||
|
d92da9a79d
|
|||
|
11434c9296
|
|||
|
9b081c8cec
|
|||
|
6c614c0f90
|
|||
|
a3b384fd87
|
|||
|
6f69039cbb
|
|||
|
393e77b80d
|
|||
|
9e51552e39
|
|||
|
2c911aad44
|
|||
|
fe0e5831e1
|
|||
|
2c8641472e
|
|||
|
be6513f835
|
|||
|
f2f586f586
|
|||
|
382a181d1a
|
|||
|
a68a4dc255
|
|||
|
bd235e7e19
|
|||
|
b42486dc88
|
|||
|
8a016f4d1e
|
|||
|
25d8d427fe
|
|||
|
7393b0da87
|
|||
|
5ea9da0782
|
|||
|
6f612170e6
|
|||
| d059b7d2cd | |||
| 876c6f0678 | |||
| f384c90781 | |||
| 266a711b36 | |||
| 7f55a91c1d | |||
| 247d11d625 |
8
.github/dependabot.yml
vendored
Normal file
8
.github/dependabot.yml
vendored
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
version: 2
|
||||||
|
updates:
|
||||||
|
- package-ecosystem: docker
|
||||||
|
directory: "/"
|
||||||
|
schedule:
|
||||||
|
interval: monthly
|
||||||
|
time: '02:00'
|
||||||
|
open-pull-requests-limit: 10
|
||||||
30
Dockerfile
30
Dockerfile
@@ -1,7 +1,7 @@
|
|||||||
FROM alpine:3.8 as build
|
FROM --platform=linux/armhf alpine:3.12.0 as build
|
||||||
|
|
||||||
ENV SQUID_VER 3.5.28
|
ENV SQUID_VER 4.12
|
||||||
ENV SQUID_SIG_KEY EA31CC5E9488E5168D2DCC5EB268E706FF5CF463
|
ENV SQUID_SIG_KEY B06884EDB779C89B044E64E3CD6DBF8EF3B17D3E
|
||||||
|
|
||||||
RUN set -x && \
|
RUN set -x && \
|
||||||
apk add --no-cache \
|
apk add --no-cache \
|
||||||
@@ -24,8 +24,8 @@ RUN set -x && \
|
|||||||
RUN set -x && \
|
RUN set -x && \
|
||||||
mkdir -p /tmp/build && \
|
mkdir -p /tmp/build && \
|
||||||
cd /tmp/build && \
|
cd /tmp/build && \
|
||||||
curl -SsL http://www.squid-cache.org/Versions/v${SQUID_VER%.*.*}/${SQUID_VER%.*}/squid-${SQUID_VER}.tar.gz -o squid-${SQUID_VER}.tar.gz && \
|
curl -SsL http://www.squid-cache.org/Versions/v${SQUID_VER%%.*}/squid-${SQUID_VER}.tar.gz -o squid-${SQUID_VER}.tar.gz && \
|
||||||
curl -SsL http://www.squid-cache.org/Versions/v${SQUID_VER%.*.*}/${SQUID_VER%.*}/squid-${SQUID_VER}.tar.gz.asc -o squid-${SQUID_VER}.tar.gz.asc
|
curl -SsL http://www.squid-cache.org/Versions/v${SQUID_VER%%.*}/squid-${SQUID_VER}.tar.gz.asc -o squid-${SQUID_VER}.tar.gz.asc
|
||||||
|
|
||||||
RUN set -x && \
|
RUN set -x && \
|
||||||
cd /tmp/build && \
|
cd /tmp/build && \
|
||||||
@@ -71,6 +71,7 @@ RUN set -x && \
|
|||||||
--enable-arp-acl \
|
--enable-arp-acl \
|
||||||
--enable-openssl \
|
--enable-openssl \
|
||||||
--enable-ssl-crtd \
|
--enable-ssl-crtd \
|
||||||
|
--enable-security-cert-generators="file" \
|
||||||
--enable-ident-lookups \
|
--enable-ident-lookups \
|
||||||
--enable-useragent-log \
|
--enable-useragent-log \
|
||||||
--enable-cache-digests \
|
--enable-cache-digests \
|
||||||
@@ -96,8 +97,11 @@ RUN set -x && \
|
|||||||
cd /tmp/build && \
|
cd /tmp/build && \
|
||||||
make -j $(grep -cs ^processor /proc/cpuinfo) && \
|
make -j $(grep -cs ^processor /proc/cpuinfo) && \
|
||||||
make install
|
make install
|
||||||
|
|
||||||
|
RUN sed -i '1s;^;include /etc/squid/conf.d/*.conf\n;' /etc/squid/squid.conf
|
||||||
|
RUN echo 'include /etc/squid/conf.d.tail/*.conf' >> /etc/squid/squid.conf
|
||||||
|
|
||||||
FROM alpine:3.8
|
FROM --platform=linux/armhf alpine:3.12.0
|
||||||
|
|
||||||
ENV SQUID_CONFIG_FILE /etc/squid/squid.conf
|
ENV SQUID_CONFIG_FILE /etc/squid/squid.conf
|
||||||
ENV TZ Europe/Moscow
|
ENV TZ Europe/Moscow
|
||||||
@@ -110,8 +114,8 @@ RUN apk add --no-cache \
|
|||||||
libstdc++ \
|
libstdc++ \
|
||||||
heimdal-libs \
|
heimdal-libs \
|
||||||
libcap \
|
libcap \
|
||||||
libressl2.7-libcrypto \
|
libressl3.1-libcrypto \
|
||||||
libressl2.7-libssl \
|
libressl3.1-libssl \
|
||||||
libltdl
|
libltdl
|
||||||
|
|
||||||
COPY --from=build /etc/squid/ /etc/squid/
|
COPY --from=build /etc/squid/ /etc/squid/
|
||||||
@@ -125,9 +129,11 @@ RUN install -d -o squid -g squid \
|
|||||||
/var/run/squid && \
|
/var/run/squid && \
|
||||||
chmod +x /usr/lib/squid/*
|
chmod +x /usr/lib/squid/*
|
||||||
|
|
||||||
RUN echo 'include /etc/squid/conf.d/*.conf' >> "$SQUID_CONFIG_FILE" && \
|
RUN install -d -m 755 -o squid -g squid \
|
||||||
install -d -m 755 -o squid -g squid /etc/squid/conf.d
|
/etc/squid/conf.d \
|
||||||
COPY squid-log.conf /etc/squid/conf.d/
|
/etc/squid/conf.d.tail
|
||||||
|
RUN touch /etc/squid/conf.d/placeholder.conf
|
||||||
|
COPY squid-log.conf /etc/squid/conf.d.tail/
|
||||||
|
|
||||||
RUN set -x && \
|
RUN set -x && \
|
||||||
apk add --no-cache --virtual .tz alpine-conf tzdata && \
|
apk add --no-cache --virtual .tz alpine-conf tzdata && \
|
||||||
@@ -139,4 +145,4 @@ EXPOSE 3128/tcp
|
|||||||
|
|
||||||
USER squid
|
USER squid
|
||||||
|
|
||||||
CMD ["sh", "-c", "/usr/sbin/squid -f ${SQUID_CONFIG_FILE} -z && exec /usr/sbin/squid -f ${SQUID_CONFIG_FILE} -NYCd 1"]
|
CMD ["sh", "-c", "/usr/sbin/squid -f ${SQUID_CONFIG_FILE} --foreground -z && exec /usr/sbin/squid -f ${SQUID_CONFIG_FILE} --foreground -YCd 1"]
|
||||||
|
|||||||
@@ -1,4 +1,7 @@
|
|||||||
[](https://microbadger.com/images/b4tman/squid "Get your own image badge on microbadger.com")
|
[](https://microbadger.com/images/b4tman/squid:armhf "Get your own image badge on microbadger.com")
|
||||||
|
[](https://dependabot.com)
|
||||||
|

|
||||||
|

|
||||||
|
|
||||||
# docker-squid
|
# docker-squid
|
||||||
|
|
||||||
|
|||||||
11
docker-compose.test.yml
Normal file
11
docker-compose.test.yml
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
version: '2'
|
||||||
|
services:
|
||||||
|
proxy:
|
||||||
|
build: .
|
||||||
|
sut:
|
||||||
|
image: alpine:3.10.1
|
||||||
|
links:
|
||||||
|
- proxy
|
||||||
|
depends_on:
|
||||||
|
- proxy
|
||||||
|
command: sh -exc "apk add --update curl && sleep 5 && exec curl --proxy http://proxy:3128 -I http://google.com/"
|
||||||
@@ -1,12 +1,12 @@
|
|||||||
version: '2'
|
version: '2'
|
||||||
services:
|
services:
|
||||||
squid:
|
squid:
|
||||||
image: 'b4tman/squid'
|
image: 'b4tman/squid:armhf'
|
||||||
container_name: 'my-squid'
|
container_name: 'my-squid'
|
||||||
restart: always
|
restart: always
|
||||||
ports:
|
ports:
|
||||||
- '3128:3128'
|
- '3128:3128'
|
||||||
# environment:
|
# environment:
|
||||||
# SQUID_CONFIG_FILE: /etc/squid/my-squid.conf
|
# SQUID_CONFIG_FILE: /etc/squid/my-squid.conf
|
||||||
# volumes:
|
# volumes:
|
||||||
# - './my-squid.conf:/etc/squid/my-squid.conf:ro'
|
# - './my-squid.conf:/etc/squid/my-squid.conf:ro'
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
logfile_rotate 0
|
logfile_rotate 0
|
||||||
cache_store_log none
|
cache_store_log none
|
||||||
access_log stdio:/proc/self/fd/1
|
access_log stdio:/proc/self/fd/1
|
||||||
cache_log stdio:/proc/self/fd/2
|
cache_log /dev/null
|
||||||
|
|||||||
4
ssl-bump/Dockerfile
Normal file
4
ssl-bump/Dockerfile
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
FROM b4tman/squid:armhf
|
||||||
|
|
||||||
|
USER root
|
||||||
|
CMD ["sh", "-c", "(test -d /var/cache/squid/ssl_db || /usr/lib/squid/security_file_certgen -c -s /var/cache/squid/ssl_db -M 4MB) && /usr/sbin/squid -f ${SQUID_CONFIG_FILE} --foreground -z && exec /usr/sbin/squid -f ${SQUID_CONFIG_FILE} --foreground -YCd 1"]
|
||||||
Reference in New Issue
Block a user