Skip to content

Commit

Permalink
test: rewrite stable docker image build 8
Browse files Browse the repository at this point in the history
  • Loading branch information
Markson Hon committed Nov 12, 2023
1 parent 00c9334 commit aa791a3
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/release_main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -744,7 +744,7 @@ jobs:
# username: ${{ secrets.DOCKER_USERNAME }}
# password: ${{ secrets.DOCKER_PASSWORD }}
- name: Build and push
uses: docker/build-push-action@v3.0.0
uses: docker/build-push-action@v5.0.0
with:
context: .
builder: ${{ steps.buildx.outputs.name }}
Expand Down
2 changes: 2 additions & 0 deletions install/docker/Dockerfile.Action
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,10 @@ ADD .git ./.git
RUN git describe --abbrev=0 --tags | tee ./version

FROM alpine:latest AS builder
COPY ./install/docker/docker_helper.sh ./docker_helper.sh
RUN sh -c "$(cat ./docker_helper.sh)"
RUN apk add --no-cache iptables ip6tables nftables
RUN rm ./docker_helper.sh
EXPOSE 2017
VOLUME /etc/v2raya
ENTRYPOINT ["v2raya"]
4 changes: 2 additions & 2 deletions install/docker/docker_helper.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/sh
set -x
current_dir=$(pwd)
mkdir $tmp/cache && cd $tmp/cache
mkdir "$current_dir"/cache && cd "$current_dir"/cache || exit
case "$(arch)" in
x86_64)
v2ray_arch="64"
Expand Down Expand Up @@ -31,4 +31,4 @@ mkdir /usr/local/share/v2raya
ln -s /usr/local/share/v2ray /usr/local/share/v2raya
ln -s /usr/local/share/xray /usr/local/share/v2raya
wget -O /usr/local/share/v2ray/LoyalsoldierSite.dat https://raw.githubusercontent.com/mzz2017/dist-v2ray-rules-dat/master/geosite.dat
cd $current_dir && rm -rf $tmp/cache
cd "$current_dir" && rm -rf "$current_dir"/cache

0 comments on commit aa791a3

Please sign in to comment.