diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 479c957..5e782e4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -36,7 +36,8 @@ jobs: run: | python3 -m ensurepip python3 -m venv /opt/certbot/ - pip3 install aiogram tomli certbot + python3 -m pip install --upgrade pip + pip3 install aiogram pandas apscheduler tomli certbot py-postgresql beautifulsoup4 lxml # - name: Install some html stuff # run: | diff --git a/.gitignore b/.gitignore index 50744f1..b9d88fd 100644 --- a/.gitignore +++ b/.gitignore @@ -1,6 +1,8 @@ token *.pem *.toml +*.log +*.log.* # Byte-compiled / optimized / DLL files __pycache__/ @@ -60,7 +62,7 @@ cover/ *.pot # Django stuff: -*.log + local_settings.py db.sqlite3 db.sqlite3-journal diff --git a/db/init.sh b/db/init.sh index 6f37319..7762858 100755 --- a/db/init.sh +++ b/db/init.sh @@ -4,7 +4,17 @@ db_name=$1 db_user=$2 db_pass=$3 -psql -U postgres -c "DROP DATABASE ${db_name};" -psql -U postgres -c "DROP USER ${db_user};" -psql -U postgres -c "CREATE USER ${db_user} PASSWORD '${db_pass}';" -psql -U postgres -c "CREATE DATABASE ${db_name} OWNER=${db_user};" \ No newline at end of file +# psql -U postgres -c "DROP DATABASE ${db_name};" +# psql -U postgres -c "DROP USER ${db_user};" + +psql -U postgres ${db_pass} << EOF +CREATE USER ${db_user} PASSWORD '${db_pass}'; +CREATE DATABASE ${db_name} OWNER=${db_user}; +\c ${db_name}; + + +CREATE TABLE IF NOT EXISTS options ( + id SERIAL, + name VARCHAR(100), + value text); +EOF diff --git a/html/index.html b/html/index.html index b050fd5..c9e9d3b 100644 --- a/html/index.html +++ b/html/index.html @@ -6,76 +6,136 @@