Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
pycklets / resources / frecklet / conda-pkg-mgr.frecklet
Size: Mime:
doc:
  short_help: Install the 'conda' package manager
  help: |
    Install the conda package manager.

    No root permissions are required for this as long as the ``bzip2`` system package is available.

    If you specify a different 'user', it's currently not possible to add conda init code to that users
    '.profile'. You need to manually set 'no_add_to_path' to true to not get an error
  references:
    Conda homepage: https://conda.io
  examples:
  - title: install conda package manager
  - title: install conda package manager withoug adding it to PATH
    vars:
      no_add_to_path: true
  - title: install conda package manager, add PATH to custom file
    desc: |
      This adds the short bash snippet that adds 'conda' to the PATH env variable to the file ``$HOME/.init.sh`` instead of ``$HOME/.profile``.
    vars:
      init_files:
      - '{{ ansible_env.HOME }}/.init.sh'
  - title: install conda package manager for user 'freckles'
    desc: |
      This creates the user 'freckles' if it doesn't already exist, then installs conda for that user. Be aware, adding conda init code to the users '.profile' is currently not possible, so you have to manually set 'no_add_to_path' to true to not get an error.
    vars:
      user: freckles
      no_add_to_path: true

args:
  no_add_to_path:
    required: false
    type: boolean
    doc:
      short_help: Don't add conda to PATH in init files.
    default: false
    cli:
      is_flag: true
      param_decls:
      - --no-add-to-path
  init_files:
    type: list
    schema: {type: string}
    required: false
    empty: true
    default:
    - '{{ ansible_env.HOME }}/.profile'
    doc:
      short_help: Files to add a 'PATH=...' directive to.
    cli:
      metavar: PATH
      param_decls:
      - --init-file
  user:
    doc:
      short_help: The user to install conda for.
    type: string
    required: false
meta:
  tags:
  - featured-frecklecutable
  - conda
  - package-manager
  - package-management
  - install

frecklets:
- user-exists:
    frecklet::skip: '{{:: user | true_if_empty ::}}'
    name: '{{:: user ::}}'
- frecklet:
    name: freckfrackery.install-conda
    type: ansible-role
    resources:
      ansible-role:
      - freckfrackery.install-conda
    desc:
      short: installing the conda package manager
      long: |
        Install the [conda](https://conda.io) package manager.
      references:
        "'freckfrackery.install-conda' Ansible role": https://gitlab.com/freckfrackery/freckfrackery.install-conda
    properties:
      idempotent: true
      elevated: '{{:: user | false_if_empty ::}}'
      internet: true
  task:
    become: '{{:: user | false_if_empty ::}}'
    become_user: '{{:: user ::}}'
  vars:
    conda_add_to_path: '{{:: no_add_to_path | negate ::}}'
    conda_add_path_files: '{{:: init_files ::}}'