
Research
Two Malicious Rust Crates Impersonate Popular Logger to Steal Wallet Keys
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
Orchestrate rolling deployments of Docker containers like it's 2005
Cringe is an orchestration system for applications that consist of collections of immutable Docker containers. Prototype your application infrastructure with bash (or your shell of choice), then flip the shebang line to #!/usr/bin/env cringe
to ✨magically ✨ perform rolling upgrades instead.
Install cringe with npm:
npm install -g cringe
Write a shell script that launches and configures your application's containers in your shell of choice. Use as much of the docker
command-line interface as you wish. Cringe will use the --name
parameter to determine what a container's lifespan is intended to be, but all other arguments and commands are passed through to the docker
CLI on your ${PATH}
as given.
# Because Docker will automatically name this container, a new container will be launched each time
# you run cringe.
docker run -d smashwilson/minimal-sinatra
# Similarly, the DNAME in this container's name will be replaced with the current (randomly-named)
# deployment. A new container will be launched each time that you run cringe, but each will
# have a name like "foo-b35b988c8fa08d75".
docker run -d --name foo-DNAME smashwilson/minimal-sinatra
# Because this container has an explicit, untemplated name, the "frontdoor" container will be
# created if it doesn't exist, but left alone on subsequent deployments. This is useful for
# containers like load balancers or data volume containers.
docker run -d -P --name frontdoor my-nginx
# This is a bash script. You can do anything in here that you can do in bash: variable
# substitution, for loops, functions, whatever.
docker run -d -p ${PUBLIC_PORT}:${CONTAINER_PORT:-8080} ${DOCKER_USERNAME}/${DOCKER_IMAGE_NAME}
To run a deployment with cringe:
cringe.sh
, running cringe
in that directory will use your script automatically.cringe my-script.sh
#!/usr/bin/env cringe
and mark it executable with chmod +x
to use cringe when you run it directly as ./my-script.sh
.If you're sneaky, you can even set the SHELL
environment variable to any interpreter to use something that's not a shell, like SHELL=python cringe my-script.py
. As long as my-script.py
shells out to the Docker client (rather than do something sane like use an SDK) it should work fine.
Why would anyone in their right minds ever use this? Okay, okay, realistically, you should probably be using something "official" and "maintained" with "actual effort" like docker-compose or Kubernetes.
FAQs
Deploy Docker applications with terrible bash scripts
The npm package cringe receives a total of 0 weekly downloads. As such, cringe popularity was classified as not popular.
We found that cringe demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
Research
A malicious package uses a QR code as steganography in an innovative technique.
Research
/Security News
Socket identified 80 fake candidates targeting engineering roles, including suspected North Korean operators, exposing the new reality of hiring as a security function.