gcui-art / suno-api

Use API to call the music generation AI of suno.ai, and easily integrate it into agents like GPTs.
https://suno.gcui.ai
GNU Lesser General Public License v3.0
1.47k stars 340 forks source link

Improved docker compose integration #115

Closed Wheest closed 5 months ago

Wheest commented 5 months ago

Hi there, thanks a bunch for the repo.

This PR makes a small improvement by allowing the SUNO_COOKIE variable to be passed via Docker Compose, rather than requiring a .env file in the Dockerfile.

The motivation for this is that in Docker Compose you can build from a GitHub repo directly without cloning/submoduling, e.g.,:

services:
  suno-api:
    build:
      context: https://github.com/gcui-art/suno-api.git

However, this doesn't work because the Dockerfile directly copies a .env file in the suno-api directory, which doesn't exist.

Therefore this PR lets me provide the SUNO_COOKIE variable as an argument to the Dockerfile in my top-level docker-compose.yml, and thus allow this easier integration:

services:
  app:
    ...
  suno-api:
    build:
      context: https://github.com/gcui-art/suno-api.git
      args:
        SUNO_COOKIE: ${SUNO_COOKIE}
vercel[bot] commented 5 months ago

@Wheest is attempting to deploy a commit to the Linkly AI LLC's projects Team on Vercel.

A member of the Team first needs to authorize it.