Skip to content

Commit cc8564f

Browse files
authored
Migrate storage client interface into enclaves repo (#305)
* chore: import storage-client-interface, restructure project into proper monorepo * chore: bump deps for storage client interface ahead of release * chore: rebase, remove use of deprecated function from aws_config * chore: add missing workflow permissions * chore: pin actions using gh-shaping
1 parent 8c0fb8a commit cc8564f

140 files changed

Lines changed: 481 additions & 208 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎.github/workflows/deploy-control-plane-image-production.yml‎

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -25,16 +25,16 @@ jobs:
2525
runs-on: ubuntu-latest
2626

2727
steps:
28-
- uses: actions/checkout@v6
28+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
2929
- name: Install MUSL Tools
3030
run: |
3131
sudo apt-get update
3232
sudo apt-get install -y musl-tools
33-
- uses: dtolnay/rust-toolchain@stable
33+
- uses: dtolnay/rust-toolchain@29eef336d9b2848a0b548edc03f92a220660cdb8 # stable
3434
with:
3535
targets: x86_64-unknown-linux-musl
3636
components: rustfmt
37-
- uses: Swatinem/rust-cache@v2
37+
- uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2.9.1
3838
with:
3939
shared-key: "standard-cache"
4040
- name: Test control plane
@@ -45,35 +45,35 @@ jobs:
4545
needs: [get-version, last_test]
4646

4747
steps:
48-
- uses: actions/checkout@v6
49-
- uses: Swatinem/rust-cache@v2
48+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
49+
- uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2.9.1
5050
- name: Install MUSL Tools
5151
run: |
5252
sudo apt-get update
5353
sudo apt-get install -y musl-tools
54-
- uses: dtolnay/rust-toolchain@stable
54+
- uses: dtolnay/rust-toolchain@29eef336d9b2848a0b548edc03f92a220660cdb8 # stable
5555
with:
5656
targets: x86_64-unknown-linux-musl
5757
- name: Build control plane
5858
run: cargo build -p control-plane --features enclave,network_egress,release_logging --release --target ${{ env.LINUX_TARGET }}
5959
- name: Move control-plane binary to root
6060
run: cp ./target/${{ env.LINUX_TARGET }}/release/control-plane ./control-plane
6161
- name: Configure Production AWS Credentials
62-
uses: aws-actions/configure-aws-credentials@v4
62+
uses: aws-actions/configure-aws-credentials@8df5847569e6427dd6c4fb1cf565c83acfa8afa7 # v6.0.0
6363
with:
6464
role-to-assume: ${{ secrets.AWS_ENCLAVES_PRODUCTION_OIDC_ROLE_ARN}}
6565
aws-region: us-east-1
6666
- name: Login to Amazon ECR
6767
id: login-ecr
68-
uses: aws-actions/amazon-ecr-login@v1
68+
uses: aws-actions/amazon-ecr-login@183a1442edf41672e66566b7fc560e297a290896 # v2.1.1
6969
- name: Build, and tag
7070
id: build-image
7171
env:
7272
ECR_REGISTRY: ${{ steps.login-ecr.outputs.registry }}
7373
ECR_REPOSITORY: evervault/control-plane
7474
VERSION_TAG: ${{ needs.get-version.outputs.version }}
7575
run: |
76-
docker build -f ./control-plane/Dockerfile -t $ECR_REGISTRY/$ECR_REPOSITORY:egress-enabled-$VERSION_TAG --pull --no-cache .
76+
docker build -f ./crates/control-plane/Dockerfile -t $ECR_REGISTRY/$ECR_REPOSITORY:egress-enabled-$VERSION_TAG --pull --no-cache .
7777
- name: Push control plane image to Amazon ECR
7878
id: push-control-plane
7979
env:
@@ -88,35 +88,35 @@ jobs:
8888
needs: [get-version, last_test]
8989

9090
steps:
91-
- uses: actions/checkout@v6
92-
- uses: Swatinem/rust-cache@v2
91+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
92+
- uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2.9.1
9393
- name: Install MUSL Tools
9494
run: |
9595
sudo apt-get update
9696
sudo apt-get install -y musl-tools
97-
- uses: dtolnay/rust-toolchain@stable
97+
- uses: dtolnay/rust-toolchain@29eef336d9b2848a0b548edc03f92a220660cdb8 # stable
9898
with:
9999
targets: x86_64-unknown-linux-musl
100100
- name: Build control plane
101101
run: cargo build -p control-plane --features enclave,release_logging --release --target ${{ env.LINUX_TARGET }}
102102
- name: Move control-plane binary to root
103103
run: cp ./target/${{ env.LINUX_TARGET }}/release/control-plane ./control-plane
104104
- name: Configure Production AWS Credentials
105-
uses: aws-actions/configure-aws-credentials@v4
105+
uses: aws-actions/configure-aws-credentials@8df5847569e6427dd6c4fb1cf565c83acfa8afa7 # v6.0.0
106106
with:
107107
role-to-assume: ${{ secrets.AWS_ENCLAVES_PRODUCTION_OIDC_ROLE_ARN }}
108108
aws-region: us-east-1
109109
- name: Login to Amazon ECR
110110
id: login-ecr
111-
uses: aws-actions/amazon-ecr-login@v1
111+
uses: aws-actions/amazon-ecr-login@183a1442edf41672e66566b7fc560e297a290896 # v2.1.1
112112
- name: Build, and tag
113113
id: build-image
114114
env:
115115
ECR_REGISTRY: ${{ steps.login-ecr.outputs.registry }}
116116
ECR_REPOSITORY: evervault/control-plane
117117
VERSION_TAG: ${{ needs.get-version.outputs.version }}
118118
run: |
119-
docker build -f ./control-plane/Dockerfile -t $ECR_REGISTRY/$ECR_REPOSITORY:egress-disabled-$VERSION_TAG --pull --no-cache .
119+
docker build -f ./crates/control-plane/Dockerfile -t $ECR_REGISTRY/$ECR_REPOSITORY:egress-disabled-$VERSION_TAG --pull --no-cache .
120120
- name: Push control plane image to Amazon ECR
121121
id: push-control-plane
122122
env:
@@ -139,13 +139,13 @@ jobs:
139139

140140
steps:
141141
- name: Configure Production AWS Credentials
142-
uses: aws-actions/configure-aws-credentials@v4
142+
uses: aws-actions/configure-aws-credentials@8df5847569e6427dd6c4fb1cf565c83acfa8afa7 # v6.0.0
143143
with:
144144
role-to-assume: ${{ secrets.AWS_ENCLAVES_PRODUCTION_OIDC_ROLE_ARN }}
145145
aws-region: us-east-1
146146
- name: Login to Amazon ECR
147147
id: login-ecr
148-
uses: aws-actions/amazon-ecr-login@v1
148+
uses: aws-actions/amazon-ecr-login@183a1442edf41672e66566b7fc560e297a290896 # v2.1.1
149149
- name: Push latest tag to image
150150
env:
151151
ECR_REGISTRY: ${{ steps.login-ecr.outputs.registry }}

‎.github/workflows/deploy-control-plane-image-staging.yml‎

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -20,16 +20,16 @@ jobs:
2020
runs-on: ubuntu-latest
2121

2222
steps:
23-
- uses: actions/checkout@v6
23+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
2424
- name: Install MUSL Tools
2525
run: |
2626
sudo apt-get update
2727
sudo apt-get install -y musl-tools
28-
- uses: dtolnay/rust-toolchain@stable
28+
- uses: dtolnay/rust-toolchain@29eef336d9b2848a0b548edc03f92a220660cdb8 # stable
2929
with:
3030
targets: x86_64-unknown-linux-musl
3131
components: rustfmt
32-
- uses: Swatinem/rust-cache@v2
32+
- uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2.9.1
3333
with:
3434
shared-key: "standard-cache"
3535
- name: Test control plane
@@ -42,12 +42,12 @@ jobs:
4242
semver: ${{ steps.get-version.outputs.semver }}
4343
semver-sha: ${{ steps.get-version.outputs.semver-sha }}
4444
steps:
45-
- uses: actions/checkout@v6
45+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
4646
- name: Install MUSL Tools
4747
run: |
4848
sudo apt-get update
4949
sudo apt-get install -y musl-tools
50-
- uses: dtolnay/rust-toolchain@stable
50+
- uses: dtolnay/rust-toolchain@29eef336d9b2848a0b548edc03f92a220660cdb8 # stable
5151
with:
5252
targets: x86_64-unknown-linux-musl
5353
- name: Parse semver from cargo.toml
@@ -64,13 +64,13 @@ jobs:
6464
needs: [last_test, get-release-semver]
6565

6666
steps:
67-
- uses: actions/checkout@v6
68-
- uses: Swatinem/rust-cache@v2
67+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
68+
- uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2.9.1
6969
- name: Install MUSL Tools
7070
run: |
7171
sudo apt-get update
7272
sudo apt-get install -y musl-tools
73-
- uses: dtolnay/rust-toolchain@stable
73+
- uses: dtolnay/rust-toolchain@29eef336d9b2848a0b548edc03f92a220660cdb8 # stable
7474
with:
7575
targets: x86_64-unknown-linux-musl
7676
- name: Build control plane
@@ -80,13 +80,13 @@ jobs:
8080
- name: Move control-plane binary to root
8181
run: cp ./target/${{ env.LINUX_TARGET }}/release/control-plane ./control-plane
8282
- name: Configure Staging AWS Credentials
83-
uses: aws-actions/configure-aws-credentials@v4
83+
uses: aws-actions/configure-aws-credentials@8df5847569e6427dd6c4fb1cf565c83acfa8afa7 # v6.0.0
8484
with:
8585
role-to-assume: ${{ secrets.AWS_ENCLAVES_STAGING_OIDC_ROLE_ARN }}
8686
aws-region: us-east-1
8787
- name: Login to Amazon ECR
8888
id: login-ecr
89-
uses: aws-actions/amazon-ecr-login@v1
89+
uses: aws-actions/amazon-ecr-login@183a1442edf41672e66566b7fc560e297a290896 # v2.1.1
9090
- name: Build, and tag
9191
id: build-image
9292
env:
@@ -95,7 +95,7 @@ jobs:
9595
IMAGE_TAG: ${{ github.sha }}
9696
SEMVER: ${{ needs.get-release-semver.outputs.semver }}
9797
run: |
98-
docker build -f ./control-plane/Dockerfile -t $ECR_REGISTRY/$ECR_REPOSITORY:egress-enabled-$IMAGE_TAG -t $ECR_REGISTRY/$ECR_REPOSITORY:egress-enabled-$SEMVER --pull --no-cache .
98+
docker build -f ./crates/control-plane/Dockerfile -t $ECR_REGISTRY/$ECR_REPOSITORY:egress-enabled-$IMAGE_TAG -t $ECR_REGISTRY/$ECR_REPOSITORY:egress-enabled-$SEMVER --pull --no-cache .
9999
- name: Push control plane image to Amazon ECR
100100
id: push-control-plane
101101
env:
@@ -111,13 +111,13 @@ jobs:
111111
runs-on: ubuntu-latest
112112
needs: [last_test, get-release-semver]
113113
steps:
114-
- uses: actions/checkout@v6
115-
- uses: Swatinem/rust-cache@v2
114+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
115+
- uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2.9.1
116116
- name: Install MUSL Tools
117117
run: |
118118
sudo apt-get update
119119
sudo apt-get install -y musl-tools
120-
- uses: dtolnay/rust-toolchain@stable
120+
- uses: dtolnay/rust-toolchain@29eef336d9b2848a0b548edc03f92a220660cdb8 # stable
121121
with:
122122
targets: x86_64-unknown-linux-musl
123123
- name: Build control plane
@@ -127,13 +127,13 @@ jobs:
127127
- name: Move control-plane binary to root
128128
run: cp ./target/${{ env.LINUX_TARGET }}/release/control-plane ./control-plane
129129
- name: Configure Staging AWS Credentials
130-
uses: aws-actions/configure-aws-credentials@v4
130+
uses: aws-actions/configure-aws-credentials@8df5847569e6427dd6c4fb1cf565c83acfa8afa7 # v6.0.0
131131
with:
132132
role-to-assume: ${{ secrets.AWS_ENCLAVES_STAGING_OIDC_ROLE_ARN }}
133133
aws-region: us-east-1
134134
- name: Login to Amazon ECR
135135
id: login-ecr
136-
uses: aws-actions/amazon-ecr-login@v1
136+
uses: aws-actions/amazon-ecr-login@183a1442edf41672e66566b7fc560e297a290896 # v2.1.1
137137
- name: Build, and tag
138138
id: build-image
139139
env:
@@ -142,7 +142,7 @@ jobs:
142142
IMAGE_TAG: ${{ github.sha }}
143143
SEMVER: ${{ needs.get-release-semver.outputs.semver }}
144144
run: |
145-
docker build -f ./control-plane/Dockerfile -t $ECR_REGISTRY/$ECR_REPOSITORY:egress-disabled-$IMAGE_TAG -t $ECR_REGISTRY/$ECR_REPOSITORY:egress-disabled-$SEMVER --pull --no-cache .
145+
docker build -f ./crates/control-plane/Dockerfile -t $ECR_REGISTRY/$ECR_REPOSITORY:egress-disabled-$IMAGE_TAG -t $ECR_REGISTRY/$ECR_REPOSITORY:egress-disabled-$SEMVER --pull --no-cache .
146146
- name: Push control plane image to Amazon ECR
147147
id: push-control-plane
148148
env:

‎.github/workflows/deploy-data-plane-binary-production.yml‎

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -28,24 +28,24 @@ jobs:
2828
needs: get-version
2929
runs-on: ubuntu-latest
3030
steps:
31-
- uses: actions/checkout@v6
31+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
3232

3333
- name: Inject Version
3434
run: |
3535
sh ./scripts/insert-data-plane-version.sh ${{ needs.get-version.outputs.version }}
3636
3737
- name: Configure Production AWS Credentials
38-
uses: aws-actions/configure-aws-credentials@v4
38+
uses: aws-actions/configure-aws-credentials@8df5847569e6427dd6c4fb1cf565c83acfa8afa7 # v6.0.0
3939
with:
4040
role-to-assume: ${{ secrets.AWS_ENCLAVES_PRODUCTION_OIDC_ROLE_ARN }}
4141
aws-region: us-east-1
4242

43-
- uses: Swatinem/rust-cache@v2
43+
- uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2.9.1
4444
- name: Install MUSL Tools
4545
run: |
4646
sudo apt-get update
4747
sudo apt-get install -y musl-tools
48-
- uses: dtolnay/rust-toolchain@stable
48+
- uses: dtolnay/rust-toolchain@29eef336d9b2848a0b548edc03f92a220660cdb8 # stable
4949
with:
5050
targets: x86_64-unknown-linux-musl
5151

@@ -105,7 +105,7 @@ jobs:
105105
]
106106
steps:
107107
- name: Configure Production AWS Credentials
108-
uses: aws-actions/configure-aws-credentials@v4
108+
uses: aws-actions/configure-aws-credentials@8df5847569e6427dd6c4fb1cf565c83acfa8afa7 # v6.0.0
109109
with:
110110
role-to-assume: ${{ secrets.AWS_ENCLAVES_PRODUCTION_OIDC_ROLE_ARN }}
111111
aws-region: us-east-1
@@ -127,9 +127,9 @@ jobs:
127127
environment:
128128
name: production
129129
steps:
130-
- uses: actions/checkout@v6
130+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
131131
- name: Configure Production AWS Credentials
132-
uses: aws-actions/configure-aws-credentials@v4
132+
uses: aws-actions/configure-aws-credentials@8df5847569e6427dd6c4fb1cf565c83acfa8afa7 # v6.0.0
133133
with:
134134
role-to-assume: ${{ secrets.AWS_ENCLAVES_PRODUCTION_OIDC_ROLE_ARN }}
135135
aws-region: us-east-1

‎.github/workflows/deploy-data-plane-binary-staging.yml‎

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ on:
44
push:
55
paths:
66
- .github/workflows/deploy-data-plane-binary-staging.yml
7-
- data-plane/**
8-
- shared/**
7+
- crates/data-plane/**
8+
- crates/shared/**
99
branches:
1010
- main
1111

@@ -24,12 +24,12 @@ jobs:
2424
semver: ${{ steps.get-version.outputs.semver }}
2525
semver-sha: ${{ steps.get-version.outputs.semver-sha }}
2626
steps:
27-
- uses: actions/checkout@v6
27+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
2828
- name: Install MUSL Tools
2929
run: |
3030
sudo apt-get update
3131
sudo apt-get install -y musl-tools
32-
- uses: dtolnay/rust-toolchain@stable
32+
- uses: dtolnay/rust-toolchain@29eef336d9b2848a0b548edc03f92a220660cdb8 # stable
3333
with:
3434
targets: x86_64-unknown-linux-musl
3535
- name: Parse semver from cargo.toml
@@ -45,24 +45,24 @@ jobs:
4545
runs-on: ubuntu-latest
4646
needs: [get-release-semver]
4747
steps:
48-
- uses: actions/checkout@v6
48+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
4949

5050
- name: Install MUSL Tools
5151
run: |
5252
sudo apt-get update
5353
sudo apt-get install -y musl-tools
5454
55-
- uses: dtolnay/rust-toolchain@stable
55+
- uses: dtolnay/rust-toolchain@29eef336d9b2848a0b548edc03f92a220660cdb8 # stable
5656
with:
5757
targets: x86_64-unknown-linux-musl
5858

5959
- name: Configure Staging AWS Credentials
60-
uses: aws-actions/configure-aws-credentials@v4
60+
uses: aws-actions/configure-aws-credentials@8df5847569e6427dd6c4fb1cf565c83acfa8afa7 # v6.0.0
6161
with:
6262
role-to-assume: ${{ secrets.AWS_ENCLAVES_STAGING_OIDC_ROLE_ARN }}
6363
aws-region: us-east-1
6464

65-
- uses: Swatinem/rust-cache@v2
65+
- uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2.9.1
6666
with:
6767
shared-key: "standard-cache"
6868

‎.github/workflows/deploy-runtime-installer.yml‎

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,11 @@ jobs:
2323
outputs:
2424
checksum: ${{ steps.compute-checksum.outputs.checksum }}
2525
steps:
26-
- uses: actions/checkout@v6
26+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
2727
- name: Build bundle using local action
2828
uses: ./installer
2929
- name: Upload bundle as artifact
30-
uses: actions/upload-artifact@v4
30+
uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0
3131
with:
3232
name: runtime-dependencies-${{github.sha}}.zip
3333
path: ./output/runtime-dependencies.tar.gz
@@ -40,11 +40,11 @@ jobs:
4040
runs-on: ubuntu-latest
4141
needs: [build-runtime-bundle]
4242
steps:
43-
- uses: actions/download-artifact@v4.1.7
43+
- uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c # v8.0.1
4444
with:
4545
name: runtime-dependencies-${{github.sha}}.zip
4646
- name: Configure AWS Credentials
47-
uses: aws-actions/configure-aws-credentials@v4
47+
uses: aws-actions/configure-aws-credentials@8df5847569e6427dd6c4fb1cf565c83acfa8afa7 # v6.0.0
4848
with:
4949
role-to-assume: ${{ secrets.AWS_ENCLAVES_OIDC_ROLE_ARN }}
5050
aws-region: us-east-1
@@ -58,9 +58,9 @@ jobs:
5858
runs-on: ubuntu-latest
5959
needs: [build-runtime-bundle, upload-runtime-bundle]
6060
steps:
61-
- uses: actions/checkout@v6
61+
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
6262
- name: Configure AWS Credentials
63-
uses: aws-actions/configure-aws-credentials@v4
63+
uses: aws-actions/configure-aws-credentials@8df5847569e6427dd6c4fb1cf565c83acfa8afa7 # v6.0.0
6464
with:
6565
role-to-assume: ${{ secrets.AWS_ENCLAVES_OIDC_ROLE_ARN }}
6666
aws-region: us-east-1

0 commit comments

Comments
 (0)