-
-
Notifications
You must be signed in to change notification settings - Fork 11
/
Copy pathbuildspec_pwsh_linux.yml
59 lines (56 loc) · 3.96 KB
/
buildspec_pwsh_linux.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
# This is a simple CodeBuild build file for PowerShell.
# - pre_build step will ensure the Module Name / Version has not previously been built for production (plans to add this at a later time)
# - build step will perform Clean, ValidateRequirements, Analyze, Test, CreateHelp, Build, Archive
# https://docs.aws.amazon.com/codebuild/latest/userguide/build-env-ref-available.html
# https://docs.aws.amazon.com/codebuild/latest/userguide/build-spec-ref.html#runtime-versions-buildspec-file
# https://docs.aws.amazon.com/codebuild/latest/userguide/test-reporting.html
version: 0.2
phases:
install:
runtime-versions:
dotnet: 6.0
commands:
- pwsh -command './configure_aws_credential.ps1'
- pwsh -command './install_modules.ps1'
pre_build:
commands:
- pwsh -command '$PSVersionTable'
# uncomment the line below to explore what modules/variables/env variables are available in the build image
# - pwsh -command 'Get-Module -ListAvailable; (Get-Variable).GetEnumerator() | Sort-Object Name | Out-String; (Get-ChildItem env:*).GetEnumerator() | Sort-Object Name | Out-String'
- pwsh -command 'New-Item -Path /Test -ItemType Directory | Out-Null'
- pwsh -command 'New-Item -Path /Test/Animation -ItemType Directory | Out-Null'
- pwsh -command 'New-Item -Path /Test/Audio -ItemType Directory | Out-Null'
- pwsh -command 'New-Item -Path /Test/Documents -ItemType Directory | Out-Null'
- pwsh -command 'New-Item -Path /Test/PhotoGroup -ItemType Directory | Out-Null'
- pwsh -command 'New-Item -Path /Test/Photos -ItemType Directory | Out-Null'
- pwsh -command 'New-Item -Path /Test/VideoGroup -ItemType Directory | Out-Null'
- pwsh -command 'New-Item -Path /Test/Videos -ItemType Directory | Out-Null'
- pwsh -command 'New-Item -Path /Test/Stickers -ItemType Directory | Out-Null'
- aws s3 cp s3://$TESTFILES_S3_BUCKET/jean.gif /Test/Animation/jean.gif --quiet
- aws s3 cp s3://$TESTFILES_S3_BUCKET/Tobu-_-Syndec-Dusk-_NCS-Release_-YouTube.mp3 /Test/Audio/Tobu-_-Syndec-Dusk-_NCS-Release_-YouTube.mp3 --quiet
- aws s3 cp s3://$TESTFILES_S3_BUCKET/TestAudio.mp3 /Test/Audio/TestAudio.mp3 --quiet
- aws s3 cp s3://$TESTFILES_S3_BUCKET/customlog.txt /Test/Documents/customlog.txt --quiet
- aws s3 cp s3://$TESTFILES_S3_BUCKET/customlog2.txt /Test/Documents/customlog2.txt --quiet
- aws s3 cp s3://$TESTFILES_S3_BUCKET/beverly.jpg /Test/PhotoGroup/beverly.jpg --quiet
- aws s3 cp s3://$TESTFILES_S3_BUCKET/data.jpg /Test/PhotoGroup/data.jpg --quiet
- aws s3 cp s3://$TESTFILES_S3_BUCKET/geordi.jpg /Test/PhotoGroup/geordi.jpg --quiet
- aws s3 cp s3://$TESTFILES_S3_BUCKET/picard.jpg /Test/PhotoGroup/picard.jpg --quiet
- aws s3 cp s3://$TESTFILES_S3_BUCKET/riker.PNG /Test/PhotoGroup/riker.PNG --quiet
- aws s3 cp s3://$TESTFILES_S3_BUCKET/troi.jpg /Test/PhotoGroup/troi.jpg --quiet
- aws s3 cp s3://$TESTFILES_S3_BUCKET/worf.jpg /Test/PhotoGroup/worf.jpg --quiet
- aws s3 cp s3://$TESTFILES_S3_BUCKET/Photo.jpg /Test/Photos/Photo.jpg --quiet
- aws s3 cp s3://$TESTFILES_S3_BUCKET/first_contact.mp4 /Test/VideoGroup/first_contact.mp4 --quiet
- aws s3 cp s3://$TESTFILES_S3_BUCKET/root_beer.mp4 /Test/VideoGroup/root_beer.mp4 --quiet
- aws s3 cp s3://$TESTFILES_S3_BUCKET/Intro.mp4 /Test/Videos/Intro.mp4 --quiet
- aws s3 cp s3://$TESTFILES_S3_BUCKET/picard.webp /Test/Stickers/picard.webp --quiet
- aws s3 cp s3://$TESTFILES_S3_BUCKET/picard.webp /Test/Stickers/videosticker.webm --quiet
- aws s3 cp s3://$TESTFILES_S3_BUCKET/picard.webp /Test/Stickers/videosticker2.webm --quiet
- aws s3 cp s3://$TESTFILES_S3_BUCKET/picard.webp /Test/Stickers/animatedsticker.tgs --quiet
#- pwsh -command 'Invoke-Build -File .\src\PoshGram.build.Settings.ps1 -Task ValidateUniqueModuleVersion'
build:
commands:
- pwsh -command 'Invoke-Build -File .\src\PoshGram.build.ps1'
artifacts:
files:
- '**/*'
base-directory: 'src/Archive'