Skip to content
This repository has been archived by the owner on Oct 26, 2024. It is now read-only.

Commit

Permalink
Image for clouddev. (#50)
Browse files Browse the repository at this point in the history
* instane type as variable in terraform config.

* use image instead of dockerfile for clouddev devcontainer.
  • Loading branch information
tbenthompson authored Aug 22, 2022
1 parent 3481917 commit 17a363a
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 8 deletions.
13 changes: 7 additions & 6 deletions .devcontainer/clouddev/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,13 @@
// https://github.com/microsoft/vscode-dev-containers/tree/v0.238.1/containers/ubuntu
{
"name": "clouddev",
"build": {
"dockerfile": "../../cloud/clouddev/Dockerfile",
// Update 'VARIANT' to pick an Ubuntu version: jammy / ubuntu-22.04, focal / ubuntu-20.04, bionic /ubuntu-18.04
// Use ubuntu-22.04 or ubuntu-18.04 on local arm64/Apple Silicon.
"args": { "VARIANT": "ubuntu-22.04" }
},
"image": "ghcr.io/confirm-solutions/clouddev:latest",
// "build": {
// "dockerfile": "../../cloud/clouddev/Dockerfile",
// // Update 'VARIANT' to pick an Ubuntu version: jammy / ubuntu-22.04, focal / ubuntu-20.04, bionic /ubuntu-18.04
// // Use ubuntu-22.04 or ubuntu-18.04 on local arm64/Apple Silicon.
// "args": { "VARIANT": "ubuntu-22.04" }
// },

// Use 'forwardPorts' to make a list of ports inside the container available locally.
// "forwardPorts": [],
Expand Down
2 changes: 1 addition & 1 deletion cloud/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ resource "aws_iam_instance_profile" "test_profile" {

resource "aws_instance" "app" {
ami = var.ami
instance_type = "t2.xlarge"
instance_type = var.instance_type
key_name = var.key_name
iam_instance_profile = aws_iam_instance_profile.test_profile.name

Expand Down
8 changes: 7 additions & 1 deletion cloud/variables.tf
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,10 @@ variable "image_name" {
type = string
default = "smalldev:latest"
description = "Name of the docker image on ECR to use."
}
}

variable "instance_type" {
type = string
default = "t2.xlarge"
description = "description"
}

0 comments on commit 17a363a

Please sign in to comment.