Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: general update #87

Merged
merged 1 commit into from
Jun 17, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,4 @@ CREATE TABLE IF NOT EXISTS dog
id SERIAL PRIMARY KEY,
name TEXT NOT NULL,
characteristics TEXT[]
);
);
13 changes: 6 additions & 7 deletions development-environment/docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ version: "3"

services:
wiremock:
image: wiremock/wiremock:2.32.0-alpine
image: wiremock/wiremock:3.3.1-alpine
command: "--local-response-templating"
ports:
- "5050:8080"
Expand All @@ -12,19 +12,18 @@ services:
- dev

localstack:
image: localstack/localstack:1.4
image: localstack/localstack:3.1
ports:
- "127.0.0.1:4510-4559:4510-4559" # external service port range
- "127.0.0.1:4566:4566" # LocalStack Edge Proxy
environment:
- DEBUG=${DEBUG-}
- SERVICES=sns,sqs,s3,dynamodb
- DATA_DIR=${DATA_DIR-}
- LAMBDA_EXECUTOR=${LAMBDA_EXECUTOR-}
- HOST_TMP_FOLDER=${TMPDIR:-/tmp/}localstack
- DEBUG=${DEBUG:-0}
- SERVICES=sns,sqs,s3
- DOCKER_HOST=unix:///var/run/docker.sock
volumes:
- "${TMPDIR:-/tmp}/localstack:/var/lib/localstack"
- "/var/run/docker.sock:/var/run/docker.sock"
- ./localstack/start-localstack.sh:/etc/localstack/init/ready.d/start-localstack.sh
networks:
- dev

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,15 @@ awslocal sns create-topic --name COLIBRI_PROJECT_USER_CREATE
awslocal sqs create-queue --queue-name COLIBRI_PROJECT_USER_CREATE_APP_CONSUMER
awslocal sns subscribe --topic-arn arn:aws:sns:us-east-1:000000000000:COLIBRI_PROJECT_USER_CREATE \
--protocol sqs \
--notification-endpoint arn:aws:sqs:us-east-1:queue:COLIBRI_PROJECT_USER_CREATE_APP_CONSUMER

--notification-endpoint arn:aws:sqs:us-east-1:000000000000:COLIBRI_PROJECT_USER_CREATE_APP_CONSUMER

awslocal sns create-topic --name COLIBRI_PROJECT_FAIL_USER_CREATE
awslocal sqs create-queue --queue-name COLIBRI_PROJECT_FAIL_USER_CREATE_APP_CONSUMER
awslocal sqs create-queue --queue-name COLIBRI_PROJECT_FAIL_USER_CREATE_APP_CONSUMER_DLQ
awslocal sns subscribe --topic-arn arn:aws:sns:us-east-1:000000000000:COLIBRI_PROJECT_FAIL_USER_CREATE \
--protocol sqs \
--notification-endpoint arn:aws:sqs:us-east-1:queue:COLIBRI_PROJECT_FAIL_USER_CREATE_APP_CONSUMER
--notification-endpoint arn:aws:sqs:us-east-1:000000000000:COLIBRI_PROJECT_FAIL_USER_CREATE_APP_CONSUMER

awslocal s3api create-bucket --bucket my-bucket --acl public-read

echo "localstack emulator started"
echo "localstack emulator started"
2 changes: 1 addition & 1 deletion development-environment/rest/resp.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"msg": "test file"
}
}
2 changes: 1 addition & 1 deletion development-environment/storage/file.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
Test file
Test file
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
{
"priority": 1,
"request": {
"method": "PATCH",
"urlPattern": "/users-api/v1/users/100",
"bodyPatterns": [
{
"equalToJson": {
"name": "User 100 edited"
}
}
]
},
"response": {
"status": 204
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"priority": 1,
"request": {
"method": "POST",
"urlPattern": "/users-api/v1/upload",
"headers": {
"Content-Type": {
"matches": "multipart/form-data;\\s*boundary=[^\\s]+"
}
},
"bodyPatterns": [
{
"matches": ".+Content-Disposition: form-data; name=\"myfile\"; filename=\"test.txt\".*Content-Type: text/plain.+"
}
]
},
"response": {
"status": 201,
"headers": {
"Content-Type": "application/json; charset=utf-8"
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"priority": 1,
"request": {
"method": "POST",
"urlPattern": "/users-api/v1/upload",
"headers": {
"Content-Type": {
"matches": "multipart/form-data;\\s*boundary=[^\\s]+"
}
},
"bodyPatterns": [
{
"matches": ".+Content-Disposition: form-data; name=\"file\"; filename=\"test.txt\".*Content-Type: application/octet-stream.+"
}
]
},
"response": {
"status": 201,
"headers": {
"Content-Type": "application/json; charset=utf-8"
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
{
"priority": 1,
"request": {
"method": "POST",
"urlPattern": "/users-api/v1",
"headers": {
"Content-Type": {
"matches": "multipart/form-data;\\s*boundary=[^\\s]+"
}
},
"bodyPatterns": [
{
"matches": ".+Content-Disposition: form-data; name=\"name\".*User 100.+"
},
{
"matches": ".+Content-Disposition: form-data; name=\"email\".*[email protected].+"
}
]
},
"response": {
"status": 201,
"headers": {
"Content-Type": "application/json; charset=utf-8"
},
"jsonBody": {
"id": 10,
"name": "User 100",
"email": "[email protected]"
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
{
"priority": 1,
"request": {
"method": "POST",
"urlPattern": "/token",
"bodyPatterns": [
{
"equalToJson": {
"id": 10,
"name": "User 10",
"email": "[email protected]"
}
}
]
},
"response": {
"status": 200,
"headers": {
"Content-Type": "application/json; charset=utf-8"
},
"jsonBody": {
"type": "Bearer",
"token": "1A2B3C4D5E",
"expiresIn": 123456789
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"priority": 1,
"request": {
"method": "POST",
"urlPattern": "/users-api/v1/users",
"bodyPatterns": [
{
"equalToJson": {
"name": "User 100",
"email": "[email protected]"
}
}
]
},
"response": {
"status": 201,
"headers": {
"Content-Length": "0"
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
{
"priority": 1,
"request": {
"method": "PUT",
"urlPattern": "/users-api/v1/users/100",
"bodyPatterns": [
{
"equalToJson": {
"id": 100,
"name": "User 100 edited",
"email": "[email protected]"
}
}
]
},
"response": {
"status": 204,
"headers": {
"Content-Length": "0"
}
}
}
48 changes: 23 additions & 25 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ require (
cloud.google.com/go/storage v1.33.0
firebase.google.com/go v3.13.0+incompatible
github.com/aws/aws-sdk-go v1.45.28
github.com/docker/docker v24.0.5+incompatible
github.com/docker/go-connections v0.4.0
github.com/go-playground/form/v4 v4.2.1
github.com/go-playground/validator/v10 v10.15.5
Expand Down Expand Up @@ -39,31 +40,28 @@ require (

require (
cloud.google.com/go v0.110.8 // indirect
cloud.google.com/go/compute v1.23.1 // indirect
cloud.google.com/go/compute v1.23.0 // indirect
cloud.google.com/go/compute/metadata v0.2.3 // indirect
cloud.google.com/go/firestore v1.13.0 // indirect
cloud.google.com/go/iam v1.1.3 // indirect
cloud.google.com/go/longrunning v0.5.2 // indirect
cloud.google.com/go/iam v1.1.2 // indirect
cloud.google.com/go/longrunning v0.5.1 // indirect
dario.cat/mergo v1.0.0 // indirect
github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161 // indirect
github.com/KyleBanks/depth v1.2.1 // indirect
github.com/Microsoft/go-winio v0.6.1 // indirect
github.com/Microsoft/hcsshim v0.11.4 // indirect
github.com/andybalholm/brotli v1.0.6 // indirect
github.com/andybalholm/brotli v1.0.5 // indirect
github.com/benbjohnson/clock v1.3.0 // indirect
github.com/beorn7/perks v1.0.1 // indirect
github.com/cenkalti/backoff/v3 v3.1.1 // indirect
github.com/cenkalti/backoff/v4 v4.2.1 // indirect
github.com/cespare/xxhash/v2 v2.2.0 // indirect
github.com/containerd/containerd v1.7.11 // indirect
github.com/containerd/log v0.1.0 // indirect
github.com/containerd/containerd v1.7.3 // indirect
github.com/cpuguy83/dockercfg v0.3.1 // indirect
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f // indirect
github.com/docker/distribution v2.8.2+incompatible // indirect
github.com/docker/docker v24.0.9+incompatible // indirect
github.com/docker/go-units v0.5.0 // indirect
github.com/gabriel-vasile/mimetype v1.4.3 // indirect
github.com/gabriel-vasile/mimetype v1.4.2 // indirect
github.com/go-logr/logr v1.2.4 // indirect
github.com/go-logr/stdr v1.2.2 // indirect
github.com/go-openapi/jsonpointer v0.19.6 // indirect
Expand All @@ -75,16 +73,16 @@ require (
github.com/gogo/protobuf v1.3.2 // indirect
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect
github.com/golang/protobuf v1.5.3 // indirect
github.com/google/go-cmp v0.6.0 // indirect
github.com/google/go-cmp v0.5.9 // indirect
github.com/google/s2a-go v0.1.7 // indirect
github.com/googleapis/enterprise-certificate-proxy v0.3.1 // indirect
github.com/googleapis/gax-go/v2 v2.12.0 // indirect
github.com/grpc-ecosystem/grpc-gateway/v2 v2.18.0 // indirect
github.com/grpc-ecosystem/grpc-gateway/v2 v2.16.0 // indirect
github.com/hashicorp/errwrap v1.1.0 // indirect
github.com/hashicorp/go-multierror v1.1.1 // indirect
github.com/jmespath/go-jmespath v0.4.0 // indirect
github.com/josharian/intern v1.0.0 // indirect
github.com/klauspost/compress v1.17.1 // indirect
github.com/klauspost/compress v1.17.0 // indirect
github.com/leodido/go-urn v1.2.4 // indirect
github.com/magiconair/properties v1.8.7 // indirect
github.com/mailru/easyjson v0.7.7 // indirect
Expand All @@ -98,14 +96,14 @@ require (
github.com/morikuni/aec v1.0.0 // indirect
github.com/opencontainers/go-digest v1.0.0 // indirect
github.com/opencontainers/image-spec v1.1.0-rc4 // indirect
github.com/opencontainers/runc v1.1.12 // indirect
github.com/opencontainers/runc v1.1.5 // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/pmezard/go-difflib v1.0.0 // indirect
github.com/prometheus/client_model v0.3.0 // indirect
github.com/prometheus/common v0.42.0 // indirect
github.com/prometheus/procfs v0.10.1 // indirect
github.com/rivo/uniseg v0.2.0 // indirect
github.com/sirupsen/logrus v1.9.3 // indirect
github.com/sirupsen/logrus v1.9.2 // indirect
github.com/swaggo/files/v2 v2.0.0 // indirect
github.com/swaggo/swag v1.16.2 // indirect
github.com/valyala/bytebufferpool v1.0.0 // indirect
Expand All @@ -114,22 +112,22 @@ require (
go.opentelemetry.io/otel/metric v1.19.0 // indirect
go.opentelemetry.io/proto/otlp v1.0.0 // indirect
go.uber.org/atomic v1.7.0 // indirect
golang.org/x/crypto v0.21.0 // indirect
golang.org/x/crypto v0.14.0 // indirect
golang.org/x/mod v0.13.0 // indirect
golang.org/x/net v0.23.0 // indirect
golang.org/x/net v0.17.0 // indirect
golang.org/x/oauth2 v0.13.0 // indirect
golang.org/x/sync v0.4.0 // indirect
golang.org/x/sys v0.18.0 // indirect
golang.org/x/text v0.14.0 // indirect
golang.org/x/sys v0.15.0 // indirect
golang.org/x/text v0.13.0 // indirect
golang.org/x/time v0.3.0 // indirect
golang.org/x/tools v0.14.0 // indirect
golang.org/x/xerrors v0.0.0-20231012003039-104605ab7028 // indirect
google.golang.org/appengine v1.6.8 // indirect
google.golang.org/genproto v0.0.0-20231016165738-49dd2c1f3d0b // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20231016165738-49dd2c1f3d0b // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20231016165738-49dd2c1f3d0b // indirect
google.golang.org/grpc v1.59.0 // indirect
google.golang.org/protobuf v1.33.0 // indirect
golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2 // indirect
google.golang.org/appengine v1.6.7 // indirect
google.golang.org/genproto v0.0.0-20231002182017-d307bd883b97 // indirect
google.golang.org/genproto/googleapis/api v0.0.0-20231002182017-d307bd883b97 // indirect
google.golang.org/genproto/googleapis/rpc v0.0.0-20231009173412-8bfb1ae86b6c // indirect
google.golang.org/grpc v1.58.2 // indirect
google.golang.org/protobuf v1.31.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
k8s.io/klog/v2 v2.90.1 // indirect
k8s.io/utils v0.0.0-20230220204549-a5ecb0141aa5 // indirect
Expand Down
Loading
Loading