stv0g / gose

A tera-scale file uploader
Apache License 2.0
193 stars 7 forks source link

Upload failed: Failed API request: invalid server #94

Closed bloodyburger closed 1 year ago

bloodyburger commented 1 year ago

I used the shipped docker-compose with below changes,

---
version: "3.7"
services:

  minio:
    image: minio/minio:RELEASE.2022-06-03T01-40-53Z.fips
    command: server /mnt/data --console-address ":9001"
    ports:
    - 9050:9000 # API
    - 9051:9001 # Webinterface
    environment:
      MINIO_ROOT_USER: "admin-user" # changeme!
      MINIO_ROOT_PASSWORD: "admin-pass"  # changeme!
      MINIO_SERVER_URL: "http://localhost:9000"
      MINIO_SITE_REGION: "s3"
    volumes:
    - minio-data:/mnt/data
    healthcheck:
      test: ["CMD", "curl", "-f", "http://localhost:9000/minio/health/ready"]
      interval: 30s
      timeout: 20s
      retries: 3

  gose:
    image: ghcr.io/stv0g/gose:v0.4.0
    container_name: gose
    build:
      context: .
    ports:
    - 8980:8080
    environment:
      GOSE_LISTEN: ":8080"
      GOSE_BASE_URL: "https://gose.teej.xyz"
      GOSE_BUCKET: "gose-uploads"
      GOSE_ENDPOINT: "minio:9000"
      GOSE_REGION: "s3"
      GOSE_PATH_STYLE: "true"
      GOSE_NO_SSL: "true"
      GOSE_ACCESS_KEY: "dfkljghe9847t0hdflhgsd--sd" # changeme!
      GOSE_SECRET_KEY: "213lkjzciuefnl097utbldksbv90423ybfsdnlo4909jp43" # changeme!
      GOSE_MAX_UPLOAD_SIZE: "50GB"
      GOSE_PART_SIZE: "16MB"
    depends_on:
    - minio

volumes:
  minio-data:

I have exposed this via SWAG proxy and when I try to upload a file, I get this error "Upload failed: Failed API request: invalid server"

stv0g commented 1 year ago

Can you please provide the proxy configuration?

Both gose and minio services need to be exposed.

stv0g commented 1 year ago

Please also note, that you likely leaked your S3 credentials in the snippet above.

stv0g commented 1 year ago

Closed due to missing information from issue reporter