docker-library | Docker image library | Continuous Deployment library
kandi X-RAY | docker-library Summary
kandi X-RAY | docker-library Summary
Docker image library.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of docker-library
docker-library Key Features
docker-library Examples and Code Snippets
Community Discussions
Trending Discussions on docker-library
QUESTION
I'd like to use envsubst with nginx docker alpine. Documentation:
Using environment variables in nginx configuration (new in 1.19)
Out-of-the-box, nginx doesn't support environment variables inside most configuration blocks. But this image has a function, which will extract environment variables before nginx starts.
Here is an example using docker-compose.yml:
web: image: nginx volumes:
- ./templates:/etc/nginx/templates ports:
- "8080:80" environment:
- NGINX_HOST=foobar.com
- NGINX_PORT=80
By default, this function reads template files in /etc/nginx/templates/*.template and outputs the result of executing envsubst to /etc/nginx/conf.d.
I have a nginx container service of the form:
...ANSWER
Answered 2021-Jun-04 at 23:44Changing the command doesn't work because the /docker-entrypoint.sh
contains:
QUESTION
What is the difference between alpine docker image and busybox docker image ?
When I check their dockfiles, alpine is like this (for Alpine v3.12 - 3.12.7)
...ANSWER
Answered 2021-May-18 at 14:22The key difference between these is that older versions of the busybox
image statically linked busybox against glibc (current versions dynamically link busybox against glibc due to use of libnss even in static configuration), whereas the alpine
image dynamically links against musl libc.
Going into the weighting factors used to choose between these in detail would be off-topic here (software recommendation requests), but some key points:
Comparing glibc against musl libc, a few salient points (though there are certainly many other factors as well):
- glibc is built for performance and portability over size (often adding special-case performance optimizations that take a large amount of code).
- musl libc is built for correctness and size over performance (it's willing to be somewhat slower to have a smaller code size and to run in less RAM); and it's much more aggressive about having correct error reporting (instead of just exiting immediately) in the face of resource exhaustion.
- glibc is more widely used, so bugs that manifest against its implementation tend to be caught more quickly. Often, when one is the first person to build a given piece of software against musl, one will encounter bugs (typically in that software, not in musl) or places where the maintainer explicitly chose to use GNU extensions instead of sticking to the libc standard.
- glibc is licensed under LGPL terms; only software under GPL-compatible terms can be statically linked against it; whereas musl is under a MIT license, and usable with fewer restrictions.
Comparing the advantages of a static build against a dynamic build:
- If your system image will only have a single binary executable (written in C or otherwise using a libc), a static build is always better, as it discards any parts of your libraries that aren't actually used by that one executable.
- If your system image is intended to have more binaries added that are written in C, using dynamic linking will keep the overall size down, since it allows those binaries to use the libc that's already there.
- If your system image is intended to have more binaries added in a language that doesn't use libc (this can be the case for Go and Rust, f/e), then you don't benefit from dynamic linking; you don't need the unused parts of libc there because you won't be using them anyhow.
Honestly, these two images don't between themselves cover the whole matrix space of possibilities; there are situations where neither of them is optimal. There would be value to having an image with only busybox that statically links against musl libc (if everything you're going to add is in a non-C language), or an image with busybox that dynamically links against glibc (if you're going to add more binaries that need libc and aren't compatible with musl).
QUESTION
[nir ~]$ docker run --name mysql -d mysql:5.7
Unable to find image 'mysql:5.7' locally
5.7: Pulling from library/mysql
docker: no matching manifest for linux/arm64/v8 in the manifest list entries.
See 'docker run --help'.
[nir ~]$ docker run --name mysql -d mysql:8
Unable to find image 'mysql:8' locally
8: Pulling from library/mysql
docker: no matching manifest for linux/arm64/v8 in the manifest list entries.
See 'docker run --help'.
...ANSWER
Answered 2021-Apr-27 at 06:40Based on the comments.
mysql
docker does not support linux/arm64/v8
. However, mariadb
supports linux/arm64/v8
. Thus, if possible, change of of mysql
into mariadb
could solve the problem.
QUESTION
I'm running two containers. One is Keycloak (for access management/ authorization/ authentication) and the other is a mariadb database meant to store information for Keycloak.
My trouble is that I cannot access Keycloaks admin panel in my browser despite the containers running in the background (usually done by running localhost:8080/auth
).
Could somebody point me in the right direction as to what I'm doing wrong?
My Dockerfile:
...ANSWER
Answered 2021-Mar-12 at 18:14You haven't published any ports.
Update the keycloak
service in your docker-compose file.
QUESTION
I have a Galera cluster running on MariaDB containers, and only the bootstrapping node accepts connections - the other ones don't create a socket.
I'm baffled by this behavior since all the nodes are created from the same VM template and have the same configuration (apart from wsrep_cluster_address = gcomm://
in the bootstrapper node).
I'm using mariadb/server:10.4
as the container image.
/etc/mysql/my.cnf
(the only configuration file that exists and is the same across all nodes):
ANSWER
Answered 2021-Feb-17 at 09:13Locate the socket path:
QUESTION
I'm trying to setup a simple replication scenario in postgres using logical-replication and docker-compose. As you can see I'm using a postgres service for the master database (publisher) and one more for the replica (subscriber). wal_level = logical
is configured in both services by using this method.
docker-compose.yml:
...ANSWER
Answered 2021-Feb-04 at 20:56You're not passing your custom config to PG.
The compose file should read like:
QUESTION
My docker compose of mongo fails to authenticate when I add a docker-entrypoint-initdb.d/init-mongo.sh:ro file
docker-compose
...ANSWER
Answered 2021-Feb-02 at 09:48I have experimented and removed the reference in the docker-compose file
QUESTION
I am trying to get my app working with docker but I am having trouble getting my database to display. It seems my laravel application itself can access it but I need to access it myself in order to troubleshoot issues.
The problem when I try to access localhost:4306 (the port of which the db is on). when I go to that in the browser it outputs:
...ANSWER
Answered 2020-Nov-19 at 01:58You are trying to connect to database through HTTP protocol, that's why you are receiving that message.
You can connect to MySql database using phpMyAdmin (web client) or any installed MySql client.
Docker has phpMyAdmin available: https://hub.docker.com/r/phpmyadmin/phpmyadmin/
There are many MySql Clients available. Just search in your favorite search engine by "mysql client" followed by the name of your Operating System.
QUESTION
I try to initialize a database with Go.
I use port 5433 at postgres:alpine because 5432 is already taken by another microservice app.
ANSWER
Answered 2020-Nov-18 at 08:17You have multiple options:
Option 1: Define own postgresql.conf
QUESTION
I have the following docker-compose
...ANSWER
Answered 2020-Nov-13 at 13:38The command : docker swarm leave -f
is the opposite for docker swarm init
not for docker stack deploy
.
Try : docker stack rm test-stack
By using : docker swarm leave -f
, you shutdown the Swarm mode, this could explain why the volumes are destroyed.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install docker-library
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page