dokku shit
This commit is contained in:
61
dokku_notes
Normal file
61
dokku_notes
Normal file
@@ -0,0 +1,61 @@
|
||||
docker ps
|
||||
docker-compose exec web python manage.py makemigrations
|
||||
----------------------------------------
|
||||
wget https://raw.githubusercontent.com/dokku/dokku/v0.28.1/bootstrap.sh
|
||||
sudo DOKKU_TAG=v0.28.1 bash bootstrap.sh
|
||||
|
||||
cat ~/.ssh/authorized_keys | dokku ssh-keys:add admin
|
||||
|
||||
# server ip
|
||||
dokku domains:set-global ###severip
|
||||
|
||||
sudo dokku apps:create werkout
|
||||
sudo dokku plugin:install https://github.com/dokku/dokku-postgres.git
|
||||
sudo dokku postgres:create werkout
|
||||
sudo dokku plugin:install https://github.com/dokku/dokku-redis.git redis
|
||||
sudo dokku redis:create werkout
|
||||
|
||||
sudo dokku postgres:link werkout werkout
|
||||
sudo dokku redis:link werkout werkout
|
||||
|
||||
sudo dokku config:set --no-restart werkout SECRET_KEY=wz%C*@^$QLaFDc$u*wKZK9bV3CBMt7cj3wk2y^0vdu@2*pz7yco+p=7@sa%
|
||||
|
||||
#if dev env
|
||||
sudo dokku config:set --no-restart werkout IS_DEV=True
|
||||
|
||||
#push code
|
||||
# add werkoutDev and werkout to /etc/hosts
|
||||
'''
|
||||
Host brodkast
|
||||
HostName 45.33.120.174
|
||||
User root
|
||||
PreferredAuthentications publickey
|
||||
IdentityFile /Users/treyt/.ssh/bk_linode
|
||||
IdentitiesOnly yes
|
||||
AddKeysToAgent yes
|
||||
# ----------------------------
|
||||
Host brodkastDev
|
||||
HostName 45.79.26.38
|
||||
User root
|
||||
PreferredAuthentications publickey
|
||||
IdentityFile /Users/treyt/.ssh/bk_linode
|
||||
IdentitiesOnly yes
|
||||
AddKeysToAgent yes
|
||||
'''
|
||||
git push dokku@werkoutDev:werkout dokku
|
||||
git push dokku@werkout:werkout master
|
||||
|
||||
dokku run werkout python manage.py createsuperuser
|
||||
|
||||
#check if debug
|
||||
dokku run werkout python manage.py shell
|
||||
from django.conf import settings
|
||||
print(settings.DEBUG)
|
||||
exit()
|
||||
----------------------------------------
|
||||
sudo dokku domains:add werkout dev.werkout.io
|
||||
sudo dokku plugin:install https://github.com/dokku/dokku-letsencrypt.git
|
||||
sudo dokku config:set --no-restart --global DOKKU_LETSENCRYPT_EMAIL=werkoutdev@treymail.com
|
||||
sudo dokku letsencrypt:enable werkout
|
||||
sudo dokku letsencrypt:cron-job --add
|
||||
sudo dokku plugin:install https://github.com/dokku/dokku-redirect.git
|
||||
Reference in New Issue
Block a user