Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Version 5.0.0 #524

Draft
wants to merge 23 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from 12 commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/main.workflow
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ action "test image" {
action "compose" {
needs = ["test image"]
uses = "docker://python:3.8"
runs = ["/bin/sh", "-c", "pip install docker-compose; docker-compose up"]
runs = ["/bin/sh", "-c", "pip install docker-compose; docker-compose -f docker-compose.yml up"]
env = {PIP_DISABLE_PIP_VERSION_CHECK="1"}
}

Expand Down
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,12 @@ The internet.nl dashboard allows you to visualize batch scans from the internet.
- Second factor authentication
- Seamless internet.nl API integration

## Setup / installation

Read the installation tutorial here:
https://github.com/internetstandards/Internet.nl-dashboard/blob/main/docs/render/markdown/Installation.md


## Screenshots

Some screenshots can be found at: https://dashboard.internet.nl/#/tour
Expand Down
124 changes: 124 additions & 0 deletions compose.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,124 @@
services:
backend:
image: ${DOCKER_IMAGE_DASHBOARD:-${DOCKER_REGISTRY:-internetstandards}/dashboard:${RELEASE:-latest}}
build: .
command: dashboard_prdserver --migrate
# TODO: check if needed: --security-opt seccomp=unconfined
environment:
SECRET_KEY_FILE: /etc/django_keys/secret_key
FIELD_ENCRYPTION_KEY_FILE: /etc/django_keys/field_encryption_key
ALLOWED_HOSTS: "*"
UWSGI_HARAKIRI: 3600
DJANGO_DATABASE: production
DB_ENGINE: postgresql_psycopg2
DB_HOST: database
WORKER_ROLE: default
BROKER: redis://broker:6379/0
SENTRY_DSN:
DASHBOARD_FRONTEND_URL:
networks:
dashboard:
volumes:
- dashboard-frontend-uploads:/source/dashboard/uploads
- django-keys:/etc/django_keys/
healthcheck:
interval: 60s

frontend:
image: ${DOCKER_IMAGE_DASHBOARD_STATIC:-${DOCKER_REGISTRY:-internetstandards}/dashboard-static:${RELEASE:-latest}}
build: https://github.com/internetstandards/Internet.nl-dashboard-frontend.git
networks:
dashboard:
healthcheck:
interval: 60s
volumes:
- dashboard-frontend-uploads:/source/dashboard/uploads

worker: &worker
image: ${DOCKER_IMAGE_DASHBOARD:-${DOCKER_REGISTRY:-internetstandards}/dashboard:${RELEASE:-latest}}
build: .
command: celery_dashboard worker --queues storage,celery,isolated,kickoff,kickoff1,kickoff2,kickoff3,kickoff4,database_deprecate,database_deprecate3,database,database3
environment: &worker-environment
SECRET_KEY_FILE: /etc/django_keys/secret_key
FIELD_ENCRYPTION_KEY_FILE: /etc/django_keys/field_encryption_key
DJANGO_DATABASE: production
DB_ENGINE: postgresql_psycopg2
DB_HOST: database
WORKER_ROLE: default_ipv4
BROKER: redis://broker:6379/0
SENTRY_DSN:
networks:
dashboard:
healthcheck:
interval: 60s
volumes:
- django-keys:/etc/django_keys/
- dashboard-frontend-uploads:/source/dashboard/uploads

worker-reporting:
<<: *worker
command: celery_dashboard worker --queues reporting
environment:
<<: *worker-environment
WORKER_ROLE: reporting

worker-scanning:
<<: *worker
command: celery_dashboard worker --queues ipv4,internet
environment:
<<: *worker-environment
WORKER_ROLE: default_ipv4

scheduler:
<<: *worker
image: ${DOCKER_IMAGE_DASHBOARD:-${DOCKER_REGISTRY:-internetstandards}/dashboard:${RELEASE:-latest}}
build: .
command: celery_dashboard beat -l info --pidfile=/var/tmp/celerybeat.pid

webserver:
image: caddy
configs:
- source: caddyfile
target: /etc/caddy/Caddyfile
ports:
- 127.0.0.1:8000:8000
networks:
dashboard:

database:
image: postgres:12
environment:
POSTGRES_DB: dashboard
POSTGRES_USER: dashboard
POSTGRES_PASSWORD: dashboard
networks:
dashboard:
volumes:
- database:/var/lib/postgresql/data
healthcheck:
interval: 60s
stop_grace_period: 60s

broker:
image: redis
healthcheck:
interval: 60s
networks:
dashboard:

configs:
caddyfile:
content: |
:8000 {
@paths path /account/* /admin/* /data/* /jet/* /logout/* /mail/* /session/* /static/* /upload/* /security.txt /.well-known/security.txt
reverse_proxy @paths backend:8000
reverse_proxy /* frontend:80
}

volumes:
dashboard-frontend-uploads:
database:
django-keys:

networks:
dashboard:
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
[
{
"model": "internet_nl_dashboard.account",
"pk": 1,
"fields": {
"name": "default_account",
"enable_scans": true,
"internet_nl_api_username": "internetnl",
"internet_nl_api_password": "b'gAAAAABmh-l8zisrtWyjMDkkDmQBEQzpLY17FIrN81NBgMq-DacASKVVb4ZjiDvjFIgerTtYD38Y-fvq9irDfnT1vbuh4Qa_dg=='",
"can_connect_to_internet_nl_api": false,
"report_settings": null
}
}
]
Loading
Loading