/atlas-examples

Public examples for using Atlas by HashiCorp

Primary LanguageHCLMozilla Public License 2.0MPL-2.0

Atlas Examples

This repository contains application and infrastructure examples for Atlas by HashiCorp.

Examples

Example Description Tools Used
HAProxy-Nodejs Deploy a HAProxy and Node.js application on AWS. Atlas, Consul, Packer, and Terraform
consul-cluster Deploy and bootstrap a consul-cluster in various configurations. Atlas, Consul, Packer, and Terraform
google-hyperspace Deploy a real-time multiplayer space shooter game to Google Compute Engine. Atlas, Packer, and Terraform
infrastructures Deploy full application architectures including database, cache, and messaging servers. Atlas, Consul, Packer, Terraform, and Vault
metamon Deploy a python web app to AWS using Ansible for configuration. Atlas, Packer, and Terraform
nomad-cluster Deploy and bootstrap a Nomad cluster on AWS. Atlas, Nomad, and Terraform
spark Deploy a Spark cluster to AWS. Atlas, Consul, consul-template, and Terraform

Setup

Examples should use common inputs and structures as much as possible. The most commonly used environment variables for the examples are listed and explained below.

Environment Variables

# For Atlas
ATLAS_TOKEN
ATLAS_USERNAME

# For AWS
AWS_ACCESS_KEY_ID
AWS_SECRET_ACCESS_KEY
AWS_DEFAULT_REGION

See the Environment variable article on Wikipedia for an explanation of how to set and use environment variables.

Atlas Variables

To generate an Atlas Token, visit your account page in Atlas.

Atlas Username can be either your personal username in Atlas (e.g., clstokes) or the name of the organization you belong to within Atlas (e.g., hashicorp).

Amazon Web Services Credentials

Visit the IAM Management Console and follow th instructions at Managing Access Keys for IAM Users.

Google Cloud Platform Credentials

Visit the Google Developers Console and follow the instructions at Service accounts.

Writing Examples

Pretty simple - create a folder named after the example. Add a README if setup is required, and add supporting files.

Please try to adhere to the above environment variables to keep projects consistent and easy to adopt.

Issues

To report issues (such as typographical errors or confusion) in these examples, please open a GitHub issue. For Atlas-specific support, please email support@hashicorp.com.

Documentation

Additional documentation on Atlas, Vagrant, Packer, Terraform, and Consul can be read here.