initial
This commit is contained in:
		
							
								
								
									
										24
									
								
								utility/metrics/metrics.sh
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										24
									
								
								utility/metrics/metrics.sh
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,24 @@
 | 
				
			|||||||
 | 
					#!/bin/bash
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					#i hope i can make this work
 | 
				
			||||||
 | 
					# it runs and it works in offstage but not here...
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					#hmm this worked in the other account..
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# Select an existing docker image tag
 | 
				
			||||||
 | 
					VERSION=latest
 | 
				
			||||||
 | 
					# Path to configured `settings.json`
 | 
				
			||||||
 | 
					SETTINGS=/path/to/settings.json
 | 
				
			||||||
 | 
					# Port used internally (use the same one than in `settings.json`)
 | 
				
			||||||
 | 
					SERVICE_PORT=3000
 | 
				
			||||||
 | 
					# Port to publish
 | 
				
			||||||
 | 
					PUBLISHED_PORT=2002
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					docker run \
 | 
				
			||||||
 | 
					    -d \
 | 
				
			||||||
 | 
					    --rm \
 | 
				
			||||||
 | 
					    --name metrics \
 | 
				
			||||||
 | 
					    --entrypoint="" \
 | 
				
			||||||
 | 
					    -p=127.0.0.1:$PUBLISHED_PORT:$SERVICE_PORT \
 | 
				
			||||||
 | 
					    --volume=$SETTINGS:/metrics/settings.json \
 | 
				
			||||||
 | 
					    ghcr.io/lowlighter/metrics:$VERSION npm start
 | 
				
			||||||
							
								
								
									
										225
									
								
								utility/metrics/settings.json
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										225
									
								
								utility/metrics/settings.json
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,225 @@
 | 
				
			|||||||
 | 
					{
 | 
				
			||||||
 | 
					  "//": "Example of configuration for metrics web instance",
 | 
				
			||||||
 | 
					  "//": "====================================================================",
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  "token": "A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",          "//": "GitHub Personal Token (required)",
 | 
				
			||||||
 | 
					  "modes": ["embed", "insights"],       "//": "Web instance enabled modes",
 | 
				
			||||||
 | 
					  "restricted": [],                     "//": "Authorized users (empty to disable)",
 | 
				
			||||||
 | 
					  "maxusers": 0,                        "//": "Maximum users, (0 to disable)",
 | 
				
			||||||
 | 
					  "cached": 3600000,                    "//": "Cache time rendered metrics (0 to disable)",
 | 
				
			||||||
 | 
					  "ratelimiter": null,                  "//": "Rate limiter (see express-rate-limit documentation)",
 | 
				
			||||||
 | 
					  "port": 3000,                         "//": "Listening port",
 | 
				
			||||||
 | 
					  "optimize": true,                     "//": "SVG optimization",
 | 
				
			||||||
 | 
					  "debug": false,                       "//": "Debug logs",
 | 
				
			||||||
 | 
					  "debug.headless": false,              "//": "Debug puppeteer process",
 | 
				
			||||||
 | 
					  "mocked": false,                      "//": "Use mocked data instead of live APIs (use 'force' to use mocked token even if real token are defined)",
 | 
				
			||||||
 | 
					  "repositories": 100,                  "//": "Number of repositories to use",
 | 
				
			||||||
 | 
					  "padding": ["0", "8 + 11%"],          "//": "Image padding (default)",
 | 
				
			||||||
 | 
					  "outputs": ["svg", "png", "json"],    "//": "Image output formats (empty to enable all)",
 | 
				
			||||||
 | 
					  "hosted": {
 | 
				
			||||||
 | 
					    "by": "ReachableCEO Dev Workstation",                           "//": "Web instance host (displayed in footer)",
 | 
				
			||||||
 | 
					    "link": "https://www.reachableceo.com",                         "//": "Web instance host link (displayed in footer)"
 | 
				
			||||||
 | 
					  },
 | 
				
			||||||
 | 
					  "oauth":{
 | 
				
			||||||
 | 
					    "id": null,                         "//": "GitHub OAUTH client id",
 | 
				
			||||||
 | 
					    "secret": null,                     "//": "GitHub OAUTH client secret",
 | 
				
			||||||
 | 
					    "url":"https://example.com",        "//": "GitHub OAUTH callback url (must be the same as the web instance host)"
 | 
				
			||||||
 | 
					  },
 | 
				
			||||||
 | 
					  "api":{
 | 
				
			||||||
 | 
					    "rest": null,                       "//": "GitHub REST API custom endpoint",
 | 
				
			||||||
 | 
					    "graphql": null,                    "//": "GitHub GraphQL API custom endpoint"
 | 
				
			||||||
 | 
					  },
 | 
				
			||||||
 | 
					  "control":{
 | 
				
			||||||
 | 
					    "token": null,                      "//": "Control token (can be used by external services to perform actions on instance, such as stopping it for redeploys)"
 | 
				
			||||||
 | 
					  },
 | 
				
			||||||
 | 
					  "community": {
 | 
				
			||||||
 | 
					    "templates": [],                    "//": "Additional community templates to setup"
 | 
				
			||||||
 | 
					  },
 | 
				
			||||||
 | 
					  "templates": {
 | 
				
			||||||
 | 
					    "default": "classic",               "//": "Default template",
 | 
				
			||||||
 | 
					    "enabled": [],                      "//": "Enabled templates (empty to enable all)"
 | 
				
			||||||
 | 
					  },
 | 
				
			||||||
 | 
					  "extras": {
 | 
				
			||||||
 | 
					    "default": false,                   "//": "Default extras state (advised to let 'false' unless in debug mode)",
 | 
				
			||||||
 | 
					    "features": false,                  "//": "Enable extra features (advised to let 'false' on web instances), see below for supported features",
 | 
				
			||||||
 | 
					                                        "//": "________________________________________________________________________",
 | 
				
			||||||
 | 
					                                        "//": "metrics.setup.community.templates | Allow community templates download",
 | 
				
			||||||
 | 
					                                        "//": "metrics.setup.community.presets   | Allow community presets usage",
 | 
				
			||||||
 | 
					                                        "//": "metrics.api.github.overuse        | Allow GitHub API intensive requests",
 | 
				
			||||||
 | 
					                                        "//": "metrics.api.*                     | Allow use of external API requests",
 | 
				
			||||||
 | 
					                                        "//": "metrics.cpu.overuse               | Allow CPU intensive requests",
 | 
				
			||||||
 | 
					                                        "//": "metrics.run.tempdir               | Allow access to temporary directory (I/O operations may be performed)",
 | 
				
			||||||
 | 
					                                        "//": "metrics.run.git                   | Allow to run git",
 | 
				
			||||||
 | 
					                                        "//": "metrics.run.licensed              | Allow to run licensed",
 | 
				
			||||||
 | 
					                                        "//": "metrics.run.user.cmd              | Allow to run ANY command by user (USE WITH CAUTION!)",
 | 
				
			||||||
 | 
					                                        "//": "metrics.run.puppeteer.scrapping   | Allow to run puppeteer to scrape data",
 | 
				
			||||||
 | 
					                                        "//": "metrics.run.puppeteer.user.css    | Allow to run CSS by user during puppeteer render",
 | 
				
			||||||
 | 
					                                        "//": "metrics.run.puppeteer.user.js     | Allow to run JavaScript by user during puppeteer render",
 | 
				
			||||||
 | 
					                                        "//": "metrics.npm.optional.*            | Allow use of specified dependency",
 | 
				
			||||||
 | 
					                                        "//": "________________________________________________________________________",
 | 
				
			||||||
 | 
					                                        "//": "Additional extra features when user is logged with GitHub",
 | 
				
			||||||
 | 
					    "logged": [
 | 
				
			||||||
 | 
					      "metrics.api.github.overuse"
 | 
				
			||||||
 | 
					    ]
 | 
				
			||||||
 | 
					  },
 | 
				
			||||||
 | 
					  "plugins.default": false,             "//": "Default plugin state (advised to let 'false' unless in debug mode)",
 | 
				
			||||||
 | 
					  "plugins": {                          "//": "Global plugin configuration",
 | 
				
			||||||
 | 
					    "isocalendar":{
 | 
				
			||||||
 | 
					      "enabled": false,                 "//": "Enable isocalendar plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "languages":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable languages plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "stargazers":{
 | 
				
			||||||
 | 
					      "worldmap.token": null,           "//": "Stargazers worldmap token",
 | 
				
			||||||
 | 
					      "enabled": false,                 "//": "Enable stargazers plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "lines":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable lines plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "topics":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable topics plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "stars":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable stars plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "licenses":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable licenses plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "habits":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable habits plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "contributors":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable contributors plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "followup":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable followup plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "reactions":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable reactions plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "people":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable people plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "sponsorships":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable sponsorships plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "sponsors":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable sponsors plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "repositories":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable repositories plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "discussions":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable discussions plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "starlists":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable starlists plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "calendar":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable calendar plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "achievements":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable achievements plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "notable":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable notable plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "activity":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable activity plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "traffic":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable traffic plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "code":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable code plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "gists":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable gists plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "projects":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable projects plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "introduction":{
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable introduction plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "skyline":{
 | 
				
			||||||
 | 
					      "enabled": false,                 "//": "Enable skyline plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "support":{
 | 
				
			||||||
 | 
					      "enabled": false,                 "//": "Enable support plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "pagespeed":{
 | 
				
			||||||
 | 
					      "token": "PageSpeed token",
 | 
				
			||||||
 | 
					      "enabled": false,                 "//": "Enable pagespeed plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "tweets":{
 | 
				
			||||||
 | 
					      "token": "Twitter API token",
 | 
				
			||||||
 | 
					      "enabled": false,                 "//": "Enable tweets plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "stackoverflow":{
 | 
				
			||||||
 | 
					      "enabled": false,                 "//": "Enable stackoverflow plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "anilist":{
 | 
				
			||||||
 | 
					      "enabled": false,                 "//": "Enable aniList plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "music":{
 | 
				
			||||||
 | 
					      "token": "Music provider token",
 | 
				
			||||||
 | 
					      "enabled": false,                 "//": "Enable music plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "posts":{
 | 
				
			||||||
 | 
					      "enabled": false,                 "//": "Enable posts plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "rss":{
 | 
				
			||||||
 | 
					      "enabled": false,                 "//": "Enable rss plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "wakatime":{
 | 
				
			||||||
 | 
					      "token": "664dd8b2-b73a-4f31-82ef-96ed424814d2",
 | 
				
			||||||
 | 
					      "enabled": true,                 "//": "Enable wakatime plugin"
 | 
				
			||||||
 | 
					      "url": "http://localhost:2001/api",
 | 
				
			||||||
 | 
					      "days": 7,
 | 
				
			||||||
 | 
					      "sections": "time, projects, projects-graphs",
 | 
				
			||||||
 | 
					      "limit": 4,
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "leetcode":{
 | 
				
			||||||
 | 
					      "enabled": false,                 "//": "Enable leetcode plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "steam":{
 | 
				
			||||||
 | 
					      "token": "Steam token",
 | 
				
			||||||
 | 
					      "enabled": false,                 "//": "Enable steam plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "16personalities":{
 | 
				
			||||||
 | 
					      "enabled": false,                 "//": "Enable 16personalities plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "chess":{
 | 
				
			||||||
 | 
					      "token": "Chess platform token",
 | 
				
			||||||
 | 
					      "enabled": false,                 "//": "Enable chess plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "crypto":{
 | 
				
			||||||
 | 
					      "enabled": false,                 "//": "Enable crypto plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "fortune":{
 | 
				
			||||||
 | 
					      "enabled": false,                 "//": "Enable fortune plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "nightscout":{
 | 
				
			||||||
 | 
					      "enabled": false,                 "//": "Enable nightscout plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "poopmap":{
 | 
				
			||||||
 | 
					      "token": "PoopMap API token",
 | 
				
			||||||
 | 
					      "enabled": false,                 "//": "Enable poopmap plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "screenshot":{
 | 
				
			||||||
 | 
					      "enabled": false,                 "//": "Enable screenshot plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "splatoon":{
 | 
				
			||||||
 | 
					      "token": "Splatnet token",
 | 
				
			||||||
 | 
					      "statink.token": null,            "//": "stat.ink token",
 | 
				
			||||||
 | 
					      "enabled": false,                 "//": "Enable splatoon plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "stock":{
 | 
				
			||||||
 | 
					      "token": "Yahoo Finance token",
 | 
				
			||||||
 | 
					      "enabled": false,                 "//": "Enable stock plugin"
 | 
				
			||||||
 | 
					    },
 | 
				
			||||||
 | 
					    "//": ""
 | 
				
			||||||
 | 
					  }
 | 
				
			||||||
 | 
					}
 | 
				
			||||||
							
								
								
									
										8
									
								
								utility/wakaapi/wakaapi.sh
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										8
									
								
								utility/wakaapi/wakaapi.sh
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,8 @@
 | 
				
			|||||||
 | 
					#!/bin/bash
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					docker run -d \
 | 
				
			||||||
 | 
					  -p 2001:3000 \
 | 
				
			||||||
 | 
					  -e "WAKAPI_PASSWORD_SALT=1234" \
 | 
				
			||||||
 | 
					  -v wakapi-data-tsys:/data \
 | 
				
			||||||
 | 
					  --name wakaapi-tsys \
 | 
				
			||||||
 | 
					  ghcr.io/muety/wakapi:latest
 | 
				
			||||||
							
								
								
									
										111
									
								
								webapps/reactive-resume/docker-compose.yml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										111
									
								
								webapps/reactive-resume/docker-compose.yml
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,111 @@
 | 
				
			|||||||
 | 
					version: "3.8"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					# In this Docker Compose example, it assumes that you maintain a reverse proxy externally (or chose not to).
 | 
				
			||||||
 | 
					# The only two exposed ports here are from minio (:9000) and the app itself (:3000).
 | 
				
			||||||
 | 
					# If these ports are changed, ensure that the env vars passed to the app are also changed accordingly.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					services:
 | 
				
			||||||
 | 
					  # Database (Postgres)
 | 
				
			||||||
 | 
					  postgres:
 | 
				
			||||||
 | 
					    image: postgres:16-alpine
 | 
				
			||||||
 | 
					    restart: unless-stopped
 | 
				
			||||||
 | 
					    volumes:
 | 
				
			||||||
 | 
					      - postgres_data:/var/lib/postgresql/data
 | 
				
			||||||
 | 
					    environment:
 | 
				
			||||||
 | 
					      POSTGRES_DB: postgres
 | 
				
			||||||
 | 
					      POSTGRES_USER: postgres
 | 
				
			||||||
 | 
					      POSTGRES_PASSWORD: postgres
 | 
				
			||||||
 | 
					    healthcheck:
 | 
				
			||||||
 | 
					      test: ["CMD-SHELL", "pg_isready -U postgres -d postgres"]
 | 
				
			||||||
 | 
					      interval: 10s
 | 
				
			||||||
 | 
					      timeout: 5s
 | 
				
			||||||
 | 
					      retries: 5
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  # Storage (for image uploads)
 | 
				
			||||||
 | 
					  minio:
 | 
				
			||||||
 | 
					    image: minio/minio
 | 
				
			||||||
 | 
					    restart: unless-stopped
 | 
				
			||||||
 | 
					    command: server /data
 | 
				
			||||||
 | 
					    ports:
 | 
				
			||||||
 | 
					      - "9000:9000"
 | 
				
			||||||
 | 
					    volumes:
 | 
				
			||||||
 | 
					      - minio_data:/data
 | 
				
			||||||
 | 
					    environment:
 | 
				
			||||||
 | 
					      MINIO_ROOT_USER: minioadmin
 | 
				
			||||||
 | 
					      MINIO_ROOT_PASSWORD: minioadmin
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  # Chrome Browser (for printing and previews)
 | 
				
			||||||
 | 
					  chrome:
 | 
				
			||||||
 | 
					    image: ghcr.io/browserless/chromium:latest
 | 
				
			||||||
 | 
					    restart: unless-stopped
 | 
				
			||||||
 | 
					    environment:
 | 
				
			||||||
 | 
					      TIMEOUT: 10000
 | 
				
			||||||
 | 
					      CONCURRENT: 10
 | 
				
			||||||
 | 
					      TOKEN: chrome_token
 | 
				
			||||||
 | 
					      EXIT_ON_HEALTH_FAILURE: true
 | 
				
			||||||
 | 
					      PRE_REQUEST_HEALTH_CHECK: true
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					  app:
 | 
				
			||||||
 | 
					    image: amruthpillai/reactive-resume:latest
 | 
				
			||||||
 | 
					    restart: unless-stopped
 | 
				
			||||||
 | 
					    ports:
 | 
				
			||||||
 | 
					      - "3000:3000"
 | 
				
			||||||
 | 
					    depends_on:
 | 
				
			||||||
 | 
					      - postgres
 | 
				
			||||||
 | 
					      - minio
 | 
				
			||||||
 | 
					      - chrome
 | 
				
			||||||
 | 
					    environment:
 | 
				
			||||||
 | 
					      # -- Environment Variables --
 | 
				
			||||||
 | 
					      PORT: 3000
 | 
				
			||||||
 | 
					      NODE_ENV: production
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					      # -- URLs --
 | 
				
			||||||
 | 
					      PUBLIC_URL: http://localhost:3000
 | 
				
			||||||
 | 
					      STORAGE_URL: http://localhost:9000/default
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					      # -- Printer (Chrome) --
 | 
				
			||||||
 | 
					      CHROME_TOKEN: chrome_token
 | 
				
			||||||
 | 
					      CHROME_URL: ws://chrome:3000
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					      # -- Database (Postgres) --
 | 
				
			||||||
 | 
					      DATABASE_URL: postgresql://postgres:postgres@postgres:5432/postgres
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					      # -- Auth --
 | 
				
			||||||
 | 
					      ACCESS_TOKEN_SECRET: access_token_secret
 | 
				
			||||||
 | 
					      REFRESH_TOKEN_SECRET: refresh_token_secret
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					      # -- Emails --
 | 
				
			||||||
 | 
					      MAIL_FROM: noreply@localhost
 | 
				
			||||||
 | 
					      # SMTP_URL: smtp://user:pass@smtp:587 # Optional
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					      # -- Storage (Minio) --
 | 
				
			||||||
 | 
					      STORAGE_ENDPOINT: minio
 | 
				
			||||||
 | 
					      STORAGE_PORT: 9000
 | 
				
			||||||
 | 
					      STORAGE_REGION: us-east-1 # Optional
 | 
				
			||||||
 | 
					      STORAGE_BUCKET: default
 | 
				
			||||||
 | 
					      STORAGE_ACCESS_KEY: minioadmin
 | 
				
			||||||
 | 
					      STORAGE_SECRET_KEY: minioadmin
 | 
				
			||||||
 | 
					      STORAGE_USE_SSL: false
 | 
				
			||||||
 | 
					      STORAGE_SKIP_BUCKET_CHECK: false
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					      # -- Crowdin (Optional) --
 | 
				
			||||||
 | 
					      # CROWDIN_PROJECT_ID:
 | 
				
			||||||
 | 
					      # CROWDIN_PERSONAL_TOKEN:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					      # -- Email (Optional) --
 | 
				
			||||||
 | 
					      # DISABLE_SIGNUPS: false
 | 
				
			||||||
 | 
					      # DISABLE_EMAIL_AUTH: false
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					      # -- GitHub (Optional) --
 | 
				
			||||||
 | 
					      # GITHUB_CLIENT_ID: github_client_id
 | 
				
			||||||
 | 
					      # GITHUB_CLIENT_SECRET: github_client_secret
 | 
				
			||||||
 | 
					      # GITHUB_CALLBACK_URL: http://localhost:3000/api/auth/github/callback
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					      # -- Google (Optional) --
 | 
				
			||||||
 | 
					      # GOOGLE_CLIENT_ID: google_client_id
 | 
				
			||||||
 | 
					      # GOOGLE_CLIENT_SECRET: google_client_secret
 | 
				
			||||||
 | 
					      # GOOGLE_CALLBACK_URL: http://localhost:3000/api/auth/google/callback
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					volumes:
 | 
				
			||||||
 | 
					  minio_data:
 | 
				
			||||||
 | 
					  postgres_data:
 | 
				
			||||||
							
								
								
									
										65
									
								
								webapps/tube-archivist/docker-compose.yml
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										65
									
								
								webapps/tube-archivist/docker-compose.yml
									
									
									
									
									
										Normal file
									
								
							@@ -0,0 +1,65 @@
 | 
				
			|||||||
 | 
					version: '3.5'
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					services:
 | 
				
			||||||
 | 
					  tubearchivist:
 | 
				
			||||||
 | 
					    container_name: tubearchivist
 | 
				
			||||||
 | 
					    restart: unless-stopped
 | 
				
			||||||
 | 
					    image: bbilly1/tubearchivist
 | 
				
			||||||
 | 
					    ports:
 | 
				
			||||||
 | 
					      - 8000:8000
 | 
				
			||||||
 | 
					    volumes:
 | 
				
			||||||
 | 
					      - media:/youtube
 | 
				
			||||||
 | 
					      - cache:/cache
 | 
				
			||||||
 | 
					    environment:
 | 
				
			||||||
 | 
					      - ES_URL=http://archivist-es:9200     # needs protocol e.g. http and port
 | 
				
			||||||
 | 
					      - REDIS_HOST=archivist-redis          # don't add protocol
 | 
				
			||||||
 | 
					      - HOST_UID=1000
 | 
				
			||||||
 | 
					      - HOST_GID=1000
 | 
				
			||||||
 | 
					      - TA_HOST=tubearchivist.local         # set your host name
 | 
				
			||||||
 | 
					      - TA_USERNAME=tubearchivist           # your initial TA credentials
 | 
				
			||||||
 | 
					      - TA_PASSWORD=verysecret              # your initial TA credentials
 | 
				
			||||||
 | 
					      - ELASTIC_PASSWORD=verysecret         # set password for Elasticsearch
 | 
				
			||||||
 | 
					      - TZ=America/New_York                 # set your time zone
 | 
				
			||||||
 | 
					    healthcheck:
 | 
				
			||||||
 | 
					      test: ["CMD", "curl", "-f", "http://localhost:8000/health"]
 | 
				
			||||||
 | 
					      interval: 2m
 | 
				
			||||||
 | 
					      timeout: 10s
 | 
				
			||||||
 | 
					      retries: 3
 | 
				
			||||||
 | 
					      start_period: 30s
 | 
				
			||||||
 | 
					    depends_on:
 | 
				
			||||||
 | 
					      - archivist-es
 | 
				
			||||||
 | 
					      - archivist-redis
 | 
				
			||||||
 | 
					  archivist-redis:
 | 
				
			||||||
 | 
					    image: redis/redis-stack-server
 | 
				
			||||||
 | 
					    container_name: archivist-redis
 | 
				
			||||||
 | 
					    restart: unless-stopped
 | 
				
			||||||
 | 
					    expose:
 | 
				
			||||||
 | 
					      - "6379"
 | 
				
			||||||
 | 
					    volumes:
 | 
				
			||||||
 | 
					      - redis:/data
 | 
				
			||||||
 | 
					    depends_on:
 | 
				
			||||||
 | 
					      - archivist-es
 | 
				
			||||||
 | 
					  archivist-es:
 | 
				
			||||||
 | 
					    image: bbilly1/tubearchivist-es         # only for amd64, or use official es 8.14.3
 | 
				
			||||||
 | 
					    container_name: archivist-es
 | 
				
			||||||
 | 
					    restart: unless-stopped
 | 
				
			||||||
 | 
					    environment:
 | 
				
			||||||
 | 
					      - "ELASTIC_PASSWORD=verysecret"       # matching Elasticsearch password
 | 
				
			||||||
 | 
					      - "ES_JAVA_OPTS=-Xms1g -Xmx1g"
 | 
				
			||||||
 | 
					      - "xpack.security.enabled=true"
 | 
				
			||||||
 | 
					      - "discovery.type=single-node"
 | 
				
			||||||
 | 
					      - "path.repo=/usr/share/elasticsearch/data/snapshot"
 | 
				
			||||||
 | 
					    ulimits:
 | 
				
			||||||
 | 
					      memlock:
 | 
				
			||||||
 | 
					        soft: -1
 | 
				
			||||||
 | 
					        hard: -1
 | 
				
			||||||
 | 
					    volumes:
 | 
				
			||||||
 | 
					      - es:/usr/share/elasticsearch/data    # check for permission error when using bind mount, see readme
 | 
				
			||||||
 | 
					    expose:
 | 
				
			||||||
 | 
					      - "9200"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					volumes:
 | 
				
			||||||
 | 
					  media:
 | 
				
			||||||
 | 
					  cache:
 | 
				
			||||||
 | 
					  redis:
 | 
				
			||||||
 | 
					  es:
 | 
				
			||||||
		Reference in New Issue
	
	Block a user