Skip to content

Commit

Permalink
feat: make into reusable module (#3)
Browse files Browse the repository at this point in the history
  • Loading branch information
jordan-acosta authored Mar 26, 2024
1 parent e36349c commit 7bcaff9
Show file tree
Hide file tree
Showing 5 changed files with 73 additions and 76 deletions.
42 changes: 42 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
---
name: release
on:
push:
branches:
- main

permissions:
contents: write
id-token: write
issues: read
packages: write
pull-requests: write
statuses: write
actions: read

concurrency:
group: ${{ github.workflow }}-${{ github.head_ref || github.ref }}
cancel-in-progress: false

defaults:
run:
shell: bash

jobs:
bump_tag:
name: bump tag
runs-on: ubuntu-latest
steps:
- name: Determine next version
id: semver
uses: ietf-tools/semver-action@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
branch: main
patchAll: true

- name: Push tag
uses: mathieudutour/[email protected]
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
custom_tag: ${{ steps.semver.outputs.nextStrict }}
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
.terraform
26 changes: 26 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,28 @@
# aws-eks-sandbox

Turnkey AWS EKS sandbox for Nuon apps.

## Usage

This module can be used via the [aws-eks](github.com/nuonco/sandboxes/aws-eks) project in [nuonco/sandboxes](github.com/nuonco/sandboxes).

```hcl
resource "nuon_app" "my_eks_app" {
name = "my_eks_app"
}
resource "nuon_app_sandbox" "main" {
app_id = nuon_app.my_eks_app.id
terraform_version = "v1.6.3"
public_repo = {
repo = "nuonco/sandboxes"
branch = "main"
directory = "aws-eks"
}
}
resource "nuon_app_runner" "main" {
app_id = nuon_app.my_eks_app.id
runner_type = "aws-eks"
}
```
76 changes: 0 additions & 76 deletions provider.tf

This file was deleted.

4 changes: 4 additions & 0 deletions versions.tf
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,10 @@ terraform {
aws = {
source = "hashicorp/aws"
version = ">= 4.0"
# This is required in order for the calling TF project to pass in both the default and the no_tags aws providers.
# Everything works fine in the calling project, but this causes `terraform validate` to fail when run against this module itself.
# Apparently, this is a bug in Terraform: https://github.com/hashicorp/terraform/issues/28490
configuration_aliases = [aws.no_tags]
}
helm = {
source = "hashicorp/helm"
Expand Down

0 comments on commit 7bcaff9

Please sign in to comment.