Skip to content

Commit

Permalink
Merge branch 'branch/v6.2' into adam/docs/62editpass5
Browse files Browse the repository at this point in the history
  • Loading branch information
inertial-frame authored Jun 14, 2021
2 parents 5fe1d17 + 60f9e1c commit 3044813
Show file tree
Hide file tree
Showing 50 changed files with 496 additions and 283 deletions.
59 changes: 31 additions & 28 deletions .drone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ steps:
path: /var/run
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: tmpfs
path: /tmpfs
Expand Down Expand Up @@ -279,7 +279,7 @@ steps:
path: /var/run
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: tmpfs
path: /tmpfs
Expand Down Expand Up @@ -407,7 +407,7 @@ steps:
- failure
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: dockersock
path: /var/run
Expand Down Expand Up @@ -501,7 +501,7 @@ steps:
- failure
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: dockersock
path: /var/run
Expand Down Expand Up @@ -599,7 +599,7 @@ steps:
- failure
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: dockersock
path: /var/run
Expand Down Expand Up @@ -693,7 +693,7 @@ steps:
- failure
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: dockersock
path: /var/run
Expand Down Expand Up @@ -884,7 +884,7 @@ steps:
- failure
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: dockersock
path: /var/run
Expand Down Expand Up @@ -978,7 +978,7 @@ steps:
- failure
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: dockersock
path: /var/run
Expand Down Expand Up @@ -1305,7 +1305,7 @@ steps:
target: teleport/tag/${DRONE_TAG##v}
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: dockersock
path: /var/run
Expand Down Expand Up @@ -1401,7 +1401,7 @@ steps:
target: teleport/tag/${DRONE_TAG##v}
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: dockersock
path: /var/run
Expand Down Expand Up @@ -1500,7 +1500,7 @@ steps:
target: teleport/tag/${DRONE_TAG##v}
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: dockersock
path: /var/run
Expand Down Expand Up @@ -1598,7 +1598,7 @@ steps:
target: teleport/tag/${DRONE_TAG##v}
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: dockersock
path: /var/run
Expand Down Expand Up @@ -1718,7 +1718,7 @@ steps:
target: teleport/tag/${DRONE_TAG##v}
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: tmpfs
path: /tmpfs
Expand Down Expand Up @@ -1840,7 +1840,7 @@ steps:
target: teleport/tag/${DRONE_TAG##v}
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: tmpfs
path: /tmpfs
Expand Down Expand Up @@ -1956,7 +1956,7 @@ steps:
target: teleport/tag/${DRONE_TAG##v}
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: dockersock
path: /var/run
Expand Down Expand Up @@ -2064,7 +2064,7 @@ steps:
target: teleport/tag/${DRONE_TAG##v}
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: dockersock
path: /var/run
Expand Down Expand Up @@ -2160,7 +2160,7 @@ steps:
target: teleport/tag/${DRONE_TAG##v}
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: dockersock
path: /var/run
Expand Down Expand Up @@ -2280,7 +2280,7 @@ steps:
target: teleport/tag/${DRONE_TAG##v}
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: tmpfs
path: /tmpfs
Expand Down Expand Up @@ -2396,7 +2396,7 @@ steps:
target: teleport/tag/${DRONE_TAG##v}
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: dockersock
path: /var/run
Expand Down Expand Up @@ -2878,7 +2878,7 @@ steps:
target: teleport/tag/${DRONE_TAG##v}
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: dockersock
path: /var/run
Expand Down Expand Up @@ -2974,7 +2974,7 @@ steps:
target: teleport/tag/${DRONE_TAG##v}
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: dockersock
path: /var/run
Expand Down Expand Up @@ -3085,7 +3085,7 @@ steps:
target: teleport/tag/${DRONE_TAG##v}
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: dockersock
path: /var/run
Expand Down Expand Up @@ -3196,7 +3196,7 @@ steps:
target: teleport/tag/${DRONE_TAG##v}
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: dockersock
path: /var/run
Expand Down Expand Up @@ -3316,7 +3316,7 @@ steps:
target: teleport/tag/${DRONE_TAG##v}
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: tmpfs
path: /tmpfs
Expand Down Expand Up @@ -3441,7 +3441,7 @@ steps:
target: teleport/tag/${DRONE_TAG##v}
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: tmpfs
path: /tmpfs
Expand Down Expand Up @@ -3541,7 +3541,7 @@ steps:
target: teleport/tag/${DRONE_TAG##v}
services:
- name: Start Docker
image: docker:dind
image: docker:20.10.6-dind
volumes:
- name: dockersock
path: /var/run
Expand Down Expand Up @@ -3579,6 +3579,7 @@ steps:
environment:
GITHUB_PRIVATE_KEY:
from_secret: GITHUB_PRIVATE_KEY
GOCACHE: /go/cache
commands:
- mkdir -p /go/src/github.com/gravitational/teleport
- cd /go/src/github.com/gravitational/teleport
Expand All @@ -3592,7 +3593,7 @@ steps:
- git submodule update --init --recursive webassets || true
- rm -f /root/.ssh/id_rsa
# create necessary directories
- mkdir -p /go/cache /go/artifacts
- mkdir -p /go/artifacts ${GOCACHE}
# set version
- if [[ "${DRONE_TAG}" != "" ]]; then echo "${DRONE_TAG##v}" > /go/.version.txt; else egrep ^VERSION Makefile | cut -d= -f2 > /go/.version.txt; fi; cat /go/.version.txt

Expand All @@ -3601,6 +3602,7 @@ steps:
environment:
UID: 1000
GID: 1000
GOCACHE: /go/cache
GOPATH: /go
OS: linux
ARCH: amd64
Expand All @@ -3625,6 +3627,7 @@ steps:
environment:
UID: 1000
GID: 1000
GOCACHE: /go/cache
GOPATH: /go
OS: linux
ARCH: amd64
Expand Down Expand Up @@ -4300,6 +4303,6 @@ volumes:
name: drone-s3-debrepo-pvc
---
kind: signature
hmac: 81e81a6ee7ef982ff05c6b1008572da8b23fab12647dec2500d769bf78d16e33
hmac: 500a3e3248826b7f7b1563d9fe6d6f04065767c60822b83080b1f574ca88edb4

...
8 changes: 7 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
# Changelog

## 6.2.2
## 6.2.4

This release of Teleport contains multiple improvements.

* Added support for `regexp.replace(variable, expression, replacement)` in role templates.

## 6.2.3

This release of Teleport contains multiple improvements.

Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
# Stable releases: "1.0.0"
# Pre-releases: "1.0.0-alpha.1", "1.0.0-beta.2", "1.0.0-rc.3"
# Master/dev branch: "1.0.0-dev"
VERSION=6.2.2
VERSION=6.2.3

DOCKER_IMAGE ?= quay.io/gravitational/teleport
DOCKER_IMAGE_CI ?= quay.io/gravitational/teleport-ci
Expand Down
8 changes: 4 additions & 4 deletions assets/aws/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ AWS_REGION ?= us-west-2
# This must be a _released_ version of Teleport, i.e. one which has binaries
# available for download on https://gravitational.com/teleport/download
# Unreleased versions will fail to build.
TELEPORT_VERSION ?= 5.1.2
TELEPORT_VERSION ?= 6.2.0

# Teleport UID is the UID of a non-privileged 'teleport' user
TELEPORT_UID ?= 1007
Expand Down Expand Up @@ -71,7 +71,7 @@ oss-ci-build:
.PHONY: change-amis-to-public-oss
change-amis-to-public-oss:
@echo "Making OSS AMIs public"
bash files/make-amis-public.sh oss
bash files/make-amis-public.sh oss $(DESTINATION_REGIONS)

# Build local 'debug' AMI
.PHONY: ent
Expand Down Expand Up @@ -99,12 +99,12 @@ ent-ci-build:
.PHONY: change-amis-to-public-ent
change-amis-to-public-ent:
@echo "Making Enterprise AMIs public"
bash files/make-amis-public.sh ent
bash files/make-amis-public.sh ent $(DESTINATION_REGIONS)

.PHONY: change-amis-to-public-ent-fips
change-amis-to-public-ent-fips:
@echo "Making FIPS Enterprise AMIs public"
bash files/make-amis-public.sh ent-fips
bash files/make-amis-public.sh ent-fips $(DESTINATION_REGIONS)


# Other helpers
Expand Down
15 changes: 8 additions & 7 deletions assets/aws/files/make-amis-public.sh
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
#!/bin/bash
#!/usr/bin/env bash
set -e

# Define list of regions to run in
REGION_LIST="us-east-1 us-east-2 us-west-1 us-west-2 ap-south-1 ap-northeast-2 ap-southeast-1 ap-southeast-2 ap-northeast-1 ca-central-1 eu-central-1 eu-west-1 eu-west-2 sa-east-1"

# Exit if oss/ent parameters not provided
if [[ "$1" == "" ]]; then
echo "Usage: $(basename $0) [oss/ent/ent-fips]"
# Exit if required parameters not provided
if [[ "$1" == "" ]] || [[ "$2" == "" ]]; then
echo "Usage: $(basename $0) [oss/ent/ent-fips] [comma-separated-destination-region-list]"
exit 1
else
RUN_MODE="$1"
REGION_LIST="$2"
fi

# Note: to run this script on MacOS you will need to install coreutils (using Brew), then edit the PATH in your shell's
# RC file to use coreutils versions first (something like "export PATH=/usr/local/opt/coreutils/libexec/gnubin:$PATH")
ABSPATH=$(readlink -f "$0")
SCRIPT_DIR=$(dirname "${ABSPATH}")
BUILD_DIR=$(readlink -f "${SCRIPT_DIR}/build")
Expand Down Expand Up @@ -42,6 +42,7 @@ fi
BUILD_TIMESTAMP=$(<"${TIMESTAMP_FILE}")

# Iterate through AMIs
IFS=","
for REGION in ${REGION_LIST}; do
AMI_ID=$(aws ec2 describe-images --region ${REGION} --filters "Name=name,Values=${NAME_FILTER}" "Name=tag:BuildTimestamp,Values=${BUILD_TIMESTAMP}" "Name=tag:BuildType,Values=${AMI_TAG}"| jq -r '.Images[0].ImageId')
if [[ "${AMI_ID}" == "" || "${AMI_ID}" == "null" ]]; then
Expand Down
8 changes: 7 additions & 1 deletion assets/aws/update-ami-ids.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
#!/bin/bash
#!/usr/bin/env bash
set -euo pipefail

# Note: to run this script on MacOS you will need to:
# - install gnu-sed (using Brew), then edit the PATH in your shell's RC file to use the GNU version first
# -- (something like "export PATH=/usr/local/opt/gnu-sed/libexec/gnubin:$PATH")
# - install findutils (using Brew), then edit the PATH in your shell's RC file to use the GNU version first
# -- (something like "export PATH=/usr/local/opt/findutils/libexec/gnubin:$PATH")

# shellcheck disable=SC2086
usage() { echo "Usage: $(basename $0) [-a <AWS account ID>] [-m <cloudformation/terraform>] [-t <oss/ent/ent-fips>] [-r <comma-separated regions>] [-v version]" 1>&2; exit 1; }
while getopts ":a:m:t:r:v:" o; do
Expand Down
4 changes: 4 additions & 0 deletions build.assets/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,10 @@ ifeq ("$(DRONE)","true")
UID := 1000
GID := 1000
NOROOT := -u 1000:1000
# if running in CI and the GOCACHE environment variable is not set, set it to a sensible default
ifeq ("$(GOCACHE)",)
GOCACHE := $(shell go env GOCACHE)
endif
# pass external gocache path through to docker containers
DOCKERFLAGS := $(DOCKERFLAGS) -v $(GOCACHE):/go/cache -e GOCACHE=/go/cache
endif
Expand Down
Loading

0 comments on commit 3044813

Please sign in to comment.