Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 4 additions & 25 deletions .github/workflows/build-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
password: ${{ secrets.TOKEN }}

- name: Build and push for ${{ matrix.archs.arch }}
id: build
Expand Down Expand Up @@ -86,40 +86,19 @@ jobs:
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Login to Docker Hub
if: github.event_name != 'pull_request'
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_HUB_NAME }}
password: ${{ secrets.DOCKER_HUB_PASSWORD }}

- name: Login to Ali Hub
uses: docker/login-action@v3
with:
registry: registry.cn-hangzhou.aliyuncs.com
username: ${{ secrets.ALI_HUB_USERNAME }}
password: ${{ secrets.ALI_HUB_PASSWORD }}
password: ${{ secrets.TOKEN }}

- name: Create manifest list and push
working-directory: /tmp/digests
run: |
# Define all tags for different registries
GITHUB_TAG="ghcr.io/${{ github.repository_owner }}/fastgpt-plugin:${{ github.ref_name }}"

GITHUB_LATEST="ghcr.io/${{ github.repository_owner }}/fastgpt-plugin:latest"
GITHUB_SHA="ghcr.io/${{ github.repository_owner }}/fastgpt-plugin:${{ github.sha }}"

ALI_TAG="${{ secrets.ALI_IMAGE_NAME }}/fastgpt-plugin:${{ github.ref_name }}"
ALI_LATEST="${{ secrets.ALI_IMAGE_NAME }}/fastgpt-plugin:latest"
ALI_SHA="${{ secrets.ALI_IMAGE_NAME }}/fastgpt-plugin:${{ github.sha }}"

DOCKER_TAG="${{ secrets.DOCKER_IMAGE_NAME }}/fastgpt-plugin:${{ github.ref_name }}"
DOCKER_LATEST="${{ secrets.DOCKER_IMAGE_NAME }}/fastgpt-plugin:latest"
DOCKER_SHA="${{ secrets.DOCKER_IMAGE_NAME }}/fastgpt-plugin:${{ github.sha }}"

# Create array of all tags
TAGS="$GITHUB_TAG $GITHUB_LATEST $GITHUB_SHA $ALI_TAG $ALI_LATEST $ALI_SHA $DOCKER_TAG $DOCKER_LATEST $DOCKER_SHA"
TAGS=" $GITHUB_LATEST $GITHUB_SHA"

# Create manifest list for each tag
for TAG in $TAGS; do
Expand Down
3 changes: 2 additions & 1 deletion lib/s3/controller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,8 @@ export class S3Service {
useSSL: this.config.useSSL,
accessKey: this.config.accessKey,
secretKey: this.config.secretKey,
transportAgent: this.config.transportAgent
transportAgent: this.config.transportAgent,
pathStyle: false
});

if (this.config.externalBaseURL) {
Expand Down