If you have installed Alpine Linux image using Docker and you get, /bin/sh: bash: not found, the reason is that you do not get bash shell installed on with this image, you only get sh shell.
You should make use of sh instead to keep the footprint, if you still want to install bash, use command RUN apk add --no-cache bash
You can also, run the command apk add bash after you run alpine Linux,
Example:# apk add bash
fetch https://dl-cdn.alpinelinux.org/alpine/v3.15/main/aarch64/APKINDEX.tar.gz
fetch https://dl-cdn.alpinelinux.org/alpine/v3.15/community/aarch64/APKINDEX.tar.gz
(1/4) Installing ncurses-terminfo-base (6.3_p20211120-r0)
(2/4) Installing ncurses-libs (6.3_p20211120-r0)
(3/4) Installing readline (8.1.1-r0)
(4/4) Installing bash (5.1.16-r0)
Executing bash-5.1.16-r0.post-install
Executing busybox-1.34.1-r5.trigger
OK: 8 MiB in 18 packages
More Posts related to Docker,
- Install Docker on Mac using brew cask
- How to know the Docker Sandbox ID of a Container Network?
- How to Rename Docker Image with none TAG and REPOSITORY?
- How to know list of images available on your device
- Docker Alpine Linux and Apache2 Example
- Install Bash on Alpine Linux - Docker
- Docker Run Command Examples - Part 1
- Install the minimal Linux on Docker (only 5 mb Alpine Linux)
- [fix] docker: Error response from daemon: dial unix docker.raw.sock: connect: no such file or directory.
- Install RabbitMQ on Docker
- How to know docker Engine details
- [Fix] Docker Error response from daemon: manifest for :latest not found: manifest unknown
- How to stop and start a docker container
- How to create volume in Docker using Command
- How to know the Docker Engine Version
- [docker] Error response from daemon: No such container
- Install Docker for Mac using Home-brew Cask
- Docker - Incompatible CPU detected - M1/M2 Mac (macOS Sonoma)
- [fix] Docker Desktop App not starting on Mac (macOS)
- Unable to find image docker latest locally
- How to Stop/Cancel/kill docker image pull
- List of what's new in Docker 4.23
- [Docker M1/M2 Mac] qemu-x86_64: Could not open /lib64/ld-linux-x86-64.so.2: No such file or directory AWS CLI
- Install Docker Desktop on M1/M2 Apple Silicon ARM Chip Mac
- Docker - Running in Resource Saver mode
More Posts:
- JSON Syntax : JSON Tutorial - Json-Tutorial
- Android AlertDialog Programatically Example - Android
- How to see Mac Login and Shutdown history for audit - MacOS
- JdbcTemplate Batch Insert Example using Spring Boot - Java
- Ubuntu: How to set Environment Variable - Ubuntu
- Image Extension Converter (Supports PNG, JPG, GIF, TIF, WEBP, BMP, and ICO formats) - Tools
- How to Decode Base64 Data String in Python - Python
- Microsoft Edge Fix: ERR_TUNNEL_CONNECTION_FAILED - Microsoft