Skip to content

Commit

Permalink
Merge branch 'main' into TheRealAmazonKendra/python-version
Browse files Browse the repository at this point in the history
  • Loading branch information
TheRealAmazonKendra authored Jul 26, 2023
2 parents bf8866d + ef6e5b1 commit 131cadf
Show file tree
Hide file tree
Showing 128 changed files with 3,743 additions and 3,554 deletions.
884 changes: 303 additions & 581 deletions .all-contributorsrc

Large diffs are not rendered by default.

9 changes: 9 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ updates:
labels:
- dependencies
- language/dotnet
- auto-approve

- package-ecosystem: nuget
directory: '/packages/@jsii/dotnet-runtime-test/test'
Expand All @@ -16,6 +17,7 @@ updates:
labels:
- dependencies
- language/dotnet
- auto-approve

- package-ecosystem: pip
directory: '/packages/@jsii/python-runtime'
Expand All @@ -24,6 +26,7 @@ updates:
labels:
- dependencies
- language/python
- auto-approve

- package-ecosystem: pip
directory: '/gh-pages'
Expand All @@ -32,6 +35,7 @@ updates:
labels:
- dependencies
- language/python
- auto-approve

- package-ecosystem: pip
directory: '/packages/jsii-pacmak/test/generated-code'
Expand All @@ -40,6 +44,7 @@ updates:
labels:
- dependencies
- language/python
- auto-approve

- package-ecosystem: pip
directory: '/packages/jsii-pacmak/lib/targets/python'
Expand All @@ -48,6 +53,7 @@ updates:
labels:
- dependencies
- language/python
- auto-approve
ignore:
- dependency-name: "setuptools"

Expand All @@ -58,6 +64,7 @@ updates:
labels:
- dependencies
- language/go
- auto-approve

- package-ecosystem: gomod
directory: '/packages/@jsii/go-runtime-test/project'
Expand All @@ -66,6 +73,7 @@ updates:
labels:
- dependencies
- language/go
- auto-approve
ignore:
- dependency-name: github.com/aws/jsii-runtime-go
- dependency-name: github.com/aws/jsii-runtime-go/*
Expand All @@ -77,3 +85,4 @@ updates:
interval: daily
labels:
- dependencies
- auto-approve
2 changes: 1 addition & 1 deletion .github/workflows/close-stale-issues.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:
# Issue timing
days-before-stale: 2
days-before-close: 5
days-before-ancient: 730
days-before-ancient: 36500

# If you don't want to mark a issue as being ancient based on a
# threshold of "upvotes", you can set this here. An "upvote" is
Expand Down
52 changes: 12 additions & 40 deletions .github/workflows/docker-images.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
name: Docker Images

on:
merge_group: {}
pull_request:
branches: [main, release]
push:
Expand All @@ -18,11 +19,12 @@ jobs:
id-token: write # Necessary for OIDC federation
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
node: ['14', '16', '18']
node: ['14', '16', '18', '20']
env:
# Node version whose images will be aliased without the -nodeXX segment
DEFAULT_NODE_MAJOR_VERSION: 14
DEFAULT_NODE_MAJOR_VERSION: 16
steps:
- name: Check out
uses: actions/checkout@v3
Expand All @@ -33,25 +35,25 @@ jobs:
run: |-
if [ "${{ github.event_name }}" = "push" ]; then
echo '⏯ Triggered by "push" event'
echo "::set-output name=result::true"
echo "result=true" >> $GITHUB_OUTPUT
elif [ "${{ github.base_ref }}" = "release" ]; then
echo '⏯ Triggered by "pull_request" event against "release"'
echo "::set-output name=result::true"
echo "result=true" >> $GITHUB_OUTPUT
else
# Fetch the base and head refs from origin so we can safely diff 'em
git fetch --depth=1 --quiet origin ${{ github.base_ref }}
# Otherwise, only run if the Dockerfile changed
changed=$(git diff --name-only origin/${{ github.base_ref }}..HEAD)
if grep Dockerfile <<< "${changed}" ; then
echo '⏯ Dockerfile changed'
echo "::set-output name=result::true"
echo "result=true" >> $GITHUB_OUTPUT
else
if grep '.github/workflows/docker-images.yml' <<< "${changed}" ; then
echo '⏯ docker-images workflow changed'
echo "::set-output name=result::true"
echo "result=true" >> $GITHUB_OUTPUT
else
echo '⏭ Dockerfile not changed'
echo "::set-output name=result::false"
echo "result=false" >> $GITHUB_OUTPUT
fi
fi
fi
Expand All @@ -65,10 +67,10 @@ jobs:
run: |-
if [[ "${{ secrets.AWS_ROLE_TO_ASSUME }}" != "" ]]; then
echo "🔑 Federation into AWS is possible (AWS_ROLE_TO_ASSUME is available)"
echo "::set-output name=enabled::true"
echo "enabled=true" >> $GITHUB_OUTPUT
else
echo "❌ Federation into AWS is disabled (no AWS_ROLE_TO_ASSUME secret found)"
echo "::set-output name=enabled::false"
echo "enabled=false" >> $GITHUB_OUTPUT
fi
# Federate into the PR Validation AWS Account
Expand Down Expand Up @@ -114,17 +116,6 @@ jobs:
[worker.oci]
max-parallelism = 1
# We only restore GH cache if we are not going to publish the result (i.e: PR validation)
- name: Set up layer cache
if: steps.should-run.outputs.result == 'true' && github.event_name != 'push'
uses: actions/cache@v3
with:
path: /tmp/.buildx-cache
key: ${{ runner.os }}-buildx-${{ hashFiles('superchain/*') }}-${{ github.sha }}
restore-keys: |-
${{ runner.os }}-buildx-${{ hashFiles('superchain/*') }}-
${{ runner.os }}-buildx-
# 1 pull per second from ECR Public
- name: Jitter the start time to avoid ECR Public throttling
id: sleep-start
Expand All @@ -136,7 +127,7 @@ jobs:
id: build-time
if: steps.should-run.outputs.result == 'true'
run: |-
echo "::set-output name=value::$(date -u +'%Y-%m-%dT%H:%M:%SZ')"
echo "value=$(date -u +'%Y-%m-%dT%H:%M:%SZ')" >> $GITHUB_OUTPUT
- name: Build Image
if: steps.should-run.outputs.result == 'true'
Expand All @@ -145,8 +136,6 @@ jobs:
--builder ${{ steps.buildx.outputs.name }} \
--platform linux/amd64,linux/arm64 \
--target superchain \
--cache-from type=local,src=/tmp/.buildx-cache \
--cache-to type=local,dest=/tmp/.buildx-cache-out \
--pull \
--build-arg BUILD_TIMESTAMP="${{ steps.build-time.outputs.value }}" \
--build-arg COMMIT_ID='${{ github.sha }}' \
Expand All @@ -161,8 +150,6 @@ jobs:
--builder ${{ steps.buildx.outputs.name }} \
--platform linux/amd64,linux/arm64 \
--target superchain \
--cache-from type=local,src=/tmp/.buildx-cache \
--cache-to type=local,dest=/tmp/.buildx-cache \
--build-arg BUILD_TIMESTAMP="${{ steps.build-time.outputs.value }}" \
--build-arg COMMIT_ID='${{ github.sha }}' \
--build-arg NODE_MAJOR_VERSION=${{ matrix.node }} \
Expand Down Expand Up @@ -194,8 +181,6 @@ jobs:
--builder ${{ steps.buildx.outputs.name }} \
--platform linux/amd64,linux/arm64 \
--target superchain \
--cache-from type=local,src=/tmp/.buildx-cache \
--cache-to type=local,dest=/tmp/.buildx-cache \
--push \
--build-arg BUILD_TIMESTAMP="${{ steps.build-time.outputs.value }}" \
--build-arg COMMIT_ID='${{ github.sha }}' \
Expand All @@ -211,8 +196,6 @@ jobs:
--builder ${{ steps.buildx.outputs.name }} \
--platform linux/amd64,linux/arm64 \
--target superchain \
--cache-from type=local,src=/tmp/.buildx-cache \
--cache-to type=local,dest=/tmp/.buildx-cache \
--push \
--build-arg BUILD_TIMESTAMP="${{ steps.build-time.outputs.value }}" \
--build-arg COMMIT_ID='${{ github.sha }}' \
Expand All @@ -233,8 +216,6 @@ jobs:
--builder ${{ steps.buildx.outputs.name }} \
--platform linux/amd64,linux/arm64 \
--target superchain \
--cache-from type=local,src=/tmp/.buildx-cache \
--cache-to type=local,dest=/tmp/.buildx-cache \
--push \
--build-arg BUILD_TIMESTAMP="${{ steps.build-time.outputs.value }}" \
--build-arg COMMIT_ID='${{ github.sha }}' \
Expand All @@ -250,8 +231,6 @@ jobs:
--builder ${{ steps.buildx.outputs.name }} \
--platform linux/amd64,linux/arm64 \
--target superchain \
--cache-from type=local,src=/tmp/.buildx-cache \
--cache-to type=local,dest=/tmp/.buildx-cache \
--push \
--build-arg BUILD_TIMESTAMP="${{ steps.build-time.outputs.value }}" \
--build-arg COMMIT_ID='${{ github.sha }}' \
Expand All @@ -261,10 +240,3 @@ jobs:
-f superchain/Dockerfile \
.
fi
# Replace the cache so it does not grow forever (should always be last!)
- name: Update layer cache
if: always() && steps.should-run.outputs.result == 'true'
run: |-
rm -rf /tmp/.buildx-cache
mv /tmp/.buildx-cache-out /tmp/.buildx-cache
1 change: 1 addition & 0 deletions .github/workflows/gh-pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
name: GitHub Pages

on:
merge_group: {}
pull_request:
branches: [main]
push:
Expand Down
18 changes: 18 additions & 0 deletions .github/workflows/handle-stale-discussions.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: HandleStaleDiscussions
on:
schedule:
- cron: '0 */4 * * *'
discussion_comment:
types: [created]

jobs:
handle-stale-discussions:
name: Handle stale discussions
runs-on: ubuntu-latest
permissions:
discussions: write
steps:
- name: Stale discussions action
uses: aws-github-ops/handle-stale-discussions@v1
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
Loading

0 comments on commit 131cadf

Please sign in to comment.