feat: 添加 GNU AGPL v3 license #12
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build and Push Docker Image | |
| on: | |
| push: | |
| branches: | |
| - master | |
| permissions: | |
| packages: write | |
| contents: read | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: 1. 拉取最新代码 | |
| uses: actions/checkout@v4 | |
| - name: 2. 准备小写用户名 | |
| run: | | |
| echo "OWNER_LC=${OWNER,,}" >> $GITHUB_ENV | |
| env: | |
| OWNER: ${{ github.repository_owner }} | |
| - name: 3. 登录到 GitHub Container Registry | |
| uses: docker/login-action@v3 | |
| with: | |
| registry: ghcr.io | |
| username: ${{ github.actor }} | |
| password: ${{ secrets.GITHUB_TOKEN }} | |
| - name: 4. 构建并推送【后端】镜像 | |
| uses: docker/build-push-action@v5 | |
| with: | |
| context: ./backend | |
| push: true | |
| tags: ghcr.io/${{ env.OWNER_LC }}/wavebypass-backend:latest | |
| - name: 5. 构建并推送【前端】镜像 | |
| uses: docker/build-push-action@v5 | |
| with: | |
| context: ./frontend | |
| push: true | |
| tags: ghcr.io/${{ env.OWNER_LC }}/wavebypass-frontend:latest |