Last active
April 27, 2024 20:57
-
-
Save codingmatty/05922f9dc5dcb75bd8495d62b4211e27 to your computer and use it in GitHub Desktop.
Reference for setting up an application with Dokku
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# These lines only need to be ran once: | |
dokku plugin:install postgres | |
dokku letsencrypt:set --global email <your-email@email.com> | |
dokku letsencrypt:cron-job --add | |
# This script is meant to be used as a reference to setup an application with a postgres database pointing to a git repository with a Dockerfile | |
dokku apps:create linkwarden | |
dokku postgres:create linkwarden-db | |
dokku postgres:link linkwarden-db linkwarden | |
# Example of how to store files from the Docker container on the local machine | |
sudo mkdir -p /opt/linkwarden/data | |
dokku storage:mount linkwarden /opt/linkwarden/data:/data/data | |
dokku git:sync linkwarden git@github.com:linkwarden/linkwarden.git main | |
dokku config:set linkwarden NEXTAUTH_SECRET=`openssl rand -hex 32` | |
dokku ps:rebuild linkwarden | |
dokku ports:add linkwarden http:80:5000 | |
dokku domains:add linkwarden linkwarden.your-domain.com | |
dokku letsencrypt:enabled linkwarden |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment