![]() You can use the below snippet to set up your inital secrets: NOTE: This step is mandatory if you're using the provided cloudformation template. If you'd prefer to keep your application configuration stored in secrets manager so you don't have to worry about distributing configuration with senstive information (Github PAT) to your server then it's recommended to store the configuration in Secrets Manager. "GOPROXY=direct " # if you want to disable module mothership checks go_binary_path: /usr/local/go/bin/go # path to go binary on server "GOSUMDB=off " # if you want to disable module checksums "GOPATH=/tmp/source " # location on server where `go get` will store # ahoy config file interval: 20 # seconds between trigger checks dynamodb_region: us-east-1 dynamodb_table: goarder-stage github_server: my. # hostname of private github server github_pat: AWOGOIAOCOKOWAQKVJBKELKALJKSEK # personal access token for GH server go_get_envs: For more in depth explanations of each field see the sample configuration files within those sections of the project. Here's example configs for ahoy and chook. Whether you're pushing config files to the server directly or storing in secrets manager we still neeed to build the config. Store this for later use when you're building the configuration for the ahoy service. You can read Github documentation to learn how to generate this but the gist is that you log in as whatever user you want to grant the access for and you go to the user settings > Developer settings > Personal Access Tokens and generate one from there. You are asked to provide a Github personal access token to the ahoy service so that it can pull code from your private repositories. Remember the name of the table you created for when you're building your configuration for ahoy and chook. ![]() key-schema AttributeName=repo,KeyType=HASH \ attribute-definitions AttributeName=repo,AttributeType=S \ The counter will be used by the application to know when to trigger go get on each repo. You should create this in the same account in which your infrastructure will run.īelow is the command to create the table and set the base counter value. You'll need to create a DynamoDB table to store the information about which repositories to display on the godocs server. Regardless of whether you do a manual install of each component or use the cloudformation template you'll need to set a few things ahead of time. This section will cover two ways of deploying the service-manual and via the cloudformation template. When it detects that a package was removed it removes that collection of files from the filesystem. When it sees that there is an update to the table it rescans the table and does a go get -ud on all of the repos in the table. ahoyĪhoy is a daemon that scans the DynamoDB table at an interval to determine whether or not to pull the latest packages down so that the godocs server can serve them. It also has a delete handler so that you can remove entries from the table. It then updates a counter so that anything consuming the table knows to do a rescan of the table and pull all of the latest godocs. chookĬhook is a web server that accepts incoming Github webhooks from a repository and then adds information about that repository to a DynamoDB table. This serves up an HTTP server with documentation for all of the packages in the local server's target folder. Godocs is a service wrapper around the pre-existing godocs package. godocs runs a godocs server from the same server as ahoyīelow is a more detailed explanation of each component.ahoy continuously scans the DynamoDB table and updates local repos on the server.chook listens for webhooks from your GitHub server and updates a DynamoDB table with repos.It's made up of a few services meant to be deployed to a server or set of servers. ![]() Goarder is a collection of services designed to work in concert as a web server that accepts incoming webhooks from a private GitHub server and then serve up the contents of those repositories as godocs.
0 Comments
Leave a Reply. |