Giter Club home page Giter Club logo

Comments (6)

chouseknecht avatar chouseknecht commented on July 22, 2024

@TemperingPick

Not sure there is a programmatic way to do what you need. The first step is to add the http_proxy and/or https_proxy environment variables to the container.yml file, like so:

version: "2"
settings:
  save_conductor_container: false
  conductor:
    environment:
      http_proxy: http://my-proxy-server
      https_proxy: https://my-proxy_server
  vars_files:
  - develop.yml
    
services:
  django:
    ... 
    environment: 
      - C_FORCE_ROOT=1
      - http_proxy=http://my-proxy-server
      - https_proxy=https://my-proxy-server 
    ....

  gulp:
    ...
    environment: 
      - http_proxy=http://my-proxy-server
      - https_proxy=https://my-proxy-server 
    ...

registries: {}

from galaxy.

chouseknecht avatar chouseknecht commented on July 22, 2024

From @TemperingPick on July 24, 2017 16:40

@chouseknecht

Is there any where else that I might need to add the environmental variables? I've added them to the main container.yml but the get_url module is still failing even when it says use_proxy=true. I know it's something with the containers because I can wget the file from the server.

from galaxy.

chouseknecht avatar chouseknecht commented on July 22, 2024

@TemperingPick

As an experiment, you might try modifying the task directly, so that it looks like the following:

- name: Get the file
  get_url:
    url: ...
    dest: .... 
  environment:
    http_proxy: http://my-proxy-server

See http://docs.ansible.com/ansible/latest/playbooks_environment.html for more details, if needed.

I was hoping to avoid modifying the tasks by setting the environment variables at the service level in container.yml.

from galaxy.

chouseknecht avatar chouseknecht commented on July 22, 2024

From @TemperingPick on July 24, 2017 19:56

@chouseknecht
Doesn't look like get_url supports the environment parameter. It only supports the use_proxy which is set as true.

" "msg": "Unsupported parameters for (get_url) module: environment. Supported parameters include: attributes,backup,checksum,client_cert,client_key,content,delimiter,dest,directory_mode,follow,force,force_basic_auth,group,headers,http_agent,mode,owner,regexp,remote_src,selevel,serole,setype,seuser,sha256sum,src,timeout,tmp_dest,unsafe_writes,url,url_password,url_username,use_proxy,validate_certs""

from galaxy.

chouseknecht avatar chouseknecht commented on July 22, 2024

@TemperingPick

It's not a module parameter. Take a look at the example below. The module name and environment should be at the same indentation level.

- apt: name=cobbler state=installed
  environment:
    http_proxy: http://proxy.example.com:8080

from galaxy.

chouseknecht avatar chouseknecht commented on July 22, 2024

From @TemperingPick on July 25, 2017 2:57

@chouseknecht

Yep that did it! Thanks so much!! If there's a place for it I'd love to document which steps needed to have the environment step added so no one else needs to try and fight with all of this.

from galaxy.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.