Skip to content

Commit 0cf526a

Browse files
authored
Switch to LocalStack Pro image and add license requirement (#17)
* Switch to LocalStack Pro image and add license requirement * Hyperlink LOCALSTACK_AUTH_TOKEN and clean up localstack CLI prerequisite * Add auth token guard to start target
1 parent 668389a commit 0cf526a

File tree

3 files changed

+6
-4
lines changed

3 files changed

+6
-4
lines changed

Makefile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,8 @@ frontend:
5252

5353
## Start LocalStack in detached mode
5454
start:
55-
localstack start -d
55+
@test -n "${LOCALSTACK_AUTH_TOKEN}" || (echo "LOCALSTACK_AUTH_TOKEN is not set. Find your token at https://app.localstack.cloud/workspace/auth-token"; exit 1)
56+
@LOCALSTACK_AUTH_TOKEN=$(LOCALSTACK_AUTH_TOKEN) localstack start -d
5657

5758
## Stop the Running LocalStack container
5859
stop:

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,8 @@ The following diagram shows the architecture that this sample application builds
2828

2929
## Prerequisites
3030

31-
- [`localstack` CLI](https://docs.localstack.cloud/getting-started/installation/#localstack-cli) with a [`LOCALSTACK_AUTH_TOKEN`](https://docs.localstack.cloud/getting-started/auth-token/).
31+
- A valid [LocalStack for AWS license](https://localstack.cloud/pricing). Your license provides a [`LOCALSTACK_AUTH_TOKEN`](https://docs.localstack.cloud/getting-started/auth-token/) to activate LocalStack.
32+
- [`localstack` CLI](https://docs.localstack.cloud/getting-started/installation/#localstack-cli).
3233
- [AWS CLI](https://docs.localstack.cloud/user-guide/integrations/aws-cli/) with the [`awslocal` wrapper](https://docs.localstack.cloud/user-guide/integrations/aws-cli/#localstack-aws-cli-awslocal).
3334
- [Terraform](https://docs.localstack.cloud/user-guide/integrations/terraform/) with the [`tflocal`](https://github.com/localstack/terraform-local) wrapper.
3435
- [Maven 3.8.5+](https://maven.apache.org/install.html) & [Java 17](https://www.java.com/en/download/help/download_options.html)

docker-compose.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ version: "3.9"
33
services:
44
localstack:
55
container_name: localstack
6-
image: localstack/localstack:latest
6+
image: localstack/localstack-pro:latest
77
ports:
88
- "127.0.0.1:4566:4566" # LocalStack Gateway
99
- "127.0.0.1:4510-4559:4510-4559" # external services port range
@@ -12,7 +12,7 @@ services:
1212
- DOCKER_HOST=unix:///var/run/docker.sock #unix socket to communicate with the docker daemon
1313
- LOCALSTACK_HOST=localstack # where services are available from other containers
1414
- ENFORCE_IAM=1 # enforce IAM policies
15-
# - LOCALSTACK_AUTH_TOKEN=${LOCALSTACK_AUTH_TOKEN}
15+
- LOCALSTACK_AUTH_TOKEN=${LOCALSTACK_AUTH_TOKEN:?}
1616
volumes:
1717
- "${LOCALSTACK_VOLUME_DIR:-./volume}:/var/lib/localstack"
1818
- "/var/run/docker.sock:/var/run/docker.sock"

0 commit comments

Comments
 (0)