Unable to deploy 'blank/new' npx create-payload-app to Payload Cloud

default discord avatar
oldmanpewpew
3 weeks ago
10

Appears i'm having the same? issue as the post from RankedDev28



I created a new blank payload app. Runs locally great.



I have DATABASE_URI, PAYLOAD_SECRET, and also MONGODB_URI (even though the code only looks for DATABASE_URI, the error on payloadcms.com/cloud says to check MONGODB_URI for some reason -- payload.config.ts looks for DATABASE_URI).



The logs appears/disappear too quickly on the webapp to read what the issue may be.



ProjectID is: 654bba80a24033b20bf32a26

  • discord user avatar
    denolfe
    Payload Team
    3 weeks ago

    I can look into this today

  • default discord avatar
    oldmanpewpew
    3 weeks ago

    I just saw it flash in the logs that yarn was missing (we don't use yarn)



    so I did a quick npm install --save-dev yarn



    trying that

  • discord user avatar
    denolfe
    Payload Team
    3 weeks ago

    Likely just a build issue, I will look shortly

  • default discord avatar
    oldmanpewpew
    3 weeks ago

    I also saw:

    ā”‚ ---> Downloading and extracting Node v16.20.2

    and thought node v16 was beyond EOL (even for security updates). Just thought i'd mention



    heh -- well, it definitely got farther I think today -- but still fails to deploy and there is no way to view the logs (they vanish from the UI)

  • discord user avatar
    denolfe
    Payload Team
    3 weeks ago

    Your run script is set to

    npm run start

    , but you likely do not have a script named that. It is likely

    serve

    that needs to be run if you used the blank template.



    I'd check that first.

    CleanShot_2023-11-09_at_08.39.03.png
  • default discord avatar
    oldmanpewpew
    3 weeks ago

    Trying that thanks. This part of the UI on payloadcms.com -^ just vanishes when the build fails heh. So it makes it hard to know where to look šŸ™‚

    CleanShot_2023-11-09_at_09.18.43.png
  • discord user avatar
    denolfe
    Payload Team
    3 weeks ago

    Re: Node.js version. This should be defaulting to Node 20 unless you've specified a version in your package.json. I can look into this.

  • default discord avatar
    oldmanpewpew
    3 weeks ago

    I didn't edit the package.json that npx create-payload-app at all.



    So no specified node version, and no yarn (which causes it also to fail).



    so seems like possibly a few things:


    1. npx create-payload-app needs some tweaking


    2. The 'default settings' for payloadcms.com for a imported project should possibly? do npm run serve vs npm run start (I hadn't edited those either)


    3. The error message on payloadcms.com indicates MONGODB_URI needs to be set possibly, when i'm pretty sure the code (again from npx create-payload-app for a blank template) has DATABASE_URI in it.



    it has deployed and is live! šŸ™‚

  • discord user avatar
    denolfe
    Payload Team
    3 weeks ago

    All of these things noted. Thank you for the feedback šŸ‘

  • default discord avatar
    oldmanpewpew
    3 weeks ago

    excited to kick tires on this. thanks for your help!

Open the post
Continue the discussion in Discord
Like what we're doing?
Star us on GitHub!

Star

Connect with the Payload Community on Discord

Discord

online

Can't find what you're looking for?

Get help straight from the Payload team with an Enterprise License.