Attention: this is the key used to sign the certificate requests, anyone holding this can sign certificates on your behalf. So keep it in a safe place!
openssl genrsa -des3 -out rootCA.key 4096| # If you come from bash you might have to change your $PATH. | |
| # export PATH=$HOME/bin:$HOME/.local/bin:/usr/local/bin:$PATH | |
| # Path to your Oh My Zsh installation. | |
| export ZSH="$HOME/.oh-my-zsh" | |
| # Set name of the theme to load --- if set to "random", it will | |
| # load a random theme each time Oh My Zsh is loaded, in which case, | |
| # to know which specific one was loaded, run: echo $RANDOM_THEME | |
| # See https://github.com/ohmyzsh/ohmyzsh/wiki/Themes |
| //AWS access credential validation | |
| provider "aws" { | |
| region = "us-west-2" | |
| shared_credentials_file = "~/.aws/credentials" | |
| profile = "default" | |
| } | |
| //Creates Prod VPC | |
| module "prod_vpc" { | |
| source = "./prod_vpc" |
| module "prod-openvpn-sg" { | |
| # source = "../modules/security-group" | |
| source = "github.com/terraform-aws-modules/terraform-aws-security-group" | |
| name = "${var.vpn_name}-sg" | |
| description = "Security Group for openvpn server Prod" | |
| vpc_id = var.vpc_id | |
| ingress_cidr_blocks = ["0.0.0.0/0"] # Actual IP range to support | |
| ingress_ipv6_cidr_blocks = ["::/0"] | |
| ingress_rules = ["openvpn-udp", "openvpn-tcp", "openvpn-https-tcp", "ssh-tcp"] | |
| egress_rules = ["all-all"] |
| # have this created before hand on AWS | |
| data "aws_eip" "Production-VPC-EIP" { | |
| tags = { | |
| Name = "Production-VPC-EIP" | |
| } | |
| } | |
| module "vpc" { | |
| # source = "../modules/vpc" | |
| source = "github.com/terraform-aws-modules/terraform-aws-vpc" |
| provider "aws" { | |
| region = "us-west-2" | |
| shared_credentials_file = "~/.aws/credentials" | |
| profile = "default" | |
| } | |
| resource "aws_s3_bucket" "terraform_state" { | |
| bucket = "terraform-backend-state" | |
| versioning { | |
| enabled = true |
| #!/bin/bash | |
| DISTRO_ID=$(awk -F= '/^ID=/{print $2}' /etc/os-release | sed -e 's/^"//' -e 's/"$//') | |
| # Install Salt Minion | |
| if [ $DISTRO_ID == centos ]; then | |
| echo "Do CENTOS stuff here" | |
| elif [ $DISTRO_ID == ubuntu ]; then | |
| echo "Do UBUNTU stuff here" |
| FROM ubuntu as ubuntu | |
| RUN apt-get update | |
| RUN apt-get install -y dpkg-dev wget gnupg2 curl | |
| ARG ubuntu_packages="wget htop default-jre-headless apt-transport-https nvidia-container-toolkit cuda-drivers libopengl0 linux-image-extra-virtual omnisci" | |
| WORKDIR /opt/packages/deb | |
| # Nvidia-Docker |
| # To list all Windows Features: dism /online /Get-Features | |
| # Get-WindowsOptionalFeature -Online | |
| # LIST All IIS FEATURES: | |
| # Get-WindowsOptionalFeature -Online | where FeatureName -like 'IIS-*' | |
| # NetFx dependencies | |
| dism /online /Enable-Feature /FeatureName:NetFx4 /All | |
| # ASP dependencies | |
| dism /online /enable-feature /all /featurename:IIS-ASPNET45 |
| pipeline { | |
| agent { label "build && windows" } | |
| stages { | |
| stage('Clean Workspace'){ | |
| steps { | |
| cleanWs() | |
| } | |
| } | |
| stage('Checkout'){ |