Giter Club home page Giter Club logo

openjdk-gradle-terraform's Introduction

openjdk-gradle-terraform

CircleCI

OpenJDK Docker image with Python 3, pip, Gradle, Terraform, Checkov and the AWS CLI tool. See Dockerfile for exact versions.

Written with the intention of creating a single, consistent CircleCI container image for Java applications that deploy their infrastructure with Terraform in the same pipeline (but are not necessarily deployed as containerized applications).

Published via CircleCI to Docker Hub.

Usage

Simple example of a CircleCI pipeline for a Gradle project dummy with a terraform subdirectory containing its infrastructure code that makes use of the aws-cli orb to set up credentials (using default environment variables configured in CircleCI):

version: 2.1

executors:
  openjdk-gradle-terraform:
    docker:
      - image: blairnangle/openjdk-gradle-terraform:latest

orbs:
  aws-cli: circleci/[email protected]

workflows:
  version: 2
  build_and_later_some_other_stuff:
    jobs:
      - build
      - infra

jobs:
  build:
    executor: openjdk-gradle-terraform
    steps:
      - checkout
      - run:
          name: Build
          command: gradle build
  infra:
    executor: openjdk-gradle-terraform
    working_directory: ~/dummy/terraform
    steps:
      - checkout:
          path: ~/dummy
      - aws-cli/setup
      - run:
         name: Initialize
         command: terraform init
      - run:
          name: Validate
          command: terraform validate
      - run:
          name: Check
          command: checkov -d .
      - run:
          name: Plan
          command: terraform plan --out plan.tf
      - run:
          name: Apply
          command: terraform apply plan.tf

The pipeline is basic (does not actually deploy an artifact, for example) and the planning and application of the Terraform infrastructure should probably be split into separate jobs, but it illustrates the tools that are made available to CircleCI by using the blairnangle/openjdk-gradle-terraform image.

License

Distributed under MIT License.

openjdk-gradle-terraform's People

Contributors

blairnangle avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.