remove!(camo): unused
This commit is contained in:
parent
d0086c85c3
commit
0d31368132
6 changed files with 0 additions and 262 deletions
|
@ -1,25 +0,0 @@
|
|||
---
|
||||
# Infrastructure
|
||||
# Ansible instructions to deploy the infrastructure
|
||||
# Copyright (C) 2019-2020 Christoph (Sheogorath) Kern
|
||||
# Copyright (C) 2020 Saibotk
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation, version 3 of the License.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
- name: Install & configure camo
|
||||
hosts: camo
|
||||
roles:
|
||||
- docker
|
||||
- docker_cleanup
|
||||
- traefik
|
||||
- camo
|
|
@ -1,35 +0,0 @@
|
|||
Camo
|
||||
=========
|
||||
|
||||
This will setup a [go-camo](https://github.com/cactus/go-camo) content proxy server with their official docker container and traefik.
|
||||
|
||||
Requirements
|
||||
------------
|
||||
|
||||
You will need to have docker, docker-compose and traefik installed or declared as dependencies with their respective roles.
|
||||
|
||||
**This role assumes that you have setup traefik with an endpoint called `websecure`.**
|
||||
|
||||
Role Variables
|
||||
--------------
|
||||
|
||||
**Please look at the [defaults/main.yml](defaults/main.yml) for all available variables and their description.**
|
||||
|
||||
**Note: Lines that are commented out via `#` are usually still valid/used variables, but they are not defined by default, so they might enable a feature, when uncommenting/defining them!**
|
||||
|
||||
### Global variables, that are used:
|
||||
|
||||
- `proxy_network`: Defined by the local traefik installation, this is the shared proxy network used by traefik to reach the containers. (optional)
|
||||
- `proxy_hiddenservice`: Defined by the local traefik installation, this is used to generate the alt-svc header for the alternative Tor domain. (optional)
|
||||
|
||||
Dependencies
|
||||
------------
|
||||
|
||||
- docker
|
||||
- docker-compose
|
||||
- traefik
|
||||
|
||||
License
|
||||
-------
|
||||
|
||||
GPL-3.0-only
|
|
@ -1,42 +0,0 @@
|
|||
---
|
||||
# Default variables for the camo role
|
||||
|
||||
# Infrastructure
|
||||
# Ansible instructions to deploy the infrastructure
|
||||
# Copyright (C) 2019-2020 Christoph (Sheogorath) Kern
|
||||
# Copyright (C) 2020 Saibotk
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation, version 3 of the License.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
# The install location (where the docker-compose file is stored)
|
||||
camo_install_location: "/srv/camo"
|
||||
|
||||
# The camo version that should be used
|
||||
# renovate: depName=docker.io/cactus4docker/go-camo
|
||||
camo_version: "2.6.0"
|
||||
|
||||
# The domain under which camo should be available using traefik
|
||||
camo_domain: camo.example.com
|
||||
|
||||
# The certresolver that is used by traefik for camo's domain
|
||||
camo_traefik_certresolver: "letsencrypt_http"
|
||||
|
||||
# The HMAC key to be used
|
||||
camo_key: "{{ lookup('passwordstore', camo_domain + '/hmac-key create=true length=128') }}"
|
||||
|
||||
# The maximum allowed response size (in KB). (0 means unlimited)
|
||||
camo_max_size: 0
|
||||
|
||||
# Docker image and version
|
||||
camo_image: "docker.io/cactus4docker/go-camo"
|
||||
camo_image_version: "v{{ camo_version }}"
|
|
@ -1,44 +0,0 @@
|
|||
galaxy_info:
|
||||
author: saibotk
|
||||
description: "Installs a go-camo image proxy server via Docker."
|
||||
license: GPL-3.0-only
|
||||
min_ansible_version: "2.9"
|
||||
standalone: true
|
||||
|
||||
platforms:
|
||||
- name: EL
|
||||
versions:
|
||||
- all
|
||||
- name: GenericUNIX
|
||||
versions:
|
||||
- all
|
||||
- name: Fedora
|
||||
versions:
|
||||
- all
|
||||
- name: opensuse
|
||||
versions:
|
||||
- all
|
||||
- name: GenericBSD
|
||||
versions:
|
||||
- all
|
||||
- name: FreeBSD
|
||||
versions:
|
||||
- all
|
||||
- name: Ubuntu
|
||||
versions:
|
||||
- all
|
||||
- name: SLES
|
||||
versions:
|
||||
- all
|
||||
- name: GenericLinux
|
||||
versions:
|
||||
- all
|
||||
- name: Debian
|
||||
versions:
|
||||
- all
|
||||
|
||||
galaxy_tags: []
|
||||
|
||||
dependencies:
|
||||
- role: docker
|
||||
- role: traefik
|
|
@ -1,54 +0,0 @@
|
|||
---
|
||||
# Tasks file for the camo role
|
||||
|
||||
# Infrastructure
|
||||
# Ansible instructions to deploy the infrastructure
|
||||
# Copyright (C) 2019-2020 Christoph (Sheogorath) Kern
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation, version 3 of the License.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
- name: Create install directory
|
||||
ansible.builtin.file:
|
||||
path: "{{ item }}"
|
||||
state: directory
|
||||
mode: "0700"
|
||||
owner: "root"
|
||||
group: "root"
|
||||
with_items:
|
||||
- "{{ camo_install_location }}"
|
||||
become: true
|
||||
tags:
|
||||
- camo
|
||||
|
||||
- name: Deploy docker-compose.yml
|
||||
ansible.builtin.template:
|
||||
src: docker-compose.yml
|
||||
dest: "{{ camo_install_location }}/docker-compose.yml"
|
||||
mode: "0600"
|
||||
owner: "root"
|
||||
group: "root"
|
||||
validate: docker compose -f %s config -q
|
||||
tags:
|
||||
- docker
|
||||
- camo
|
||||
become: true
|
||||
|
||||
- name: Compose camo container
|
||||
community.docker.docker_compose_v2:
|
||||
state: present
|
||||
project_src: "{{ camo_install_location }}"
|
||||
pull: always
|
||||
remove_orphans: true
|
||||
tags:
|
||||
- camo
|
||||
become: true
|
|
@ -1,62 +0,0 @@
|
|||
{{ ansible_managed | comment }}
|
||||
|
||||
# Infrastructure
|
||||
# Ansible instructions to deploy the infrastructure
|
||||
# Copyright (C) 2019-2020 Christoph (Sheogorath) Kern
|
||||
# Copyright (C) 2020 Saibotk
|
||||
#
|
||||
# This program is free software: you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation, version 3 of the License.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
version: '2'
|
||||
services:
|
||||
camo:
|
||||
image: "{{ camo_image }}:{{ camo_image_version }}"
|
||||
mem_limit: 64mb
|
||||
memswap_limit: 128mb
|
||||
security_opt:
|
||||
- no-new-privileges
|
||||
environment:
|
||||
- "GOCAMO_HMAC={{ camo_key }}"
|
||||
labels:
|
||||
- "traefik.enable=true"
|
||||
|
||||
- "traefik.http.routers.camo.rule=Host(`{{ camo_domain }}`) && PathPrefix(`/`)"
|
||||
- "traefik.http.routers.camo.entrypoints=websecure"
|
||||
- "traefik.http.routers.camo.tls=true"
|
||||
- "traefik.http.routers.camo.tls.certresolver={{ camo_traefik_certresolver }}"
|
||||
- "traefik.http.routers.camo.middlewares=camo,compress"
|
||||
- "traefik.http.middlewares.camo.headers.sslredirect=true"
|
||||
- "traefik.http.middlewares.camo.headers.stsSeconds=63072000"
|
||||
- "traefik.http.middlewares.camo.headers.referrerPolicy=no-referrer"
|
||||
|
||||
{% if proxy_network is defined %}
|
||||
- "traefik.docker.network={{ proxy_network }}"
|
||||
{% endif %}
|
||||
{% if proxy_hiddenservice is defined and proxy_hiddenservice.content is defined %}
|
||||
- "traefik.http.middlewares.camo.headers.customresponseheaders.alt-svc=h2={{ proxy_hiddenservice['content'] | b64decode | trim }}:443; ma=2592000"
|
||||
{% endif %}
|
||||
|
||||
command:
|
||||
- "--max-size={{ camo_max_size }}"
|
||||
- "--server-name='go-camo v{{ camo_version }}'"
|
||||
restart: always
|
||||
{% if proxy_network is defined %}
|
||||
networks:
|
||||
{{ proxy_network }}:
|
||||
{% endif %}
|
||||
|
||||
{% if proxy_network is defined %}
|
||||
networks:
|
||||
{{ proxy_network }}:
|
||||
external: true
|
||||
{% endif %}
|
Loading…
Add table
Reference in a new issue