In this brief article, I'll show how to launch your own Feathers instance on Digital Ocean.
Similar to Heroku and other PaaS (Platform-as-a-Service) providers, with the DigitalOcean App service, it's quite easy and straightforward to deploy an application. Digital Ocean provides a full workflow to add in environment variables, add a managed database, build on code push, and to deploy your application. If you don't want to deal with the stress of CI/CD (continuous integration/continuous delivery) and DevOps for an application, this may be a good option.
To get started, I generated a basic Feathers application using the following settings:
feathers generate app
This scaffolded a barebones application.
I updated the
Then I pushed this to my github repo.
To create a new App, on the home screen, click the Create App button.
This will walk you through creating an app.
The first step will be to connect your Github to Digital Ocean.
Follow the prompts to authorize your account, and either allow access to all repositories or only select repositories.
Select the repository with your feathers app.
You'll be asked to name your application, select a region, and select a branch to deploy your application from.
You can also decide if you want Digital Ocean to automatically rebuild your application and deploy it for you once you push a new commit.
Digital Ocean will attempt to detect the type of application you are trying to run. It should detect that you have a Node.js based application and offer some default options.
Update the settings as needed.
Depending on your application, you may need to update the Environment Variables, Build Commands, Run Command, and Port.
Environment variables should be used to store 3rd-party API credentials and database settings.
For the default Feathers application, at a minimum, you'll need to update the port to 3030, which is the default setting for a Feathers Application (though you can change it if you choose).
Finally, you'll be asked to select a plan. Choose one that meets your needs. If you're participating in the hackathon, you'll be given $50 credit for 60 days to use.
Once you're ready, hit the magic button: Launch Basic App.
Take a look at my deployment:
It's available here:
Here's the repo used:
This project uses Feathers. An open source web framework for building modern real-time applications.
Getting up and running is as easy as 1, 2, 3.
Install your dependencies
cd path/to/do-feathers npm install
Start your app
npm test and all your tests in the
test/ directory will be run.
Feathers has a powerful command line interface. Here are a few things it can do:
$ npm install -g @feathersjs/cli # Install Feathers CLI $ feathers generate service # Generate a new Service $ feathers generate hook # Generate a new Hook $ feathers help # Show all commands
For more information on all the things you can do with Feathers visit docs.feathersjs.com.
I don't plan to keep it up long though, as I hope to deploy another app for the hackathon, so don't be surprised if it's no longer available by the time you read this!
Let me know if you run into any issues. Happy Hacking!