By Pico Alta
First of all let me say that I am new to the Digital Ocean platform. I am currently exploring the ‘apps’ section and I am currently trying to upload a static website to an app without needing the overhead of an additional github repository. I created an app with the ‘static assets’ setup. I am now trying to figure out where to upload the What I would ideally would do is run a command similar like I would do in Firebase. It would go something like this:
firebase login
firebase use <yourprojectid>
Then in the build folder created by running npm build
you would do the following:
firebase deploy
And it would upload the static build assets to the project.
Are similar commands available or do I need to use a public repo to host the website? Or can I drag and drop the files?
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
Accepted Answer
Hi there,
The DigitalOcean App Platform does not offer a drag-and-drop way of deploying sites.
The best way to deploy your static site to the App Platform is to use a GitHub repo. It does not have to be a public one, you can also use a private repository and keep your site files private.
After you’ve deployed your static site via GitHub, the next time you push your changes to your repository they will be automatically deployed to the App Platform, so it will be a matter of pushing your changes with:
git add .
git commit -m "your commit"
git push origin main
To get your changes from your local laptop to the App Platform.
You can define the build command in the App Platform so that you will not have to build your site locally and push the build folder, but it will be done on the App Platform itself.
Here is a step by step guide on how to do this:
Hope that this helps!
Best,
Bobby
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Full documentation for every DigitalOcean product.
The Wave has everything you need to know about building a business, from raising funding to marketing your product.
Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.
New accounts only. By submitting your email you agree to our Privacy Policy
Scale up as you grow — whether you're running one virtual machine or ten thousand.
Sign up and get $200 in credit for your first 60 days with DigitalOcean.*
*This promotional offer applies to new accounts only.