Skip to content

Commit

Permalink
Update examples (#170)
Browse files Browse the repository at this point in the history
* add apps

* remove apps and fix path_prefix

* remove apps from common, fix argocd and argoproj

* fix argocd ref

* fix argo default branch

* remove jenkinsfile

* update github actions for common example
  • Loading branch information
Dmitriy Kharlamov authored Mar 20, 2021
1 parent b9c336f commit 66920d4
Show file tree
Hide file tree
Showing 14 changed files with 93 additions and 423 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/reviewdog.yml
Original file line number Diff line number Diff line change
Expand Up @@ -150,4 +150,4 @@ jobs:
run: |
tfenv use ${TERRAFORM_VERSION}
terraform init
terraform plan -var 'cluster_name=swiss-army-github-ci' -var 'domains=["edu.provectus.io"]'
terraform plan -var "zone_id=${ZONE_ID}" -var 'cluster_name=swiss-army-github-ci'
6 changes: 3 additions & 3 deletions examples/argocd-with-applications/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ That example is the standard deployment of the SAK cluster with managing applica

```
variable "cluster_name" {
default = "swiss-army-grusakov"
default = "swiss-army-kube"
}
variable "region" {
Expand Down Expand Up @@ -46,8 +46,8 @@ variable "domain_name" {
variable "argocd" {
default = {
repository = "swiss-army-kube"
branch = "feature/kubernetes-1.18"
owner = "gfrntz"
branch = "main"
owner = "provectus"
}
}
```
Expand Down
4 changes: 2 additions & 2 deletions examples/argocd-with-applications/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ module "argocd" {
}
}

#
#Apps
module "external_dns" {
depends_on = [module.argocd]

Expand Down Expand Up @@ -105,7 +105,7 @@ module "clusterwide" {
local.domain[0]
]
zone_id = module.external_dns.zone_id
validate_certificate = true
validate_certificate = true #Disable if used private DNS and validate it manually
wait_for_validation = false
tags = local.tags
}
Expand Down
4 changes: 2 additions & 2 deletions examples/argocd/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -38,14 +38,14 @@ module "kubernetes" {
}

module "argocd" {
depends_on = [module.network.vpc_id, module.kubernetes.cluster_name, data.aws_eks_cluster.cluster, data.aws_eks_cluster_auth.cluster]
depends_on = [module.network.vpc_id, module.kubernetes.cluster_name, data.aws_eks_cluster.cluster]
source = "github.com/provectus/sak-argocd"

branch = var.argocd.branch
owner = var.argocd.owner
repository = var.argocd.repository
cluster_name = module.kubernetes.cluster_name
path_prefix = "examples/argocd-with-applications/"
path_prefix = "examples/argocd/"

domains = local.domain
ingress_annotations = {
Expand Down
10 changes: 5 additions & 5 deletions examples/argocd/variables.tf
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
variable "cluster_name" {
default = "swiss-army-grusakov"
default = "swiss-army-kube"
type = string
description = "A name of the Amazon EKS cluster"
}
Expand All @@ -23,22 +23,22 @@ variable "environment" {
}

variable "project" {
default = "EDUCATION"
default = "SWISS"
type = string
description = "A value that will be used in annotations and tags to identify resources with the `Project` key"
}

variable "domain_name" {
default = "edu.provectus.io"
default = "swiss.sak.ninja"
type = string
description = "Default domain name"
}

variable "argocd" {
default = {
repository = "swiss-army-kube"
branch = "feature/kubernetes-1.18"
owner = "gfrntz"
branch = "master"
owner = "provectus"
}
type = map(string)
description = "A set of values for enabling deployment through ArgoCD"
Expand Down
4 changes: 2 additions & 2 deletions examples/argocd/versions.tf
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,12 @@ terraform {
}
random = {
source = "hashicorp/random"
version = "2.3.1"
version = "3.1.0"
}
template = {
source = "hashicorp/template"
version = "2.2.0"
}
}
required_version = ">= 0.13"
required_version = ">= 0.14"
}
87 changes: 42 additions & 45 deletions examples/argoproj/.terraform.lock.hcl

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion examples/argoproj/main.tf
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ module "kubernetes" {
vpc_id = module.network.vpc_id
subnets = module.network.private_subnets

on_demand_gpu_instance_type = ["g4dn.xlarge"]
on_demand_gpu_instance_type = "g4dn.xlarge"
}

module "argocd" {
Expand Down
8 changes: 4 additions & 4 deletions examples/argoproj/versions.tf
Original file line number Diff line number Diff line change
Expand Up @@ -22,16 +22,16 @@ terraform {
}
null = {
source = "hashicorp/null"
version = "2.1"
version = "2.1.2"
}
random = {
source = "hashicorp/random"
version = "2.1"
version = "3.1.0"
}
template = {
source = "hashicorp/template"
version = "2.1"
version = "2.2.0"
}
}
required_version = ">= 0.13"
required_version = ">= 0.14"
}
2 changes: 1 addition & 1 deletion examples/common/.terraform.lock.hcl

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 5 additions & 0 deletions examples/common/README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# About

simple installation of EKS and VPC


# Prerequisites

#### Helm v3
Expand Down
Loading

0 comments on commit 66920d4

Please sign in to comment.