init
This commit is contained in:
110
TubeArchivist/.drone.yml
Normal file
110
TubeArchivist/.drone.yml
Normal file
@@ -0,0 +1,110 @@
|
||||
---
|
||||
kind: pipeline
|
||||
type: docker
|
||||
name: deploy
|
||||
|
||||
environment:
|
||||
PACKAGE: TubeArchivist
|
||||
URL: tubearchivist.alexlebens.net
|
||||
|
||||
steps:
|
||||
- name: Tests
|
||||
image: ps03fd.alexlebens.net:5000/droneimage:latest
|
||||
commands:
|
||||
- /scripts/tests.sh
|
||||
|
||||
- name: Nofification > Discord | Tests - Failure
|
||||
image: appleboy/drone-discord
|
||||
settings:
|
||||
webhook_id:
|
||||
from_secret: discord_webhook_id
|
||||
webhook_token:
|
||||
from_secret: discord_webhook_token
|
||||
username: DroneCI - ps03fd
|
||||
message: Docker compose validation for TubeArchivist failed.
|
||||
when:
|
||||
status:
|
||||
- failure
|
||||
|
||||
- name: Configuration
|
||||
image: ps03fd.alexlebens.net:5000/droneimage:latest
|
||||
commands:
|
||||
- mkdir ~/.ssh/
|
||||
- echo "$SSH_KEY" > ~/.ssh/id_rsa
|
||||
- chmod 600 ~/.ssh/id_rsa
|
||||
- ssh-keyscan -H $HOST_IP >> ~/.ssh/known_hosts
|
||||
- /scripts/configuration.sh
|
||||
environment:
|
||||
SSH_KEY:
|
||||
from_secret: ssh_key_ps03fd_drone
|
||||
DOCKER_HOST:
|
||||
from_secret: docker_host_ps03fd
|
||||
HOST_IP:
|
||||
from_secret: host_ip_ps03fd
|
||||
UPTIMEKUMA_NAME:
|
||||
from_secret: uptimekuma_name
|
||||
UPTIMEKUMA_PASSWORD:
|
||||
from_secret: uptimekuma_password
|
||||
UPTIMEKUMA_URL:
|
||||
from_secret: uptimekuma_url
|
||||
when:
|
||||
branch:
|
||||
- main
|
||||
|
||||
- name: Nofification > Discord | Configuration - Failure
|
||||
image: appleboy/drone-discord
|
||||
settings:
|
||||
webhook_id:
|
||||
from_secret: discord_webhook_id
|
||||
webhook_token:
|
||||
from_secret: discord_webhook_token
|
||||
username: DroneCI - ps03fd
|
||||
message: Configuration for TubeArchivist failed.
|
||||
when:
|
||||
status:
|
||||
- failure
|
||||
|
||||
- name: Deploy
|
||||
image: ps03fd.alexlebens.net:5000/droneimage:latest
|
||||
commands:
|
||||
- mkdir ~/.ssh/
|
||||
- echo "$SSH_KEY" > ~/.ssh/id_rsa
|
||||
- chmod 600 ~/.ssh/id_rsa
|
||||
- ssh-keyscan -H $HOST_IP >> ~/.ssh/known_hosts
|
||||
- /scripts/deploy.sh
|
||||
environment:
|
||||
SSH_KEY:
|
||||
from_secret: ssh_key_ps03fd_drone
|
||||
DOCKER_HOST:
|
||||
from_secret: docker_host_ps03fd
|
||||
HOST_IP:
|
||||
from_secret: host_ip_ps03fd
|
||||
when:
|
||||
branch:
|
||||
- main
|
||||
|
||||
- name: Nofification > Discord | Deploy - Success
|
||||
image: appleboy/drone-discord
|
||||
settings:
|
||||
webhook_id:
|
||||
from_secret: discord_webhook_id
|
||||
webhook_token:
|
||||
from_secret: discord_webhook_token
|
||||
username: DroneCI - ps03fd
|
||||
message: Docker compose deployment for TubeArchivist succeeded
|
||||
when:
|
||||
status:
|
||||
- sucess
|
||||
|
||||
- name: Nofification > Discord | Deploy - Failure
|
||||
image: appleboy/drone-discord
|
||||
settings:
|
||||
webhook_id:
|
||||
from_secret: discord_webhook_id
|
||||
webhook_token:
|
||||
from_secret: discord_webhook_token
|
||||
username: DroneCI - ps03fd
|
||||
message: Docker compose deployment for TubeArchivist failed.
|
||||
when:
|
||||
status:
|
||||
- failure
|
9
TubeArchivist/.env
Normal file
9
TubeArchivist/.env
Normal file
@@ -0,0 +1,9 @@
|
||||
ES_URL=http://tube_archivist_es:9200
|
||||
REDIS_HOST=tube_archivist_redis
|
||||
HOST_UID=1000
|
||||
HOST_GID=1000
|
||||
TA_HOST=tubearchivist.alexlebens.net
|
||||
TA_USERNAME=tubearchivist
|
||||
TA_PASSWORD='24wrsfxv@$WRSFXV'
|
||||
ELASTIC_PASSWORD='35etdgcb#%ETDGCB'
|
||||
TZ=America/Denver
|
5
TubeArchivist/.es.env
Normal file
5
TubeArchivist/.es.env
Normal file
@@ -0,0 +1,5 @@
|
||||
ELASTIC_PASSWORD='35etdgcb#%ETDGCB'
|
||||
ES_JAVA_OPTS=-Xms512m -Xmx512m
|
||||
xpack.security.enabled=true
|
||||
discovery.type=single-node
|
||||
path.repo=/usr/share/elasticsearch/data/snapshot
|
3
TubeArchivist/README.md
Normal file
3
TubeArchivist/README.md
Normal file
@@ -0,0 +1,3 @@
|
||||
# TubeArchivist
|
||||
|
||||
[](https://drone.alexlebens.net/alexlebens/TubeArchivist)
|
17
TubeArchivist/UptimeKuma/docker-1.json
Normal file
17
TubeArchivist/UptimeKuma/docker-1.json
Normal file
@@ -0,0 +1,17 @@
|
||||
{
|
||||
"type": "docker",
|
||||
"name": "TubeArchivist ES - Docker",
|
||||
"interval": 60,
|
||||
"retryInterval": 20,
|
||||
"maxretries": 1,
|
||||
"notificationIDList": [
|
||||
3,
|
||||
4
|
||||
],
|
||||
"url": "https://tubearchivist.alexlebens.net",
|
||||
"accepted_statuscodes": [
|
||||
"200-299"
|
||||
],
|
||||
"docker_container": "tube_archivist_es",
|
||||
"docker_host": 1
|
||||
}
|
17
TubeArchivist/UptimeKuma/docker-2.json
Normal file
17
TubeArchivist/UptimeKuma/docker-2.json
Normal file
@@ -0,0 +1,17 @@
|
||||
{
|
||||
"type": "docker",
|
||||
"name": "TubeArchivist Redis - Docker",
|
||||
"interval": 60,
|
||||
"retryInterval": 20,
|
||||
"maxretries": 1,
|
||||
"notificationIDList": [
|
||||
3,
|
||||
4
|
||||
],
|
||||
"url": "https://tubearchivist.alexlebens.net",
|
||||
"accepted_statuscodes": [
|
||||
"200-299"
|
||||
],
|
||||
"docker_container": "tube_archivist_redis",
|
||||
"docker_host": 1
|
||||
}
|
17
TubeArchivist/UptimeKuma/docker-3.json
Normal file
17
TubeArchivist/UptimeKuma/docker-3.json
Normal file
@@ -0,0 +1,17 @@
|
||||
{
|
||||
"type": "docker",
|
||||
"name": "TubeArchivist - Docker",
|
||||
"interval": 60,
|
||||
"retryInterval": 20,
|
||||
"maxretries": 1,
|
||||
"notificationIDList": [
|
||||
3,
|
||||
4
|
||||
],
|
||||
"url": "https://tubearchivist.alexlebens.net",
|
||||
"accepted_statuscodes": [
|
||||
"200-299"
|
||||
],
|
||||
"docker_container": "tube_archivist",
|
||||
"docker_host": 1
|
||||
}
|
15
TubeArchivist/UptimeKuma/http-1.json
Normal file
15
TubeArchivist/UptimeKuma/http-1.json
Normal file
@@ -0,0 +1,15 @@
|
||||
{
|
||||
"type": "http",
|
||||
"name": "TubeArchivist - Web",
|
||||
"interval": 60,
|
||||
"retryInterval": 20,
|
||||
"maxretries": 1,
|
||||
"notificationIDList": [
|
||||
3,
|
||||
4
|
||||
],
|
||||
"url": "https://tubearchivist.alexlebens.net",
|
||||
"accepted_statuscodes": [
|
||||
"200-299"
|
||||
]
|
||||
}
|
105
TubeArchivist/docker-compose.yml
Normal file
105
TubeArchivist/docker-compose.yml
Normal file
@@ -0,0 +1,105 @@
|
||||
services:
|
||||
tube_archivist_es:
|
||||
container_name: tube_archivist_es
|
||||
env_file:
|
||||
- .es.env
|
||||
image: bbilly1/tubearchivist-es:latest
|
||||
logging:
|
||||
driver: json-file
|
||||
options:
|
||||
max-size: 50m
|
||||
max-file: "3"
|
||||
networks:
|
||||
traefik: null
|
||||
restart: unless-stopped
|
||||
ulimits:
|
||||
memlock:
|
||||
soft: -1
|
||||
hard: -1
|
||||
volumes:
|
||||
- es:/usr/share/elasticsearch/data
|
||||
|
||||
tube_archivist_redis:
|
||||
container_name: tube_archivist_redis
|
||||
depends_on:
|
||||
- tube_archivist_es
|
||||
image: redislabs/rejson:latest
|
||||
logging:
|
||||
driver: json-file
|
||||
options:
|
||||
max-size: 50m
|
||||
max-file: "3"
|
||||
networks:
|
||||
traefik: null
|
||||
restart: unless-stopped
|
||||
volumes:
|
||||
- redis:/data
|
||||
|
||||
tube_archivist:
|
||||
container_name: tube_archivist
|
||||
depends_on:
|
||||
- tube_archivist_es
|
||||
- tube_archivist_redis
|
||||
env_file:
|
||||
- .env
|
||||
image: bbilly1/tubearchivist
|
||||
labels:
|
||||
traefik.docker.network: traefik
|
||||
traefik.enable: true
|
||||
traefik.http.routers.tube_archivist.entrypoints: websecure
|
||||
traefik.http.routers.tube_archivist.rule: Host(`tubearchivist.alexlebens.net`)
|
||||
traefik.http.routers.tube_archivist.service: tube_archivist
|
||||
traefik.http.services.tube_archivist.loadbalancer.server.port: 8000
|
||||
logging:
|
||||
driver: json-file
|
||||
options:
|
||||
max-size: 50m
|
||||
max-file: "3"
|
||||
networks:
|
||||
traefik: null
|
||||
privileged: true
|
||||
restart: unless-stopped
|
||||
volumes:
|
||||
- media:/youtube
|
||||
- cache:/cache
|
||||
|
||||
networks:
|
||||
traefik:
|
||||
name: traefik
|
||||
external: true
|
||||
|
||||
volumes:
|
||||
# media:
|
||||
# driver: local
|
||||
# driver_opts:
|
||||
# type: none
|
||||
# o: bind
|
||||
# device: /var/lib/docker/volumes/partition/tube_archivist_media
|
||||
|
||||
media:
|
||||
driver: local
|
||||
driver_opts:
|
||||
type: nfs
|
||||
o: addr=192.168.1.194,nfsvers=4
|
||||
device: :/volume2/Storage/TubeArchivist
|
||||
|
||||
cache:
|
||||
driver: local
|
||||
driver_opts:
|
||||
type: none
|
||||
o: bind
|
||||
device: /var/lib/docker/volumes/partition/tube_archivist_cache
|
||||
|
||||
redis:
|
||||
driver: local
|
||||
driver_opts:
|
||||
type: none
|
||||
o: bind
|
||||
device: /var/lib/docker/volumes/partition/tube_archivist_redis
|
||||
|
||||
es:
|
||||
driver: local
|
||||
driver_opts:
|
||||
type: none
|
||||
o: bind
|
||||
device: /var/lib/docker/volumes/partition/tube_archivist_es
|
Reference in New Issue
Block a user