This tutorial walks you through the steps needed to setup and deploy a single-node Offen instance on Heroku using PostgreSQL for storing data.
All resources created in this tutorial are free of charge. You might want to upgrade some of them to another plan with costs when running Offen in production though. A single Hobby Dyno ($7 at the time of writing) should be beefy enough to handle most traffic scenarios and will also give you free and managed SSL for a custom domain.
- Deploy our template repository
- Set the configuration values
- Deploy the app
- Creating an account
- Run Offen on your own domain
To follow the steps in this tutorial you will need to have created an account with Heroku.
You can automatically deploy our template repository to Heroku using this button:
Below you will find what you need to do next:
Heroku will now ask you for a name for you instance (you can call this something like
my-offen for example), the region where to deploy (choose something the one that is geographically close to your users), and a few configuration values:
Offen needs to send transactional email for the following features:
- Inviting a new user to an account
- Resetting your password in case you forgot it
To enable this, you need supply SMTP credentials to Offen, namely Host, User, Password and Port to the setup form. If you do not know which values to use right now, you can start by using your personal mail account or create a new mailbox using your default email provider.
If you need to look these up, and don’t want to do it right away, you can always add these at a later time. Remember though that you cannot reset account passwords or invite users until email is configured.
You are now ready to press the “Deploy app” button. Building the application can take a little while, but you will see the interface updating while Offen is being installed for you.
The final step for your installation is now to create an account that you can use to collect usage data and log in. To do so, head to
/setup/ on your newly installed instance by clicking the “View app” button once installation has finished.
Create your first account and a user by filling and submitting the form. You can always create more accounts and add other users later.
You can now head to the running application at
https://<your-provided-app-name>.herokuapp.com/login and login using your given credentials.
In a real world setup, you will likely want to make Offen available as a subdomain of your own domain.
To setup DNS first configure Heroku to use your desired custom domain in your app’s settings. Now, you can set a CNAME record with your domain registrar from your desired domain to the target given in the response.
Offen requires to be served via SSL. In case you are on a paid plan, Heroku offers free Certificate Management for your domain and there is nothing you need to other than enable it. In case you are using the free plan, you can use self-signed certificates. Instructions can be found in the Heroku documentation on the topic.