Giter Club home page Giter Club logo

ansible-workstations-ubuntu's Introduction

Ansible standup for GUI and ssh only workstations

This is a collection of ansible scripts that set up a chunk of packages that I use in my day to day operations. Use of the gui flag allows

Runbook Steps

  • clone this repo to the machine you wish to ansible
  • Option 1:
    • run 'install.sh' if you need to install all prerequisites (Python/Ansible/Git) ./install.sh Option 2:
    • If you already ran 'install.sh' or have all the prerequisites installed, run the ansible playbook directly ansible-playbook main.yml -i ./hosts -c local -v --ask-become-pass

Two Modes for Install

GUI Workstation

ansible-playbook main.yml -i ./hosts -c local --tags gui

Terminal workstation

ansible-playbook main.yml -i ./hosts -c local

Optional Use of password sudo

Append --ask-become-pass for password based sudo

General Setup

The command sh ansible-workstations-ubuntu/install.sh is run.

This then calls the main.yml file which consists of three roles, pre-install, workstation, and postbrew, as well as the additional gui components role.

The preinstall creates a shared directory using the variable sharedInstallPath: /opt/ansible-up. This directory is used throughout the ansible installation.

Note that there might be installations of things multiple times. This code can be improved by removing redundancies.

In our post-brew task, we utilize the shared directory to set up a python2 and python3 virtual environment. I tried implementing a similar setup for emacs, however, I am not sure if it is implemented properly or what the best way to implement that is.

Additional notes

This current version is designed specifically for WSL, however it should run on other environments. This is handled using a "when: ansible_facts['virtualization_type'] == " statement to help modify behavior depending on the virtualization technology used. In some environments, it has been observed that the virtualization type instead of "wsl" is instead listed as "NA", so the ansible code has been modified to cover this. If you are uncertain as to how ansible is interpreting your environment, please run the command:

ansible -m setup localhost

This installation of the GUI components is omitted for wsl. In particular snapd is used for GUI installs, and snapd relies on systemd, and systemd is not present in wsl.

Lastly

This is still a work in progress. Feel free to update it and configure it to install your desired tools.

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.