fix: Upgrading Terraform and starting to extend.

This commit is contained in:
James Wells 2021-09-18 20:20:26 -07:00
parent 643267caba
commit 0557021282
Signed by: jwells
GPG key ID: 73196D10B8E65666
3 changed files with 23 additions and 13 deletions

View file

@ -53,16 +53,26 @@ steps:
- trivy fs --skip-update --exit-code 1 --severity CRITICAL,HIGH .
# Build new container image.
- docker buildx build --push --platform linux/amd64 --progress plain --build-arg SEMVER="${DRONE_SEMVER}" -t ${DRONE_REPO}:latest -t ${DRONE_REPO}:${DRONE_SEMVER} -f docker/Dockerfile .
# - docker buildx build --push --platform linux/amd64 --progress plain --build-arg SEMVER="${DRONE_SEMVER}" -t "${DRONE_REPO}:latest" -t "${DRONE_REPO}:${DRONE_SEMVER}" -f docker/Dockerfile .
- docker buildx build --platform linux/amd64 --progress plain --build-arg SEMVER="dev" -t "${DRONE_REPO}:dev" -f docker/Dockerfile .
# Perform image security check of lower level vulnerabilities. This will not break the build, we just want this information, just in case.
- trivy image --skip-update --exit-code 0 --severity UNKNOWN,LOW,MEDIUM,HIGH ${DRONE_REPO}:${DRONE_SEMVER}
- trivy image --skip-update --exit-code 0 --severity UNKNOWN,LOW,MEDIUM,HIGH "${DRONE_REPO}:dev"
# Perform image security check of higher level vulnerabilities. This can break the build.
- trivy image --skip-update --exit-code 1 --severity CRITICAL ${DRONE_REPO}:${DRONE_SEMVER}
- trivy image --skip-update --exit-code 1 --severity CRITICAL "${DRONE_REPO}:dev"
# name: Create Test Environment
# image: dragonheim/terraform:latest
- name: Create Test Environment
image: dragonheim/terraform:latest
volumes:
- name: dockersock
path: /var/run/docker.sock
environment:
TRIVY_QUIET: true
commands:
- cd tfenv
- terraform init
- terraform plan
- name: Notify Datadog That We Have Completed
image: masci/drone-datadog

View file

@ -14,7 +14,7 @@ RUN go build -o /gagent/bin/gagent -ldflags "-X main.semVER=${SEMVER}" gagent/ma
RUN strip /gagent/bin/gagent
FROM alpine:3.14
ARG vernum
ARG SEMVER
LABEL Name="G'Agent"
LABEL Maintainer="jwells@dragonheim.net"
LABEL License="MIT License"

View file

@ -1,9 +1,9 @@
terraform {
required_version = ">= 1.0.0"
required_providers {
aws = {
source = "hashicorp/aws"
version = "~> 3.46.0"
}
}
required_version = ">= 1.0.7"
required_providers {
aws = {
source = "hashicorp/aws"
version = "~> 3.59.0"
}
}
}