Project

General

Profile

Support #865

Updated by Daniel Curtis about 8 years ago

This is a guide for setting up a Hydra OAuth2 server on FreeBSD 10. 

 h2. Prepare the Environment 

 * Make sure the system is up to date: 
 <pre> 
 pkg update && pkg upgrade 
 </pre> 

 * Create a GOPATH folder: 
 mkdir ~/go 

 * Install a couple dependencies: 
 <pre> 
 pkg install go git 
 </pre> 

 * Edit the .cshrc file: 
 <pre> 
 vi ~/.cshrc 
 </pre> 
 #* Set the GOROOT and Go bin for the environment: 
 <pre> 
 set path = (/sbin /bin /usr/sbin /usr/bin /usr/games /usr/local/sbin /usr/local/bin $HOME/bin /usr/local/go/bin /home/bob/go/bin) /usr/local/go/bin) 
 setenv GOROOT /usr/local/go 
 setenv GOPATH $HOME/go 
 source ~/.cshrc 
 </pre> 

 h2. Install Hydra 

 * Download and install Hydra and Glide: 
 <pre> 
 go get github.com/ory-am/hydra 
 go get github.com/Masterminds/glide 
 cd $GOPATH/src/github.com/ory-am/hydra 
 glide install 
 go install github.com/ory-am/hydra 
 </pre> 

 * Test hydra: 
 <pre> 
 hydra 
 </pre> 

 h2. Resources 

 * https://github.com/ory-am/hydra 
 * https://github.com/Masterminds/glide 
 * https://golang.org/doc/install

Back