From 1b305576a348c133c0e38332dee4a6d1dffac669 Mon Sep 17 00:00:00 2001 From: lc6464 <64722907+lc6464@users.noreply.github.com> Date: Wed, 6 Dec 2023 23:47:15 +0800 Subject: [PATCH] =?UTF-8?q?=E4=B8=B4=E6=97=B6=E6=B5=8B=E8=AF=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .github/workflows/temp-test.yml | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 .github/workflows/temp-test.yml diff --git a/.github/workflows/temp-test.yml b/.github/workflows/temp-test.yml new file mode 100644 index 00000000..9c7366a6 --- /dev/null +++ b/.github/workflows/temp-test.yml @@ -0,0 +1,27 @@ +name: Build Docker Image & Pack Source Code + +on: + push: + +# git tag -a v1.0.0 +# git push origin v1.0.0 + +env: + IMAGE_NAME: baiduwp-php + +jobs: + build_and_upload: + runs-on: ubuntu-latest + + steps: + - name: Checkout repository + uses: actions/checkout@v4 + + - name: Parse version from tag name + run: echo "VERSION=$(echo $GITHUB_REF | sed -n 's/refs\/tags\/v\(.*\)/\1/p')" >> $GITHUB_ENV + + - name: Build Docker image + run: docker build . --file Dockerfile --tag ${{ env.IMAGE_NAME }} + + - name: Log into Docker Hub + run: echo "${{ secrets.DOCKER_ACCESS_TOKEN }}" | docker login -u yuantuo666 --password-stdin