Skip to content

Commit b5b3985

Browse files
committed
hide packaging artefacts
1 parent 13e35ea commit b5b3985

File tree

2 files changed

+20
-14
lines changed

2 files changed

+20
-14
lines changed

Makefile

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,17 +27,18 @@ STACK_NAME ?= imagemagick-layer
2727

2828
result/bin/identify: all
2929

30-
layer.zip: result/bin/identify
30+
build/layer.zip: result/bin/identify build
3131
# imagemagick has a ton of symlinks, and just using the source dir in the template
3232
# would cause all these to get packaged as individual files.
3333
# (https://github.com/aws/aws-cli/issues/2900)
3434
#
3535
# This is why we zip outside, using -y to store them as symlinks
3636

37-
cd result && zip -ry ../layer.zip *
37+
cd result && zip -ry $(PROJECT_ROOT)$@ *
3838

39-
output.yaml: template.yaml result/bin/identify
39+
build/output.yaml: template.yaml build/layer.zip
4040
aws cloudformation package --template $< --s3-bucket $(DEPLOYMENT_BUCKET) --output-template-file $@
4141

42-
deploy: output.yaml
42+
deploy: build/output.yaml
4343
aws cloudformation deploy --template $< --stack-name $(STACK_NAME)
44+
aws cloudformation describe-stacks --stack-name $(STACK_NAME) --query Stacks[].Outputs --output table

template.yaml

Lines changed: 15 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,25 @@
1+
AWSTemplateFormatVersion: 2010-09-09
12
Transform: AWS::Serverless-2016-10-31
3+
Description: >
4+
Static build of ImageMagick for AWS Linux 2,
5+
including convert, mogrify and identify tools
6+
and support for jpeg, gif, png, tiff and webm formats.
7+
8+
Check out https://github.com/serverlesspub/imagemagick-aws-lambda-2
9+
for more information.
210
Resources:
311
ImageMagickLayer:
412
Type: AWS::Serverless::LayerVersion
513
Properties:
614
LayerName: image-magick
7-
Description: >
8-
9-
Static build of ImageMagick for AWS Linux 2,
10-
including convert, mogrify and identify tools
11-
and support for jpeg, gif, png, tiff and webm formats.
12-
13-
Check out https://github.com/serverlesspub/imagemagick-aws-lambda-2
14-
for more information.
15-
16-
ContentUri: layer.zip
15+
Description: Static build of ImageMagick for AWS Linux 2,
16+
ContentUri: build/layer.zip
1717
CompatibleRuntimes:
1818
- nodejs10.x
1919
LicenseInfo: https://imagemagick.org/script/license.php
2020
RetentionPolicy: Retain
21+
22+
Outputs:
23+
LayerVersion:
24+
Description: Layer ARN Reference
25+
Value: !Ref ImageMagickLayer

0 commit comments

Comments
 (0)