Passage des variables d'environnement proxy au conteneur + refactoring
This commit is contained in:
parent
22f325f749
commit
1dec78875a
|
@ -71,7 +71,7 @@ function exec_hooks {
|
|||
local hook=${1}
|
||||
local workspace=${2}
|
||||
|
||||
local hook_scripts=$( find "${HOOKS_DIR}" -type f -name "*${hook}" -executable)
|
||||
local hook_scripts=$( find "${HOOKS_DIR}" -type f -name "*${hook}" -executable | sort )
|
||||
|
||||
for hook_script in ${hook_scripts}; do
|
||||
|
||||
|
|
|
@ -92,6 +92,9 @@ function main {
|
|||
|
||||
# Expose host uid & gid
|
||||
docker_opt="${docker_opt} -e HOST_UID=$(id -u) -e HOST_GID=$(id -g)"
|
||||
# Expose host proxy variables
|
||||
docker_opt="${docker_opt} -e HTTP_PROXY=${HTTP_PROXY} -e HTTPS_PROXY=${HTTPS_PROXY}"
|
||||
docker_opt="${docker_opt} -e http_proxy=${http_proxy} -e https_proxy=${https_proxy}"
|
||||
|
||||
if [[ ${PERSIST_CONTAINER} -eq 0 ]]
|
||||
then
|
||||
|
|
|
@ -1,5 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
|
||||
|
||||
mkdir -p $DESTDIR/opt/hello-world
|
||||
cp $SRCDIR/hello-world $DESTDIR/opt/hello-world/
|
|
@ -1,3 +0,0 @@
|
|||
#!/bin/sh
|
||||
|
||||
echo "Test pre-install"
|
|
@ -1,16 +0,0 @@
|
|||
{
|
||||
"name": "hello-world",
|
||||
"dependencies": {
|
||||
"debian:jessie": {
|
||||
"apache2": ">= 2.4",
|
||||
"php5": ">= 5.4"
|
||||
}
|
||||
},
|
||||
"hooks": {
|
||||
"preBuild": "./scripts/pre-build.sh",
|
||||
"preInstall": "./scripts/pre-install.sh",
|
||||
"preRemove": "",
|
||||
"postInstall": "",
|
||||
"postRemove": ""
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue