Sha256: 3f30fe815671764ad4915d93d4c37ca7be89cc5bf200432108652cb9d98c77e2

Contents?: true

Size: 1.94 KB

Versions: 7

Compression:

Stored size: 1.94 KB

Contents

---
  - name: Test connection
    ping:

  - name: Set MOTD
    template:
      src: motd
      dest: /etc/motd
    become: true

  - name: Set hostname
    command: hostname {{hostname}}
    become: true

  - name: Set hostname in /etc/hosts
    lineinfile:
      dest: "/etc/hosts"
      line: "127.0.0.1 {{hostname}}"
      state: present
      insertafter: "127.0.0.1 localhost"
    become: true

  - name: update /etc/hostname
    copy:
      content: "{{hostname}}"
      dest: /etc/hostname
    become: true

  - name: Set hostname for systemd
    hostname:
      name: "{{hostname}}"
    become: true

  - name: install aptitude
    apt:
      pkg: aptitude
      state: present
    become: true

  - name: apt-get update
    apt: update_cache=yes cache_valid_time=86400
    become: true

  - name: apt-get upgrade
    apt: upgrade=full
    become: true

  - name: Set timezone variables
    copy: content='America/Chicago'
          dest=/etc/timezone
          owner=root
          group=root
          mode=0644
          backup=yes
    become: true
    notify:
      - update timezone

  - name: Add deploy user
    user:
      name: "{{deploy_user}}"
      state: present
      generate_ssh_key: yes
      shell: /bin/bash
    become: true

  - name: Add deploy user to adm group so it can view logs in /var/log
    user:
      name: "{{deploy_user}}"
      append: yes
      groups: "adm"
    become: true

  - name: Add sudoers.d file so that deploy can restart services without entering password.
    copy:
      src: sudoers-service
      dest: /etc/sudoers.d/service
    become: true

  - name: Update authorized_keys for deploy user
    copy:
      src: authorized_keys
      dest: "/home/{{deploy_user}}/.ssh/authorized_keys"
      owner: "{{deploy_user}}"
    become: true

  - name: Create directory to which to deploy
    file:
      path: /u/apps/{{project_name}}
      owner: "{{deploy_user}}"
      state: directory
    become: true

  - import_tasks: swap.yml

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
subspace-0.6.17 ansible/roles/common/tasks/main.yml
subspace-0.6.16 ansible/roles/common/tasks/main.yml
subspace-0.6.15 ansible/roles/common/tasks/main.yml
subspace-0.5.15 ansible/roles/common/tasks/main.yml
subspace-0.5.14 ansible/roles/common/tasks/main.yml
subspace-0.4.14 ansible/roles/common/tasks/main.yml
subspace-0.4.13 ansible/roles/common/tasks/main.yml