From 08215df8b731ca44aa75bbf694bcf740e3922559 Mon Sep 17 00:00:00 2001 From: Laur Ivan Date: Wed, 5 Oct 2022 12:53:35 +0200 Subject: [PATCH] Initial commit. --- .gitignore | 7 ++ .travis.yml | 29 ++++++ .yamllint | 33 ++++++ LICENSE | 20 ++++ README.md | 178 ++++++++++++++++++++++++++++++++ TODO.md | 5 + defaults/main.yml | 26 +++++ handlers/main.yml | 2 + meta/main.yml | 37 +++++++ molecule/default/INSTALL.rst | 15 +++ molecule/default/cleanup.yml | 23 +++++ molecule/default/converge.yml | 11 ++ molecule/default/destroy.yml | 28 +++++ molecule/default/molecule.yml | 30 ++++++ molecule/default/prepare.yml | 35 +++++++ molecule/default/verify.yml | 10 ++ molecule/requirements.yml | 4 + tasks/main.yml | 67 ++++++++++++ templates/docker-compose.yml.j2 | 72 +++++++++++++ templates/env.db.conf.j2 | 4 + templates/env.oidc.conf.j2 | 18 ++++ templates/env.outline.conf.j2 | 79 ++++++++++++++ templates/env.redis.conf.j2 | 0 templates/env.s3.conf.j2 | 0 tests/inventory | 2 + tests/test.yml | 5 + vars/main.yml | 2 + 27 files changed, 742 insertions(+) create mode 100644 .gitignore create mode 100644 .travis.yml create mode 100644 .yamllint create mode 100644 LICENSE create mode 100644 README.md create mode 100644 TODO.md create mode 100644 defaults/main.yml create mode 100644 handlers/main.yml create mode 100644 meta/main.yml create mode 100644 molecule/default/INSTALL.rst create mode 100644 molecule/default/cleanup.yml create mode 100644 molecule/default/converge.yml create mode 100644 molecule/default/destroy.yml create mode 100644 molecule/default/molecule.yml create mode 100644 molecule/default/prepare.yml create mode 100644 molecule/default/verify.yml create mode 100644 molecule/requirements.yml create mode 100644 tasks/main.yml create mode 100644 templates/docker-compose.yml.j2 create mode 100644 templates/env.db.conf.j2 create mode 100644 templates/env.oidc.conf.j2 create mode 100644 templates/env.outline.conf.j2 create mode 100644 templates/env.redis.conf.j2 create mode 100644 templates/env.s3.conf.j2 create mode 100644 tests/inventory create mode 100644 tests/test.yml create mode 100644 vars/main.yml diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..bcb54e9 --- /dev/null +++ b/.gitignore @@ -0,0 +1,7 @@ +*.retry +*/__pycache__ +*.pyc +.cache +.venv +.env.yml +docker-compose.yml \ No newline at end of file diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 0000000..36bbf62 --- /dev/null +++ b/.travis.yml @@ -0,0 +1,29 @@ +--- +language: python +python: "2.7" + +# Use the new container infrastructure +sudo: false + +# Install ansible +addons: + apt: + packages: + - python-pip + +install: + # Install ansible + - pip install ansible + + # Check ansible version + - ansible --version + + # Create ansible.cfg with correct roles_path + - printf '[defaults]\nroles_path=../' >ansible.cfg + +script: + # Basic role syntax check + - ansible-playbook tests/test.yml -i tests/inventory --syntax-check + +notifications: + webhooks: https://galaxy.ansible.com/api/v1/notifications/ \ No newline at end of file diff --git a/.yamllint b/.yamllint new file mode 100644 index 0000000..8827676 --- /dev/null +++ b/.yamllint @@ -0,0 +1,33 @@ +--- +# Based on ansible-lint config +extends: default + +rules: + braces: + max-spaces-inside: 1 + level: error + brackets: + max-spaces-inside: 1 + level: error + colons: + max-spaces-after: -1 + level: error + commas: + max-spaces-after: -1 + level: error + comments: disable + comments-indentation: disable + document-start: disable + empty-lines: + max: 3 + level: error + hyphens: + level: error + indentation: disable + key-duplicates: enable + line-length: disable + new-line-at-end-of-file: disable + new-lines: + type: unix + trailing-spaces: disable + truthy: disable diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..37f76e9 --- /dev/null +++ b/LICENSE @@ -0,0 +1,20 @@ +The MIT License (MIT) + +Copyright (c) 2022 Laur Ivan + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of +the Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS +FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR +COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER +IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN +CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. \ No newline at end of file diff --git a/README.md b/README.md new file mode 100644 index 0000000..1ccd631 --- /dev/null +++ b/README.md @@ -0,0 +1,178 @@ +# laurivan.outline + +This role installs Outline via Docker. + +## Requirements + +None + +## Role Variables + +All variables are listed below (see also `defaults/main.yml`). + +### Common variables + +You need to specify: + +- The `timezone` +- The location where torrents will be downloaded +- The location where different configuration files are stored +- The place where `docker-compose.yml` and the environment files are stored + +```yml +timezone: 'Europe/Brussels' +torrent_downloads_volume: '/mnt/download' +outline_configuration_volume: '/mnt/config' +outline_setup_path: '~/outline' +``` + +If you need to install the containers with a specific user/group ID, then define: + +```yml +outline_uid: +outline_gid: +``` +The role allows oyu to specify which components will be installed: + +```yml +deluge_enabled: true +sonarr_enabled: true +lidarr_enabled: true +jackett_enabled: true +``` + +### Deluge torrent + +You can specify the image version and the log level: + +```yml +deluge_image_version: 'latest' +deluge_loglevel: 'warning' +``` + +Deluge works on ports 6881 and 8112. You can change these ports: + +```yml +deluge_host_port: 6881 +deluge_admin_port: 8112 +``` + +You can also overwrite the location where deluge's configuration is stored (e.g. if you already have deluge installed and you want to use the Ansible role): + +```yml +deluge_config_volume: '{{ outline_configuration_volume }}/deluge' +``` + +### Radarr + +You can specify the image version and the port exposed: + +```yml +radarr_image_version: 'latest' +radarr_host_port: 7878 +``` +You can also overwrite the location where radarr's configuration is stored (e.g. if you already have it installed and you want to use the Ansible role): + +```yml +radarr_config_volume: '{{ outline_configuration_volume }}/radarr' +``` + +Radarr needs a place to copy the downloaded series: + +```yml +radarr_series_volume: '/mnt/videos/Movies' +``` + +**Notes**: + +- Depending on your settings, it will also rename your current series +- You need write access to that directory, so Sonarr can actually copy the files + +### Sonarr + +You can specify the image version and the port exposed: + +```yml +sonarr_image_version: 'latest' +sonarr_host_port: 8989 +``` +You can also overwrite the location where sonarr's configuration is stored (e.g. if you already have it installed and you want to use the Ansible role): + +```yml +sonarr_config_volume: '{{ outline_configuration_volume }}/sonarr' +``` + +Sonarr needs a place to copy the downloaded series: + +```yml +sonarr_series_volume: '/mnt/videos/Series' +``` + +**Notes**: + +- Depending on your settings, it will also rename your current series +- You need write access to that directory, so Sonarr can actually copy the files + +# Lidarr + +You can specify the image version and the port exposed: + +```yml +lidarr_image_version: 'latest' +lidarr_host_port: 8686 +``` +You can also overwrite the location where lidarr's configuration is stored (e.g. if you already have it installed and you want to use the Ansible role): + +```yml +lidarr_config_volume: '{{ outline_configuration_volume }}/lidarr' +``` +Lidarr needs a place to copy the downloaded music: + +```yml +lidarr_music_upload_volume: '/mnt/music/Reference' +``` + +You will need to add a reference to your music collection (so you don't download what you already have). The layout below allows for multiple collections: + +```yml +lidarr_music_volumes: + - {path: '/mnt/music/Sonos', alias: 'sonos' } + - {path: '/mnt/music/Audiophile', alias: 'audiophile' } + - {path: '/mnt/music/Raw', alias: 'raw' } +``` + +The `path` is the actual directory where the collection is located and the `alias` is the internal mapping name in Docker. + +# Jakett +You can specify the image version, the port exposed and to autoupdate: + +```yml +jackett_image_version: 'latest' +jackett_auto_update: true +jackett_host_port: 9117 +``` +You can also overwrite the location where jackett's configuration is stored (e.g. if you already have it installed and you want to use the Ansible role): + +```yml +jackett_config_volume: '{{ outline_configuration_volume }}/jackett' +``` + +## Dependencies + +You need a machine with docker and docker-compose installed. + +## Example Playbook + +```yml +- hosts: servers + roles: + - 'laurivan.outline' +``` + +## License + +MIT + +## Author Information + +This role was created in 2022 by [Laur Ivan](https://www.laurivan.com). diff --git a/TODO.md b/TODO.md new file mode 100644 index 0000000..d36014b --- /dev/null +++ b/TODO.md @@ -0,0 +1,5 @@ +# TODOs + + +- [ ] Add logo +- [ ] Optional S3 (allow for e.g. external minio install) \ No newline at end of file diff --git a/defaults/main.yml b/defaults/main.yml new file mode 100644 index 0000000..97dbfcb --- /dev/null +++ b/defaults/main.yml @@ -0,0 +1,26 @@ +--- +# defaults file for outline + + +outline_setup_path: '~/outline' + +outline_port: 3000 +outline_url: "http://localhost:{{ outline_port }}" +outline_cdn_url: + +outline_volume_base: "/mnt/outline" +outline_volume_redis: "{{ outline_volume_base }}/redis" +outline_volume_db: "{{ outline_volume_base }}/db" +outline_volume_s3: "{{ outline_volume_base }}/s3" + +oidc_client_id: +oidc_client_secret: +oidc_auth_uri: +oidc_token_uri: +oidc_userinfo_uri: + +outline_db_user: "postgres" +outline_db_password: "changeme" +outline_db: "outline" + + diff --git a/handlers/main.yml b/handlers/main.yml new file mode 100644 index 0000000..6d08496 --- /dev/null +++ b/handlers/main.yml @@ -0,0 +1,2 @@ +--- +# handlers file for outline \ No newline at end of file diff --git a/meta/main.yml b/meta/main.yml new file mode 100644 index 0000000..e79247b --- /dev/null +++ b/meta/main.yml @@ -0,0 +1,37 @@ +galaxy_info: + author: Laur Ivan + namespace: laurivan + role_name: outline + description: Sonarr, Lidarr, Deluge and Jackett via Docker + license: MIT + + min_ansible_version: "2.4" + min_ansible_container_version: "2.4" + + platforms: + - name: Debian + versions: + - buster + - bullseye + - name: Ubuntu + versions: + - bionic + - focal + - jammy + - name: Alpine + version: + - all + - name: ArchLinux + versions: + - all + + galaxy_tags: + - sonarr + - lidarr + - deluge + - jackett + - media + - grabber + - docker + +dependencies: [] diff --git a/molecule/default/INSTALL.rst b/molecule/default/INSTALL.rst new file mode 100644 index 0000000..1b38d09 --- /dev/null +++ b/molecule/default/INSTALL.rst @@ -0,0 +1,15 @@ +*********************************** +Delegated driver installation guide +*********************************** + +Requirements +============ + +This driver is delegated to the developer. Up to the developer to implement +requirements. + +Install +======= + +This driver is delegated to the developer. Up to the developer to implement +requirements. diff --git a/molecule/default/cleanup.yml b/molecule/default/cleanup.yml new file mode 100644 index 0000000..21c88a8 --- /dev/null +++ b/molecule/default/cleanup.yml @@ -0,0 +1,23 @@ +--- +- name: Clean up + hosts: all + gather_facts: true + tasks: + - name: Check if the docker-compose file exists. + ansible.builtin.stat: + path: "~/outline/docker-compose.yml" + register: docker_compose_file + + - name: Remove docker-compose. + community.docker.docker_compose: + project_src: ~/outline/ + build: false + state: absent + when: docker_compose_file.stat.exists + become: false + + - name: Remove the docker-compose file + ansible.builtin.file: + path: "~/outline/docker-compose.yml" + state: absent + when: docker_compose_file.stat.exists diff --git a/molecule/default/converge.yml b/molecule/default/converge.yml new file mode 100644 index 0000000..e8bc4ad --- /dev/null +++ b/molecule/default/converge.yml @@ -0,0 +1,11 @@ +--- +- name: Converge + hosts: all + # gather_facts: false + pre_tasks: + - name: "Include necessary variables" + ansible.builtin.include_vars: + file: "../../.env.yml" + + roles: + - role: laurivan.outline diff --git a/molecule/default/destroy.yml b/molecule/default/destroy.yml new file mode 100644 index 0000000..4f49a04 --- /dev/null +++ b/molecule/default/destroy.yml @@ -0,0 +1,28 @@ +--- +- name: Destroy + hosts: localhost + connection: local + gather_facts: false + no_log: "{{ molecule_no_log }}" + tasks: + # Developer must implement. + - name: Remove the docker image + community.docker.docker_container: + name: instance-outline + state: absent + + # Mandatory configuration for Molecule to function. + + - name: Populate instance config + ansible.builtin.set_fact: + instance_conf: {} + + - name: Dump instance config + ansible.builtin.copy: + content: | + # Molecule managed + + {{ instance_conf | to_json | from_json | to_yaml }} + dest: "{{ molecule_instance_config }}" + mode: 0600 + when: server.changed | default(false) | bool diff --git a/molecule/default/molecule.yml b/molecule/default/molecule.yml new file mode 100644 index 0000000..183652b --- /dev/null +++ b/molecule/default/molecule.yml @@ -0,0 +1,30 @@ +--- +role_name_check: 1 +dependency: + name: galaxy + options: + ignore-certs: true + ignore-errors: true + role-file: molecule/requirements.yml + requirements-file: molecule/requirements.yml +driver: + name: docker +platforms: + - name: instance-outline + image: "geerlingguy/docker-${MOLECULE_DISTRO:-centos8}-ansible:latest" + command: ${MOLECULE_DOCKER_COMMAND:-""} + volumes: + - /sys/fs/cgroup:/sys/fs/cgroup:ro + - /var/run/docker.sock:/tmp/docker_mounted.sock + privileged: true + pre_build_image: true +provisioner: + name: ansible + playbooks: + converge: ${MOLECULE_PLAYBOOK:-converge.yml} +verifier: + name: ansible +lint: | + set -e + yamllint . + ansible-lint . \ No newline at end of file diff --git a/molecule/default/prepare.yml b/molecule/default/prepare.yml new file mode 100644 index 0000000..d6c1f36 --- /dev/null +++ b/molecule/default/prepare.yml @@ -0,0 +1,35 @@ +--- +- name: Setup the test machine + hosts: instance-outline + tasks: + - name: Check if /var/run/docker.sock already exists + ansible.builtin.stat: + path: "/var/run/docker.sock" + register: docker_sock_stat + + - name: Create docker.sock + raw: touch /var/run/docker.sock + become: true + changed_when: false + when: not docker_sock_stat.stat.exists + + - name: Move docker.sock from tmp + raw: mount --move /tmp/docker_mounted.sock /var/run/docker.sock + become: true + changed_when: false + when: not docker_sock_stat.stat.exists + + - name: Update apt cache. + apt: update_cache=yes cache_valid_time=600 + when: ansible_os_family == 'Debian' + - name: Install python requests + pip: + name: + - requests + - docker + - docker-compose + - name: Install docker + vars: + docker_service_manage: false + include_role: + name: geerlingguy.docker diff --git a/molecule/default/verify.yml b/molecule/default/verify.yml new file mode 100644 index 0000000..e707420 --- /dev/null +++ b/molecule/default/verify.yml @@ -0,0 +1,10 @@ +--- +# This is an example playbook to execute Ansible tests. + +- name: Verify + hosts: all + gather_facts: false + tasks: + - name: Example assertion + ansible.builtin.assert: + that: true diff --git a/molecule/requirements.yml b/molecule/requirements.yml new file mode 100644 index 0000000..a6284de --- /dev/null +++ b/molecule/requirements.yml @@ -0,0 +1,4 @@ +--- +roles: + - geerlingguy.docker +collections: [] diff --git a/tasks/main.yml b/tasks/main.yml new file mode 100644 index 0000000..e88d2b5 --- /dev/null +++ b/tasks/main.yml @@ -0,0 +1,67 @@ +--- +# tasks file for outline +- name: Set up main directory + ansible.builtin.file: + state: directory + path: "{{ item }}" + owner: "{{ ansible_effective_user_id }}" + group: "{{ ansible_effective_group_id }}" + mode: "0750" + with_items: + - "{{ outline_setup_path }}" + tags: + - configuration + become: true + +- name: Set up config directories + ansible.builtin.file: + state: directory + path: "{{ item }}" + owner: "{% if outline_uid %}{{ outline_uid }}{% else %}{{ ansible_effective_user_id }}{% endif %}" + group: "{% if outline_gid %}{{ outline_gid }}{% else %}{{ ansible_effective_group_id }}{% endif %}" + mode: "0750" + with_items: + - "{{ deluge_config_volume }}" + - "{{ radarr_config_volume }}" + - "{{ sonarr_config_volume }}" + - "{{ lidarr_config_volume }}" + - "{{ jackett_config_volume }}" + tags: + - configuration + become: true + +- name: Set up upload directories + ansible.builtin.file: + state: directory + path: "{{ item }}" + owner: "{% if outline_uid %}{{ outline_uid }}{% else %}{{ ansible_effective_user_id }}{% endif %}" + group: "{% if outline_gid %}{{ outline_gid }}{% else %}{{ ansible_effective_group_id }}{% endif %}" + mode: "0750" + with_items: + - "{{ radarr_upload_volume }}" + - "{{ sonarr_upload_volume }}" + - "{{ lidarr_upload_volume }}" + tags: + - configuration + become: true + +- name: Write configuration files + ansible.builtin.template: + src: "{{ item }}.j2" + dest: "{{ outline_setup_path }}/{{ item }}" + mode: '0640' + loop: + - "docker-compose.yml" + - "env.deluge.conf" + - "env.radarr.conf" + - "env.sonarr.conf" + - "env.lidarr.conf" + - "env.jackett.conf" + tags: + - configuration + +- name: Ensure all requested components are running. + community.docker.docker_compose: + project_src: "{{ outline_setup_path }}" + build: false + become: false diff --git a/templates/docker-compose.yml.j2 b/templates/docker-compose.yml.j2 new file mode 100644 index 0000000..5430742 --- /dev/null +++ b/templates/docker-compose.yml.j2 @@ -0,0 +1,72 @@ +version: "3.3" +services: + redis: + image: docker.io/library/redis:alpine + command: --save 60 1 --loglevel warning + restart: unless-stopped + healthcheck: + test: ["CMD-SHELL", "redis-cli ping | grep PONG"] + start_period: 20s + interval: 30s + retries: 5 + timeout: 3s + networks: + - outline + volumes: + - {{ outline_volume_redis }}:/data + - /etc/timezone:/etc/timezone:ro + - /etc/localtime:/etc/localtime:ro + + postgres: + image: docker.io/library/postgres:12-alpine + env_file: + - "{{ outline_setup_path }}/env.db.conf" + restart: unless-stopped + healthcheck: + test: ["CMD-SHELL", "pg_isready -d $${POSTGRES_DB} -U $${POSTGRES_USER}"] + start_period: 20s + interval: 30s + retries: 5 + timeout: 5s + networks: + - outline +{% if outline_db_port %} + ports: + - {{ outline_db_port }}:5432 +{% endif %} + volumes: + - {{ outline_volume_db }}:/var/lib/postgresql/data + + + s3: + image: lphoward/fake-s3 + env_file: + - "{{ outline_setup_path }}/env.s3.conf" +{% if outline_s3_port %} + ports: + - {{ outline_fake_s3_port }}:4569 +{% endif %} + volumes: + - {{ outline_volume_s3 }}:/fakes3_root + networks: + - outline + + outline: + image: outlinewiki/outline:latest + command: sh -c "yarn sequelize:migrate --env production-ssl-disabled && yarn start" + env_file: + - ./env.outline.conf + - ./env.oidc.conf + restart: always + ports: + - {{ outline_port }}:3000 + depends_on: + - postgres + - redis + - s3 + networks: + - outline + +networks: + outline: {} + diff --git a/templates/env.db.conf.j2 b/templates/env.db.conf.j2 new file mode 100644 index 0000000..d03754f --- /dev/null +++ b/templates/env.db.conf.j2 @@ -0,0 +1,4 @@ +POSTGRES_USER={{ outline_db_user }} +POSTGRES_PASSWORD={{ outline_db_password }} + +POSTGRES_DB={{ outline_db }} diff --git a/templates/env.oidc.conf.j2 b/templates/env.oidc.conf.j2 new file mode 100644 index 0000000..97c9c32 --- /dev/null +++ b/templates/env.oidc.conf.j2 @@ -0,0 +1,18 @@ +# To configure generic OIDC auth, you'll need some kind of identity provider. +# See documentation for whichever IdP you use to acquire the following info: +# Redirect URI is https:///auth/oidc.callback +OIDC_CLIENT_ID={{ oidc_client_id }} +OIDC_CLIENT_SECRET={{ oidc_client_secret }} +OIDC_AUTH_URI= {{ oidc_auth_uri }} +OIDC_TOKEN_URI={{ oidc_token_uri }} +OIDC_USERINFO_URI={{ oidc_userinfo_uri }} + +# Specify which claims to derive user information from +# Supports any valid JSON path with the JWT payload +OIDC_USERNAME_CLAIM=preferred_username + +# Display name for OIDC authentication +OIDC_DISPLAY_NAME=OpenID + +# Space separated auth scopes. +OIDC_SCOPES=openid profile email \ No newline at end of file diff --git a/templates/env.outline.conf.j2 b/templates/env.outline.conf.j2 new file mode 100644 index 0000000..402217b --- /dev/null +++ b/templates/env.outline.conf.j2 @@ -0,0 +1,79 @@ +# Copy this file to .env, remove this comment and change the keys. For development +# with docker this should mostly work out of the box other than setting the Slack +# keys (for auth) and the SECRET_KEY. +# +# Please use `openssl rand -hex 32` to create SECRET_KEY +SECRET_KEY=generate_a_new_key +UTILS_SECRET=generate_a_new_key + +DATABASE_URL=postgres://{{ outline_db_user }}:{{ outline_db_password }}@postgres:5432/{{ outline_db }} +DATABASE_URL_TEST=postgres://{{ outline_db_user }}:{{ outline_db_password }}@wk-postgres:5432/{{ outline_db }}_test +REDIS_URL=redis://redis:6379 + +# Must point to the publicly accessible URL for the installation +URL={{ outline_url }} +PORT=3000 + +# Optional. If using a Cloudfront distribution or similar the origin server +# should be set to the same as URL. +CDN_URL={{ outline_cdn_url }} + +# enforce (auto redirect to) https in production, (optional) default is true. +# set to false if your SSL is terminated at a loadbalancer, for example +FORCE_HTTPS=true + +ENABLE_UPDATES=true +DEBUG=cache,presenters,events,emails,mailer,utils,multiplayer,server,services + +# Third party signin credentials (at least one is required) +SLACK_KEY=get_a_key_from_slack +SLACK_SECRET=get_the_secret_of_above_key + +# To configure Google auth, you'll need to create an OAuth Client ID at +# => https://console.cloud.google.com/apis/credentials +# +# When configuring the Client ID, add an Authorized redirect URI: +# https:///auth/google.callback +GOOGLE_CLIENT_ID= +GOOGLE_CLIENT_SECRET= + +# Comma separated list of domains to be allowed (optional) +# If not set, all Google apps domains are allowed by default +GOOGLE_ALLOWED_DOMAINS= + +# Third party credentials (optional) +SLACK_VERIFICATION_TOKEN= +SLACK_APP_ID=A0XXXXXXX +SLACK_MESSAGE_ACTIONS=true +GOOGLE_ANALYTICS_ID= +SENTRY_DSN= + +# AWS credentials (optional in development) +AWS_ACCESS_KEY_ID=get_a_key_from_aws +AWS_SECRET_ACCESS_KEY=get_the_secret_of_above_key +AWS_REGION=xx-xxxx-x +AWS_S3_UPLOAD_BUCKET_URL=http://s3:4569 +AWS_S3_UPLOAD_BUCKET_NAME=outline-bucket +AWS_S3_UPLOAD_MAX_SIZE=26214400 +AWS_S3_FORCE_PATH_STYLE=true +# uploaded s3 objects permission level, default is private +# set to "public-read" to allow public access +AWS_S3_ACL=private + +# Emails configuration (optional) +SMTP_HOST= +SMTP_PORT= +SMTP_USERNAME= +SMTP_PASSWORD= +SMTP_FROM_EMAIL= +SMTP_REPLY_EMAIL= + +# Custom logo that displays on the authentication screen, scaled to height: 60px +# TEAM_LOGO=https://example.com/images/logo.png + +# See translate.getoutline.com for a list of available language codes and their +# percentage translated. +DEFAULT_LANGUAGE=en_US + + + diff --git a/templates/env.redis.conf.j2 b/templates/env.redis.conf.j2 new file mode 100644 index 0000000..e69de29 diff --git a/templates/env.s3.conf.j2 b/templates/env.s3.conf.j2 new file mode 100644 index 0000000..e69de29 diff --git a/tests/inventory b/tests/inventory new file mode 100644 index 0000000..878877b --- /dev/null +++ b/tests/inventory @@ -0,0 +1,2 @@ +localhost + diff --git a/tests/test.yml b/tests/test.yml new file mode 100644 index 0000000..8b2fb50 --- /dev/null +++ b/tests/test.yml @@ -0,0 +1,5 @@ +--- +- hosts: localhost + remote_user: root + roles: + - outline \ No newline at end of file diff --git a/vars/main.yml b/vars/main.yml new file mode 100644 index 0000000..11d3b70 --- /dev/null +++ b/vars/main.yml @@ -0,0 +1,2 @@ +--- +# vars file for outline \ No newline at end of file