Skip to content

Automatically create a server on DigitalOcean and setup it

Notifications You must be signed in to change notification settings

BrunIF/create-server-doctl

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Automate server creation on DigitalOcean

Pre Install Server

Generate token on DO

Before installation, you need generate Token API -> Tokens -> Generate New Token. After run command:

doctl auth init

and paste your token

Generate SSH key

You need generate key in this folder, because it need to your future server. Run next command:

ssh-keygen -t rsa -b 4096 -C "autodeploy@yourcompany.com"

Now you must copy and paste your id_rsa.pub key on bitbucket.org (or github.com, gitlab.com,...)

Install Server

Edit file setup-server.sh and change variables value DROPLET_NAME, USER_NAME, DOMAIN_NAME, SUB_DOMAIN_NAME. On end of file userdata.sh you must change repository URL. After if you do that run script

./setup-server.sh

Wait 5-10 minutes and your server will be ready to use.

About

Automatically create a server on DigitalOcean and setup it

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages