Skip to content

Commit 899e975

Browse files
authored
Merge pull request #174 from canonical/remove-aproxy
Remove aproxy since self-hosted runners should have it now
2 parents 2929fe1 + 3763e3c commit 899e975

File tree

1 file changed

+4
-25
lines changed

1 file changed

+4
-25
lines changed

.github/workflows/server-publish-oci-image.yml

+4-25
Original file line numberDiff line numberDiff line change
@@ -23,35 +23,14 @@ jobs:
2323
steps:
2424
- name: Set up Docker Buildx
2525
uses: docker/setup-buildx-action@v3
26+
with:
27+
config-inline: |
28+
[registry."docker.io"]
29+
mirrors = ["https://github-runner-dockerhub-cache.canonical.com:5000"]
2630
2731
- name: Checkout repository
2832
uses: actions/checkout@v3
2933

30-
- name: Install Aproxy Snap
31-
run: |
32-
sudo snap install --edge aproxy
33-
34-
- name: Configure Aproxy
35-
run: |
36-
sudo snap set aproxy proxy=squid.internal:3128
37-
sudo nft -f - << EOF
38-
define default-ip = $(ip route get $(ip route show 0.0.0.0/0 | grep -oP 'via \K\S+') | grep -oP 'src \K\S+')
39-
define private-ips = { 10.0.0.0/8, 127.0.0.1/8, 172.16.0.0/12, 192.168.0.0/16 }
40-
table ip aproxy
41-
flush table ip aproxy
42-
table ip aproxy {
43-
chain prerouting {
44-
type nat hook prerouting priority dstnat; policy accept;
45-
ip daddr != \$private-ips tcp dport { 80, 443 } counter dnat to \$default-ip:8443
46-
}
47-
48-
chain output {
49-
type nat hook output priority -100; policy accept;
50-
ip daddr != \$private-ips tcp dport { 80, 443 } counter dnat to \$default-ip:8443
51-
}
52-
}
53-
EOF
54-
5534
- name: Log in to the Container registry
5635
uses: docker/login-action@65b78e6e13532edd9afa3aa52ac7964289d1a9c1
5736
with:

0 commit comments

Comments
 (0)