DVinyl icon indicating copy to clipboard operation
DVinyl copied to clipboard

Struggling to deploy with portainer

Open crispybegs opened this issue 10 months ago • 28 comments

i'm trying to get this running via portainer, but having a few problems.

I followed the steps here to download the repo and then edited the .env with the correct variables.

In the portainer UI I first tried uploading the compose yaml, but get this

Image

So I tried that again but this time loading in the variables form the .env, but again got this

Image

So i then just tried putting all env variables exposed in the compose yaml and pasting the whole lot in the portainer UI, but got this:

Image

Any ideas?

crispybegs avatar Jan 30 '26 10:01 crispybegs

Hi ! probably your .env file no ?

He can't find /data/compose/190/.env probably try to correct the destination

NoNoBzH22 avatar Jan 30 '26 17:01 NoNoBzH22

Did you compose correctly ?

NoNoBzH22 avatar Jan 30 '26 17:01 NoNoBzH22

This was the straight compose i tried:

version: '3.8'

services:
  dvinyl-app:
    build: .
    container_name: dvinyl_app
    restart: unless-stopped
    ports:
      - "3099:3099" # External port : Internal port
    volumes:
      - /mnt/terramaster/media/audio/music/vinyl/dvinyl/uploads:/app/public/uploads
    environment:
        - MONGDODB_URL=mongodb://mongodb:27017/dvinyl # MongoDB connection URL (you can change if needed)
        - PASSJWT=[redacted]
        - SESSION_SECRET=[redacted]
        - PROD=true # Change to true in production
        - VINYL_PORT=3099 # Port for the DVinyl service
        - DISCOGS_TOKEN=[redacted]
        - GOOGLE_API_KEY=[redacted]
        - GOOGLE_CSE_ID=[redacted]
        
    depends_on:
      - mongodb

  # Database service
  mongodb:
    image: mongo:latest
    container_name: dvinyl_db
    restart: unless-stopped
    volumes:
      - ./mongo_data:/data/db 

volumes:
  mongo_data:

crispybegs avatar Jan 30 '26 17:01 crispybegs

Oh i find, thats a environment problem look at MONGDODB_URL and replace with MONGODB_URL

NoNoBzH22 avatar Jan 30 '26 17:01 NoNoBzH22

ah yes, that typo is in the compose yaml i downloaded btw i fixed it, however i still got

Deployment error
Failed to deploy a stack: compose build operation failed: failed to solve: failed to read dockerfile: open Dockerfile: no such file or directory

crispybegs avatar Jan 30 '26 18:01 crispybegs

My bad, I'll adjust the variable name in the next update...

It seems that you're not running your command/the command is not running in the same location as the Dockerfile?

I am not familiar with Portainer, sorry :(

Kyonew avatar Jan 30 '26 19:01 Kyonew

Got exactly the same error as @crispybegs failed to solve: failed to read dockerfile: open Dockerfile: no such file or directory I'm not using Portainer. Classic install on Debian 12. Mongodb is however running...

houdini69 avatar Jan 30 '26 21:01 houdini69

My bad, I'll adjust the variable name in the next update...

It seems that you're not running your command/the command is not running in the same location as the Dockerfile?

I am not familiar with Portainer, sorry :(

ah ok, yes i deploy everything through portainer. usually just by pasting the compose yaml (as above) into the stack ui and clicking deploy

crispybegs avatar Jan 30 '26 21:01 crispybegs

Oh okay! I don't think pasting the compose yaml is enough. If you don't copy the files (via git clone), it will surely cause problems... Also, I added the location for the records. If I remember correctly, that was your idea :D

Kyonew avatar Jan 30 '26 21:01 Kyonew

it was my idea, thank you! but at the moment i can't get it to run to try it. i have downloaded all the files into the project folder, but there's no reference in the compose to bind a path to the project directory?

crispybegs avatar Jan 30 '26 22:01 crispybegs

No, that's true. In fact, when you go to the root of the project, you should be able to launch the docker with the commands in docker.md. That's why there's no reference to the source code in the yml.

Kyonew avatar Jan 30 '26 22:01 Kyonew

ok yep, the thing is, portainer is the orchestrator for all my stacks. if i create a stack outside portainer then I can view it, but will be unable to edit it any further from within portainer if i want to make tweaks later

crispybegs avatar Jan 30 '26 23:01 crispybegs

Oh okay. Tell me what do you need to runs the app with Portainer, I'll do my best to integrate it

Kyonew avatar Jan 30 '26 23:01 Kyonew

ok, well i built the dockerfile myself with

docker build -t dvinyl-app:latest .

and changed the build section of the compose to:

services:
  dvinyl-app:
    image: dvinyl-app:latest
    container_name: dvinyl_app

i visited the service url and...good news!... I got the UI asking me to make an admin account.. I created an admin user, and was taken to the login screen.. entered my details and... bad news... the log in form just resets itself to this:

Image

I'll be honest man, i really really really wanted to try this but I can't recall the last time I've had so much trouble just getting something working, so I'm going to step away from it for now and maybe check back in a few weeks / months to see if it's been improved or abandoned.

crispybegs avatar Jan 30 '26 23:01 crispybegs

I am sincerely sorry that it is not working as intended. I am currently working on the connection issue. Thank you for taking the time to try to get my project working, you can always make your own changes! I don't mind a little help...

Kyonew avatar Jan 31 '26 00:01 Kyonew

Same problem here without Portainer (just following the instructions), I can create the account, but afterwards I cannot login. By the way: creating a custom search engine for the entire web isn't possible anymore, it was discontinued by google on January 20 2026. Custom search engines for the entire web created before Jan 20 2026 will work until January 1 2027.

mhamoser avatar Jan 31 '26 06:01 mhamoser

I am sincerely sorry that it is not working as intended. I am currently working on the connection issue. Thank you for taking the time to try to get my project working, you can always make your own changes! I don't mind a little help...

all good! I definitely will check again as I very much want this to work

crispybegs avatar Jan 31 '26 07:01 crispybegs

Same problem here without Portainer (just following the instructions), I can create the account, but afterwards I cannot login. By the way: creating a custom search engine for the entire web isn't possible anymore, it was discontinued by google on January 20 2026. Custom search engines for the entire web created before Jan 20 2026 will work until January 1 2027.

I'm doing my best to find a solution to this problem. I don't think this option is very useful in our case, so I'll try without and I'll remove it from the markdown! Thank you.

Kyonew avatar Jan 31 '26 11:01 Kyonew

all good! I definitely will check again as I very much want this to work

Thank you really much. If you find a solution, let me know. I can’t get this login problem, it's hard to help with that...

Kyonew avatar Jan 31 '26 12:01 Kyonew

OKAY I MAY KNOW. In your .env file, the PROD variable has to be set to false if you're using http. Only use true with https.. Does it solve the problem?

Kyonew avatar Jan 31 '26 14:01 Kyonew