AccessKeyId and SecretAccessKey param for aws

pull/218/head
Frostebite 2021-01-31 20:14:20 +00:00
parent 4518ecd122
commit 9d750597a3
6 changed files with 27 additions and 2 deletions

View File

@ -50,6 +50,9 @@ jobs:
UNITY_LICENSE: ${{ secrets.UNITY_LICENSE }}
with:
remote: aws
awsRegion: eu-west-1
awsAccessKeyId: ${{ secrets.AWS_ACCESS_KEY_ID }}
awsSecretAccessKey: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
projectPath: ${{ matrix.projectPath }}
unityVersion: ${{ matrix.unityVersion }}
targetPlatform: ${{ matrix.targetPlatform }}

View File

@ -42,6 +42,14 @@ inputs:
default: 'eu-west-1'
required: false
description: ''
awsAccessKeyId:
default: ''
required: false
description: 'AWS Access Key Id'
awsAccessKey:
default: ''
required: false
description: 'AWS Access Key Secret'
kubeConfig:
default: ''
required: false

File diff suppressed because one or more lines are too long

View File

@ -7,7 +7,11 @@ const core = require('@actions/core');
class AWS {
static async runBuildJob(buildParameters, baseImage) {
SDK.config.update({ region: buildParameters.awsRegion });
SDK.config.update({
region: buildParameters.awsRegion,
secretAccessKey: buildParameters.awsSecretAccessKey,
accessKeyId: buildParameters.awsAccessKeyId,
});
await this.run(buildParameters.awsStackName, baseImage.toString());
}

View File

@ -51,6 +51,8 @@ class BuildParameters {
remote: Input.remote,
awsStackName: Input.awsStackName,
awsRegion: Input.awsRegion,
awsAccessKeyId: Input.awsAccessKeyId,
awsSecretAccessKey: Input.awsSecretAccessKey,
kubeContainerMemory: Input.kubeContainerMemory,
kubeContainerCPU: Input.kubeContainerCPU,
kubeVolumeSize: Input.kubeVolumeSize,

View File

@ -97,6 +97,14 @@ class Input {
return core.getInput('awsRegion') || '';
}
static get awsAccessKeyId() {
return core.getInput('awsAccessKeyId') || '';
}
static get awsSecretAccessKey() {
return core.getInput('awsSecretAccessKey') || '';
}
static get kubeConfig() {
return core.getInput('kubeConfig') || '';
}