Giter Club home page Giter Club logo

Comments (10)

matthew-gill avatar matthew-gill commented on August 15, 2024 6

If it helps, here's a snippet of my docker-compose file which uses localstack to set up SQS and create two queues:

services:
    localstack:
        image: localstack/localstack
        ports:
            - "8000:8080"
        environment:
            - SERVICES=sqs
            - HOSTNAME=localstack
            - DEFAULT_REGION=eu-west-1
        volumes:
            - ./docker/config/localstack:/docker-entrypoint-initaws.d

Then create the following file:

./docker/config/localstack/01-queues.sh:

#!/usr/bin/env bash
awslocal sqs create-queue --queue-name YOUR_FIRST_QUEUE_NAME
awslocal sqs create-queue --queue-name YOUR_SECOND_QUEUE_NAME

from alpine-sqs.

Pixel-Jack avatar Pixel-Jack commented on August 15, 2024 2

Hey @matthew-gill , I have the same issue !

And moreover this container is constantly getting some information as input (Here Input are at 17.9GB after like 5 min of running)
docker stats:

CONTAINER ID        NAME                CPU %               MEM USAGE / LIMIT     MEM %               NET I/O             BLOCK I/O           PIDS
ea3332804018        dev_sqs             21.41%              49.23MiB / 50MiB      98.45%              1.25MB / 21.4kB     17.9GB / 16.4kB     31

To avoid this container to overload my system, I've launch it with a cpu restriction of 0.2
In docker compose:

cpus: 0.2
mem_limit: 200M

If someone has any new idea, please share

from alpine-sqs.

matthew-gill avatar matthew-gill commented on August 15, 2024

@Pixel-Jack I ended up swapping to localstack instead of this as it supports SQS... I also needed KMS as part of my stack and it came with that, too.

Perhaps a bit heavy handed if you only need SQS, however, it seems a lot more polite with CPU usage, so maybe give it a go?

It also seems a lot more maintained than this image, too.

from alpine-sqs.

Pixel-Jack avatar Pixel-Jack commented on August 15, 2024

@matthew-gill Thank you, for the tip and the conf files ! I'll try this, this whole stack should be useful later so it won't be a waste :)

from alpine-sqs.

rciorba avatar rciorba commented on August 15, 2024

I suspect it's the insights node app that is doing something strange here.
I attached to the container and stopped the web app and now cpu usage is back to normal.

from alpine-sqs.

xdxiaodong avatar xdxiaodong commented on August 15, 2024

+1

from alpine-sqs.

brendandebeasi avatar brendandebeasi commented on August 15, 2024

@rciorba Any update on this?

from alpine-sqs.

ucarbehlul avatar ucarbehlul commented on August 15, 2024

I agree that the node app seems to be acting weird. Is there a way to make container start without the node app and only the SQS part (I can view the queue contents with aws-cli if needed)?

from alpine-sqs.

rciorba avatar rciorba commented on August 15, 2024

FYI, there's an MR which also fixes this issue: #37
As the MR isn't merged yet, you can build your own image or use one I built: https://hub.docker.com/r/rciorba/alpine-sqs

from alpine-sqs.

ronster37 avatar ronster37 commented on August 15, 2024

I also have been having over 100% CPU usage but clearing my queues from time to time seems to resolve my CPU usage and I'm actually able to hear other things besides just my laptop fans lol

from alpine-sqs.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.