Ident samples

This commit is contained in:
nemunaire 2018-10-14 22:58:19 +02:00
commit 02db9cc19c
47 changed files with 2660 additions and 215 deletions

View file

@ -56,9 +56,9 @@ Lorsqu'une ligne devient complexe, allez à la ligne :
<div lang="en-US">
```
RUN apt-get update && apt-get install -y \
nginx \
php5-fpm
RUN apt-get update && apt-get install -y \
nginx \
php5-fpm
```
</div>
@ -71,12 +71,12 @@ exemple :
<div lang="en-US">
```
RUN apt-get update && apt-get install -y \
bzr \
cvs \
git \
mercurial \
subversion
RUN apt-get update && apt-get install -y \
bzr \
cvs \
git \
mercurial \
subversion
```
</div>
@ -155,8 +155,8 @@ L'entrypoint peut être utilisé de deux manières différentes :
<div lang="en-US">
```
ENTRYPOINT ["nginx"]
CMD ["-g daemon off;"]
ENTRYPOINT ["nginx"]
CMD ["-g daemon off;"]
```
</div>
@ -167,20 +167,20 @@ CMD ["-g daemon off;"]
<div lang="en-US">
```shell
#!/bin/bash
set -e
#!/bin/bash
set -e
if [ "$1" = 'postgres' ]; then
chown -R postgres "$PGDATA"
if [ "$1" = 'postgres' ]; then
chown -R postgres "$PGDATA"
if [ -z "$(ls -A "$PGDATA")" ]; then
gosu postgres initdb
fi
if [ -z "$(ls -A "$PGDATA")" ]; then
gosu postgres initdb
fi
exec gosu postgres "$@"
fi
exec gosu postgres "$@"
fi
exec "$@"
exec "$@"
```
</div>