Skip to content

Commit 2d7c1df

Browse files
Try running localhost using the action localstack provides, rather than in docker.
1 parent 62019c6 commit 2d7c1df

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

.github/workflows/stage-4-acceptance.yaml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -111,7 +111,7 @@ jobs:
111111
needs: environment-set-up
112112
timeout-minutes: 10
113113
env:
114-
LOCALSTACK_INTERNAL_DYNAMODB_ENDPOINT: http://localstack:4566/
114+
RUNNING_LOCALSTACK_URL: http://localstack:4566/
115115
steps:
116116
- name: "Checkout code"
117117
uses: actions/checkout@v4
@@ -124,6 +124,11 @@ jobs:
124124
with:
125125
name: lambda
126126
path: dist/
127+
- name: Start LocalStack
128+
uses: LocalStack/[email protected]
129+
with:
130+
image-tag: 'latest'
131+
install-awslocal: 'true'
127132
- name: "Run integration test"
128133
run: |
129134
make test-integration

tests/integration/conftest.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@
2020

2121
@pytest.fixture(scope="session")
2222
def localstack(docker_ip, docker_services) -> URL:
23+
if url := os.getenv("RUNNING_LOCALSTACK_URL", None):
24+
logger.info("localstack already running on %s", url)
25+
return URL(url)
2326
logger.info("Starting localstack")
2427
port = docker_services.port_for("localstack", 4566)
2528
url = URL(f"http://{docker_ip}:{port}")

0 commit comments

Comments
 (0)