File tree Expand file tree Collapse file tree 2 files changed +11
-1
lines changed Expand file tree Collapse file tree 2 files changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -1152,6 +1152,7 @@ $ scw inspect myserver | jq '.[0].public_ip.address'
11521152
11531153### master (unreleased)
11541154
1155+ * create-image-from-http.sh: Support HTTP proxy ([ #249 ] ( https://github.com/scaleway/scaleway-cli/issues/249 ) )
11551156* Support of ` scw run --userdata=... ` ([ #202 ] ( https://github.com/scaleway/scaleway-cli/issues/202 ) )
11561157* Refactor of ` scw _security-groups ` ([ #197 ] ( https://github.com/scaleway/scaleway-cli/issues/197 ) )
11571158* Support of ` scw tag --arch=XXX `
Original file line number Diff line number Diff line change @@ -20,7 +20,6 @@ IMAGE_BOOTSCRIPT=${IMAGE_BOOTSCRIPT:stable}
2020VOLUME_SIZE=${VOLUME_SIZE:- 50GB}
2121KEY=$( cat ~ /.ssh/id_rsa.pub | awk ' { print $1" "$2 }' | tr ' ' ' _' )
2222
23-
2423echo " [+] URL of the tarball: ${URL} "
2524echo " [+] Target name: ${NAME} "
2625
@@ -35,6 +34,16 @@ scw exec -w "${SERVER}" 'uname -a'
3534echo " [+] Server is booted"
3635
3736
37+ if [ -n " ${SCW_GATEWAY_HTTP_PROXY} " ]; then
38+ echo " [+] Configuring HTTP proxy"
39+ # scw exec "${SERVER}" "echo proxy=${SCW_GATEWAY_HTTP_PROY} >> .curlrc"
40+ (
41+ set +x
42+ scw exec " ${SERVER} " " echo http_proxy = ${SCW_GATEWAY_HTTP_PROXY} >> .wgetrc" > /dev/null 2> /dev/null || (echo " Failed to configure HTTP proxy" ; exit 1) || exit 1
43+ )
44+ fi
45+
46+
3847echo " [+] Formating and mounting /dev/nbd1..."
3948scw exec " ${SERVER} " ' mkfs.ext4 /dev/nbd1 && mount /dev/nbd1 /mnt'
4049echo " [+] /dev/nbd1 formatted in ext4 and mounted on /mnt"
You can’t perform that action at this time.
0 commit comments