I am doing some testing on charms and I discovered that the gitlab does not deploy on environments with limited network access.
Here is the error from the
2014-08-22 20:21:31 INFO juju-log Installing bundler gem
2014-08-22 20:21:31 INFO install + sudo gem install bundler
2014-08-22 20:23:39 INFO install ERROR: Could not find a valid gem 'bundler' (>= 0) in any repository
From what I can tell gem was not able to find bundler on the network. Since the system has a limited network I am running Juju with proxies. The ubuntu-local-machine-4 has HTTP_PROXY and HTTPS_PROXY environment variables set but they were not used.
I found the command:
sudo gem install --http-proxy $HTTP_PROXY bundler
works and installs the bundler. Therefore I would recommend changing the install hook to use the HTTP_PROXY when available:
GEM_OPTIONS=""
if [ -n "${HTTP_PROXY}" ]; then GEM_OPTIONS="--http-proxy ${HTTP_PROXY}"
fi
juju-log "Installing bundler gem"
sudo gem install ${GEM_OPTIONS} bundler
I tried the above code and the bundler gem installs, but a curl command fails later in the install hook.
2014-08-22 21:02:37 INFO install + sudo curl --output /etc/init.d/gitlab https://raw.github.com/gitlabhq/gitlab-recipes/4-1-stable/init.d/gitlab
2014-08-22 21:02:37 INFO install % Total % Received % Xferd Average Speed Time Time Time Current
2014-08-22 21:02:37 INFO install Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
2014-08-22 21:02:37 INFO install + sudo chmod +x /etc/init.d/gitlab
2014-08-22 21:02:37 INFO install chmod: cannot access '/etc/init.d/gitlab': No such file or directory
2014-08-22 21:02:37 ERROR juju.worker.uniter uniter.go:486 hook failed: exit status 1
I researched curl and found the -x or --proxy option for curl. I tried using -x and --proxy but was not successful in downloading the file using curl. I was successful downloading the file with wget (that program automatically used the proxy settings).
I am doing some testing on charms and I discovered that the gitlab does not deploy on environments with limited network access.
Here is the error from the
2014-08-22 20:21:31 INFO juju-log Installing bundler gem
2014-08-22 20:21:31 INFO install + sudo gem install bundler
2014-08-22 20:23:39 INFO install ERROR: Could not find a valid gem 'bundler' (>= 0) in any repository
From what I can tell gem was not able to find bundler on the network. Since the system has a limited network I am running Juju with proxies. The ubuntu- local-machine- 4 has HTTP_PROXY and HTTPS_PROXY environment variables set but they were not used.
I found the command:
sudo gem install --http-proxy $HTTP_PROXY bundler
works and installs the bundler. Therefore I would recommend changing the install hook to use the HTTP_PROXY when available:
if [ -n "${HTTP_PROXY}" ]; then
fi
juju-log "Installing bundler gem"
sudo gem install ${GEM_OPTIONS} bundler
I tried the above code and the bundler gem installs, but a curl command fails later in the install hook.
2014-08-22 21:02:37 INFO install + sudo curl --output /etc/init.d/gitlab https:/ /raw.github. com/gitlabhq/ gitlab- recipes/ 4-1-stable/ init.d/ gitlab d/gitlab' : No such file or directory
2014-08-22 21:02:37 INFO install % Total % Received % Xferd Average Speed Time Time Time Current
2014-08-22 21:02:37 INFO install Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0
2014-08-22 21:02:37 INFO install + sudo chmod +x /etc/init.d/gitlab
2014-08-22 21:02:37 INFO install chmod: cannot access '/etc/init.
2014-08-22 21:02:37 ERROR juju.worker.uniter uniter.go:486 hook failed: exit status 1
I researched curl and found the -x or --proxy option for curl. I tried using -x and --proxy but was not successful in downloading the file using curl. I was successful downloading the file with wget (that program automatically used the proxy settings).