Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/rosesecurity/atmos.nvim
🚀 A lightweight, user-friendly Neovim plugin for easily navigating and managing Atmos stacks and components.
https://github.com/rosesecurity/atmos.nvim
atmos cloud neovim neovim-plugin telescope telescope-extension terraform
Last synced: 11 days ago
JSON representation
🚀 A lightweight, user-friendly Neovim plugin for easily navigating and managing Atmos stacks and components.
- Host: GitHub
- URL: https://github.com/rosesecurity/atmos.nvim
- Owner: RoseSecurity
- License: apache-2.0
- Created: 2024-09-19T15:35:25.000Z (about 2 months ago)
- Default Branch: main
- Last Pushed: 2024-10-17T18:15:27.000Z (26 days ago)
- Last Synced: 2024-11-02T02:05:19.406Z (11 days ago)
- Topics: atmos, cloud, neovim, neovim-plugin, telescope, telescope-extension, terraform
- Language: Lua
- Homepage:
- Size: 603 KB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# :rocket: atmos.nvim
A Neovim plugin that enables efficient navigation and management of Atmos stacks and components directly within your Neovim environment.
---
## :question: What is Atmos?
Atmos is a powerful infrastructure-as-code (IaC) tool that simplifies the management of cloud resources across multiple environments. It introduces two key concepts:
1. **Stacks**: Configuration blueprints that describe a cohesive collection of components. Stacks automate the deployment, management, and teardown of Terraform resources, ensuring uniform setups across different environments (e.g., `development`, `staging`, `production`).
2. **Components**: The building blocks of your infrastructure. Components define the business logic for provisioning common pieces of infrastructure, such as ECR repositories or EKS clusters.
This plugin enhances your Atmos workflow by providing quick and easy navigation of your Atmos stacks and components within Neovim.
## :exclamation: Features
- List and navigate Atmos stacks and components using Telescope
- Validate Atmos stacks directly from Neovim
- Quick access to stack and component definitions
- Seamless integration with your existing Neovim setup## Requirements
> [!IMPORTANT]
>
> - Neovim 0.8 or later
> - [Telescope.nvim](https://github.com/nvim-telescope/telescope.nvim)
> - [Atmos](https://atmos.tools/install/) installed and configured in your system## Installation
Using [packer.nvim](https://github.com/wbthomason/packer.nvim):
```lua
use {
'RoseSecurity/atmos.nvim',
requires = {'nvim-telescope/telescope.nvim'}
}
```Using [vim-plug](https://github.com/junegunn/vim-plug):
```sh
Plug 'nvim-telescope/telescope.nvim'
Plug 'RoseSecurity/atmos.nvim'
```For other package managers, please refer to their respective documentation for adding plugins.
## Setup
Add the following to your Neovim configuration:
```lua
require("atmos").setup({
base_path = "",
config_path = ""
})
```These correspond to the `ATMOS_CLI_CONFIG_PATH` environment variable, which is where to find `atmos.yaml`. It's the path to a folder where `atmos.yaml` CLI config file is located. The `ATMOS_BASE_PATH` is the base path to components and stacks folders.
## Usage
The plugin provides two main commands:
1. `:AtmosListStacks`
- Opens a Telescope picker listing all available Atmos stacks2. `:AtmosListComponents`
- Opens a Telescope picker listing all available Atmos components
- Selecting a component will navigate you to the component directory3. `:AtmosListVariables`
- Opens a Telescope picker with all available stacks
- After selecting the stack, a list of components for the stack will appear
- Once the component for the stack is selected, the variables and values will be displayed4. `:AtmosValidateStacks`
- Validate Atmos stack manifest configurationsYou can map these commands to key bindings for quicker access. For example:
```lua
vim.api.nvim_set_keymap('n', 'als', ':AtmosListStacks', { noremap = true, silent = true })
vim.api.nvim_set_keymap('n', 'alc', ':AtmosListComponents', { noremap = true, silent = true })
vim.api.nvim_set_keymap('n', 'alv', ':AtmosListVariables', { noremap = true, silent = true })
vim.api.nvim_set_keymap('n', 'av', ':AtmosValidateStacks', { noremap = true, silent = true })
```