Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ The bootstrap installers download a released binary and the matching configurati
installer=$(mktemp) && trap 'rm -f "$installer"' EXIT &&
curl --proto '=https' --tlsv1.2 -fsSL -o "$installer" \
https://raw.githubusercontent.com/aws/aws-workload-credentials-provider/HEAD/install.sh &&
sudo AWCP_VERSION=3.1.1 bash "$installer" --config /path/to/config.toml
sudo AWCP_VERSION=3.1.2 bash "$installer" --config /path/to/config.toml
```

`AWCP_VERSION` is required and must name a released, tagged version\. The script downloads the binary for your architecture from the artifact host and the service units and install scripts from the `v$AWCP_VERSION` tag, then hands off to the `install` script described in [Step 2](#workload-credentials-provider-install)\. It also accepts `--dry-run`, which downloads everything, keeps it, and prints where, without installing\.
Expand All @@ -101,20 +101,20 @@ Run the following in an Administrator PowerShell session\. If the download fails
```powershell
$installer = Join-Path $env:TEMP "awcp-install.ps1"
Invoke-WebRequest -UseBasicParsing https://raw.githubusercontent.com/aws/aws-workload-credentials-provider/HEAD/install.ps1 -OutFile $installer
& $installer -Version 3.1.1 -Config C:\path\to\config.toml
& $installer -Version 3.1.2 -Config C:\path\to\config.toml
Remove-Item $installer
```

Download to a file rather than running the response directly: `[scriptblock]::Create()` on an empty body produces a script block that does nothing and reports success, so a truncated or empty download would read as a completed install\.

If your execution policy refuses to run the file, or refuses the unsigned install scripts it downloads, run it as `powershell.exe -ExecutionPolicy Bypass -File $installer -Version 3.1.1 -Config C:\path\to\config.toml`\. The script checks the policy before downloading anything and tells you the same thing\.
If your execution policy refuses to run the file, or refuses the unsigned install scripts it downloads, run it as `powershell.exe -ExecutionPolicy Bypass -File $installer -Version 3.1.2 -Config C:\path\to\config.toml`\. The script checks the policy before downloading anything and tells you the same thing\.

The script verifies the Authenticode signature on the binary and passes `-Config` and `-NoStart` through to the `install.ps1` script described in [Step 2](#workload-credentials-provider-install)\. It also accepts the following parameters:
- `-Version <x.y.z>` — Version to install; required, and may also be given as the `AWCP_VERSION` environment variable
- `-Force` — \(Optional\) Stop running provider services before installing
- `-DryRun` — \(Optional\) Download and verify, then stop without installing

Newer versions stop if administrators don't control the provider folder or `C:\ProgramData\AWS`, with or without `-Config`\. Without `-Config`, they also only use an existing config if administrators control it\. See the Windows EC2 tab in [Step 2](#workload-credentials-provider-install) for details and how to continue\.
Version 3\.1\.2 and later stop if administrators don't control the provider folder or `C:\ProgramData\AWS`, with or without `-Config`\. Without `-Config`, they also only use an existing config if administrators control it\. See the Windows EC2 tab in [Step 2](#workload-credentials-provider-install) for details and how to continue\.

------

Expand Down
4 changes: 2 additions & 2 deletions aws_certificatemanager_provider/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "aws_certificatemanager_provider"
version = "3.1.1"
version = "3.1.2"
edition = "2021"
license = "Apache-2.0"
description = "AWS ACM certificate management for the AWS Workload Credentials Provider."
Expand All @@ -26,7 +26,7 @@ tokio-util = "0.7.18"
# We are required to use the sha1 feature to decrypt the password protected private keys.
pkcs8 = { version = "0.10", features = ["encryption", "pem", "sha1-insecure"] }
pkcs5 = "0.7"
aws_workload_credentials_provider_common = { version = "3.1.1", path = "../aws_workload_credentials_provider_common" }
aws_workload_credentials_provider_common = { version = "3.1.2", path = "../aws_workload_credentials_provider_common" }

[dev-dependencies]
aws-smithy-mocks = "0.1"
Expand Down
4 changes: 2 additions & 2 deletions aws_secretsmanager_provider/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "aws_secretsmanager_provider"
version = "3.1.1"
version = "3.1.2"
edition = "2021"
license = "Apache-2.0"
description = "The AWS Secrets Manager Provider is a local HTTP service that you can install and use in your compute environments to read secrets from Secrets Manager and cache them in memory."
Expand Down Expand Up @@ -38,7 +38,7 @@ log4rs = { version = "1.2.0", features = ["gzip"] }
tokio-util = "0.7.18"
url = "2"
aws_secretsmanager_caching = { version = "2.1.0", path = "../aws_secretsmanager_caching" }
aws_workload_credentials_provider_common = { version = "3.1.1", path = "../aws_workload_credentials_provider_common" }
aws_workload_credentials_provider_common = { version = "3.1.2", path = "../aws_workload_credentials_provider_common" }
regex = "1"
rand = "0.10"

Expand Down
8 changes: 4 additions & 4 deletions aws_workload_credentials_provider/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "aws_workload_credentials_provider"
version = "3.1.1"
version = "3.1.2"
edition = "2021"
license = "Apache-2.0"
description = "AWS Workload Credentials Provider binary — unified entry point for ACM and Secrets Manager modes."
Expand All @@ -13,9 +13,9 @@ path = "src/main.rs"
fips = ["aws_certificatemanager_provider/fips", "aws_secretsmanager_provider/fips"]

[dependencies]
aws_workload_credentials_provider_common = { version = "3.1.1", path = "../aws_workload_credentials_provider_common" }
aws_certificatemanager_provider = { version = "3.1.1", path = "../aws_certificatemanager_provider" }
aws_secretsmanager_provider = { version = "3.1.1", path = "../aws_secretsmanager_provider" }
aws_workload_credentials_provider_common = { version = "3.1.2", path = "../aws_workload_credentials_provider_common" }
aws_certificatemanager_provider = { version = "3.1.2", path = "../aws_certificatemanager_provider" }
aws_secretsmanager_provider = { version = "3.1.2", path = "../aws_secretsmanager_provider" }

clap = { version = "4", features = ["derive"] }
tokio-util = "0.7.18"
Expand Down
2 changes: 1 addition & 1 deletion aws_workload_credentials_provider_common/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "aws_workload_credentials_provider_common"
version = "3.1.1"
version = "3.1.2"
edition = "2021"
license = "Apache-2.0"
description = "Common library for AWS Workload Credentials Provider configuration validation and shared utilities."
Expand Down
4 changes: 2 additions & 2 deletions install.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
.EXAMPLE
$installer = Join-Path $env:TEMP "awcp-install.ps1"
Invoke-WebRequest -UseBasicParsing https://raw.githubusercontent.com/aws/aws-workload-credentials-provider/HEAD/install.ps1 -OutFile $installer
& $installer -Version 3.1.1 -Config C:\path\to\config.toml
& $installer -Version 3.1.2 -Config C:\path\to\config.toml

Downloaded to a file rather than run from the response, because
[scriptblock]::Create() on an empty body silently does nothing and reports
Expand Down Expand Up @@ -88,7 +88,7 @@ if (-not $current.IsInRole([Security.Principal.WindowsBuiltInRole]::Administrato
}

if (-not $Version) {
throw "Pass -Version (or set AWCP_VERSION) to the version to install, as in -Version 3.1.1"
throw "Pass -Version (or set AWCP_VERSION) to the version to install, as in -Version 3.1.2"
}
# \z, not $: .NET's $ also matches before a trailing newline, so a version with
# one on the end would pass and then be interpolated into the download URLs.
Expand Down
8 changes: 4 additions & 4 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# installer=$(mktemp) && trap 'rm -f "$installer"' EXIT &&
# curl --proto '=https' --tlsv1.2 -fsSL -o "$installer" \
# https://raw.githubusercontent.com/aws/aws-workload-credentials-provider/HEAD/install.sh &&
# sudo AWCP_VERSION=3.1.1 bash "$installer" --config /path/to/config.toml
# sudo AWCP_VERSION=3.1.2 bash "$installer" --config /path/to/config.toml
#
# Downloaded to a file rather than piped into a shell, because `bash -c "$(curl
# ...)"` exits 0 when the download fails: the substitution is empty and nothing
Expand Down Expand Up @@ -78,7 +78,7 @@ main() {

version="${AWCP_VERSION:-}"
[ -n "$version" ] ||
die "set AWCP_VERSION to the version to install, as in 'sudo AWCP_VERSION=3.1.1 ...'"
die "set AWCP_VERSION to the version to install, as in 'sudo AWCP_VERSION=3.1.2 ...'"
# Pattern-matched rather than piped through grep: ^ and $ anchor each line,
# not the whole value, and sh builtins that expand \n would let a second
# line ride along behind a valid first one.
Expand Down Expand Up @@ -192,8 +192,8 @@ main() {

# Run through bash rather than exec'ing the file, so a noexec staging
# directory doesn't block the install. -e is explicit because `bash <file>`
# drops the shebang's flags, and releases up to 3.1.1 take errexit from the
# shebang alone: without it their installer runs past a rejected config and
# drops the shebang's flags, and released install scripts take errexit from
# the shebang alone: without it the installer runs past a rejected config and
# reports success.
bash -e "$configuration/install" "$@"
}
Expand Down
Loading