Add Docker (#77)

This commit is contained in:
samukhin 2021-05-14 19:06:35 +03:00 committed by GitHub
parent 3f6674eff9
commit c2afd7f1f2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
12 changed files with 481 additions and 100 deletions

82
Dockerfile Normal file
View file

@ -0,0 +1,82 @@
FROM fedora:33
#update and install httpd
RUN dnf -y update && dnf -y autoremove && dnf install -y httpd
#Let's install Remi repos for PHP 7.4:
RUN dnf -y install https://rpms.remirepo.net/fedora/remi-release-$(rpm -E %fedora).rpm
#Then enable modules that we need:
RUN dnf -y module enable php:remi-7.4 && \
dnf -y module enable nodejs:14
#And install dependencies:
RUN dnf -y install php php-cli php-common unzip php-zip php-yaml php-gd php-pdo_mysql nodejs git
#Don't forget about Yarn and Composer:
RUN npm i -g yarn && \
php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" && \
php composer-setup.php --filename=composer2 --install-dir=/bin --snapshot && \
rm composer-setup.php
#We will use Mariadb for DB:
RUN dnf -y install mysql mysql-server && \
systemctl enable mariadb && \
echo 'skip-grant-tables' >> /etc/my.cnf
#Additionally, you can install ffmpeg for processing videos.
#You will need to use RPMFusion repo to install it:
RUN dnf -y install --nogpgcheck https://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm && \
dnf -y install --nogpgcheck https://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm
#Then install SDL2 and ffmpeg:
RUN dnf -y install --nogpgcheck SDL2 ffmpeg
#Install Chandler and OpenVk/Capcha-extention in /opt:
RUN cd /opt && \
git clone https://github.com/samukhin/chandler.git && \
cd chandler/ && \
composer2 install && \
mv chandler-example.yml chandler.yml && \
cd extensions/available/ && \
git clone https://github.com/samukhin/commitcaptcha.git && \
cd commitcaptcha/ && \
composer2 install && \
cd .. && \
git clone https://github.com/samukhin/openvk.git && \
cd openvk/ && \
composer2 install && \
cd Web/static/js && \
yarn install && \
cd ../../../ && \
mv openvk-example.yml openvk.yml && \
ln -s /opt/chandler/extensions/available/commitcaptcha/ /opt/chandler/extensions/enabled/commitcaptcha && \
ln -s /opt/chandler/extensions/available/openvk/ /opt/chandler/extensions/enabled/openvk
#Create database
RUN cp /opt/chandler/extensions/available/openvk/install/automated/common/create_db.service /etc/systemd/system/ && \
chmod 644 /etc/systemd/system/create_db.service && \
chmod 777 /opt/chandler/extensions/available/openvk/install/automated/common/autoexec && \
systemctl enable create_db
#Make the user apache owner of the chandler folder:
RUN cd /opt && \
chown -R apache: chandler/
#Now let's create config file /etc/httpd/conf.d/10-openvk.conf and
#Also enable rewrite_module by creating /etc/httpd/conf.modules.d/02-rewrite.conf
RUN cp /opt/chandler/extensions/available/openvk/install/automated/common/10-openvk.conf /etc/httpd/conf.d/ && \
cp /opt/chandler/extensions/available/openvk/install/automated/common/02-rewrite.conf /etc/httpd/conf.modules.d/
#Make directory for OpenVK logs and make the user apache owner of it:
RUN mkdir /var/log/openvk && \
chown apache: /var/log/openvk/
#And start Apache:
#RUN systemctl enable httpd
#For login
RUN dnf -y install passwd && passwd -d root
#Start systemd
CMD ["/sbin/init"]

View file

@ -20,7 +20,7 @@ final class NotesPresenter extends OpenVKPresenter
$user = (new Users)->get($owner); $user = (new Users)->get($owner);
if(!$user) $this->notFound(); if(!$user) $this->notFound();
$this->template->notes = $this->notes->getUserNotes($user, $this->queryParam("p") ?? 1); $this->template->notes = $this->notes->getUserNotes($user, (int)($this->queryParam("p") ?? 1));
$this->template->count = $this->notes->getUserNotesCount($user); $this->template->count = $this->notes->getUserNotesCount($user);
$this->template->owner = $user; $this->template->owner = $user;
$this->template->paginatorConf = (object) [ $this->template->paginatorConf = (object) [

View file

@ -0,0 +1,85 @@
#From https://gist.github.com/WerySkok/77f9c9ec134e98b0fef2b63655ba13d2 instruction
FROM almalinux/almalinux:8
#update and install httpd
RUN dnf -y update && dnf -y autoremove && dnf install -y httpd
#Let's install EPEL and Remi repos for PHP 7.4:
RUN dnf -y install epel-release && \
dnf -y install https://rpms.remirepo.net/enterprise/remi-release-8.rpm
#Then enable modules that we need:
RUN dnf -y module enable php:remi-7.4 && \
dnf -y module enable nodejs:14
#And install dependencies:
RUN dnf -y install php php-cli php-common unzip php-zip php-yaml php-gd php-pdo_mysql nodejs git
#Don't forget about Yarn and Composer:
RUN npm i -g yarn && \
php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" && \
php composer-setup.php --filename=composer2 --install-dir=/bin --snapshot && \
rm composer-setup.php
#We will use Percona Server for DB:
RUN dnf -y install https://repo.percona.com/yum/percona-release-latest.noarch.rpm && \
percona-release setup -y ps80 && \
dnf -y install percona-server-server percona-toolkit && \
systemctl enable mysqld && \
echo 'skip-grant-tables' >> /etc/my.cnf
#Additionally, you can install ffmpeg for processing videos.
#You will need to use RPMFusion repo to install it:
RUN dnf -y localinstall --nogpgcheck https://download1.rpmfusion.org/free/el/rpmfusion-free-release-8.noarch.rpm && \
dnf -y install --nogpgcheck https://download1.rpmfusion.org/free/el/rpmfusion-free-release-8.noarch.rpm
#Then install SDL2 and ffmpeg:
RUN dnf -y localinstall --nogpgcheck https://pkgs.dyn.su/el8/base/x86_64/raven-release-1.0-2.el8.noarch.rpm && \
dnf -y --enablerepo=epel-testing,raven-extras,raven-multimedia install --nogpgcheck SDL2 && \
dnf -y install ffmpeg
#Install Chandler and OpenVk/Capcha-extention in /opt:
RUN cd /opt && \
git clone https://github.com/samukhin/chandler.git && \
cd chandler/ && \
composer2 install && \
mv chandler-example.yml chandler.yml && \
cd extensions/available/ && \
git clone https://github.com/samukhin/commitcaptcha.git && \
cd commitcaptcha/ && \
composer2 install && \
cd .. && \
git clone https://github.com/samukhin/openvk.git && \
cd openvk/ && \
composer2 install && \
cd Web/static/js && \
yarn install && \
cd ../../../ && \
mv openvk-example.yml openvk.yml && \
ln -s /opt/chandler/extensions/available/commitcaptcha/ /opt/chandler/extensions/enabled/commitcaptcha && \
ln -s /opt/chandler/extensions/available/openvk/ /opt/chandler/extensions/enabled/openvk
#Create database
RUN cp /opt/chandler/extensions/available/openvk/install/automated/common/create_db.service /etc/systemd/system/ && \
chmod 644 /etc/systemd/system/create_db.service && \
chmod 777 /opt/chandler/extensions/available/openvk/install/automated/common/autoexec && \
systemctl enable create_db
#Make the user apache owner of the chandler folder:
RUN cd /opt && \
chown -R apache: chandler/
#Now let's create config file /etc/httpd/conf.d/10-openvk.conf and
#Also enable rewrite_module by creating /etc/httpd/conf.modules.d/02-rewrite.conf
RUN cp /opt/chandler/extensions/available/openvk/install/automated/common/10-openvk.conf /etc/httpd/conf.d/ && \
cp /opt/chandler/extensions/available/openvk/install/automated/common/02-rewrite.conf /etc/httpd/conf.modules.d/
#Make directory for OpenVK logs and make the user apache owner of it:
RUN mkdir /var/log/openvk && \
chown apache: /var/log/openvk/
#And start Apache:
#RUN systemctl enable httpd
#Start systemd
CMD ["/sbin/init"]

View file

@ -0,0 +1,85 @@
#From https://gist.github.com/WerySkok/77f9c9ec134e98b0fef2b63655ba13d2 instruction
FROM centos:8
#update and install httpd
RUN dnf -y update && dnf -y autoremove && dnf install -y httpd
#Let's install EPEL and Remi repos for PHP 7.4:
RUN dnf -y install epel-release && \
dnf -y install https://rpms.remirepo.net/enterprise/remi-release-8.rpm
#Then enable modules that we need:
RUN dnf -y module enable php:remi-7.4 && \
dnf -y module enable nodejs:14
#And install dependencies:
RUN dnf -y install php php-cli php-common unzip php-zip php-yaml php-gd php-pdo_mysql nodejs git
#Don't forget about Yarn and Composer:
RUN npm i -g yarn && \
php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" && \
php composer-setup.php --filename=composer2 --install-dir=/bin --snapshot && \
rm composer-setup.php
#We will use Percona Server for DB:
RUN dnf -y install https://repo.percona.com/yum/percona-release-latest.noarch.rpm && \
percona-release setup -y ps80 && \
dnf -y install percona-server-server percona-toolkit && \
systemctl enable mysqld && \
echo 'skip-grant-tables' >> /etc/my.cnf
#Additionally, you can install ffmpeg for processing videos.
#You will need to use RPMFusion repo to install it:
RUN dnf -y localinstall --nogpgcheck https://download1.rpmfusion.org/free/el/rpmfusion-free-release-8.noarch.rpm && \
dnf -y install --nogpgcheck https://download1.rpmfusion.org/free/el/rpmfusion-free-release-8.noarch.rpm
#Then install SDL2 and ffmpeg:
RUN dnf -y localinstall --nogpgcheck https://pkgs.dyn.su/el8/base/x86_64/raven-release-1.0-2.el8.noarch.rpm && \
dnf -y --enablerepo=epel-testing,raven-extras,raven-multimedia install --nogpgcheck SDL2 && \
dnf -y install ffmpeg
#Install Chandler and OpenVk/Capcha-extention in /opt:
RUN cd /opt && \
git clone https://github.com/samukhin/chandler.git && \
cd chandler/ && \
composer2 install && \
mv chandler-example.yml chandler.yml && \
cd extensions/available/ && \
git clone https://github.com/samukhin/commitcaptcha.git && \
cd commitcaptcha/ && \
composer2 install && \
cd .. && \
git clone https://github.com/samukhin/openvk.git && \
cd openvk/ && \
composer2 install && \
cd Web/static/js && \
yarn install && \
cd ../../../ && \
mv openvk-example.yml openvk.yml && \
ln -s /opt/chandler/extensions/available/commitcaptcha/ /opt/chandler/extensions/enabled/commitcaptcha && \
ln -s /opt/chandler/extensions/available/openvk/ /opt/chandler/extensions/enabled/openvk
#Create database
RUN cp /opt/chandler/extensions/available/openvk/install/automated/common/create_db.service /etc/systemd/system/ && \
chmod 644 /etc/systemd/system/create_db.service && \
chmod 777 /opt/chandler/extensions/available/openvk/install/automated/common/autoexec && \
systemctl enable create_db
#Make the user apache owner of the chandler folder:
RUN cd /opt && \
chown -R apache: chandler/
#Now let's create config file /etc/httpd/conf.d/10-openvk.conf and
#Also enable rewrite_module by creating /etc/httpd/conf.modules.d/02-rewrite.conf
RUN cp /opt/chandler/extensions/available/openvk/install/automated/common/10-openvk.conf /etc/httpd/conf.d/ && \
cp /opt/chandler/extensions/available/openvk/install/automated/common/02-rewrite.conf /etc/httpd/conf.modules.d/
#Make directory for OpenVK logs and make the user apache owner of it:
RUN mkdir /var/log/openvk && \
chown apache: /var/log/openvk/
#And start Apache:
#RUN systemctl enable httpd
#Start systemd
CMD ["/sbin/init"]

View file

@ -0,0 +1,83 @@
#From https://gist.github.com/WerySkok/77f9c9ec134e98b0fef2b63655ba13d2 instruction
FROM fedora:33
#update and install httpd
RUN dnf -y update && dnf -y autoremove && dnf install -y httpd
#Let's install Remi repos for PHP 7.4:
RUN dnf -y install https://rpms.remirepo.net/fedora/remi-release-$(rpm -E %fedora).rpm
#Then enable modules that we need:
RUN dnf -y module enable php:remi-7.4 && \
dnf -y module enable nodejs:14
#And install dependencies:
RUN dnf -y install php php-cli php-common unzip php-zip php-yaml php-gd php-pdo_mysql nodejs git
#Don't forget about Yarn and Composer:
RUN npm i -g yarn && \
php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" && \
php composer-setup.php --filename=composer2 --install-dir=/bin --snapshot && \
rm composer-setup.php
#We will use Mariadb for DB:
RUN dnf -y install mysql mysql-server && \
systemctl enable mariadb && \
echo 'skip-grant-tables' >> /etc/my.cnf
#Additionally, you can install ffmpeg for processing videos.
#You will need to use RPMFusion repo to install it:
RUN dnf -y install --nogpgcheck https://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm && \
dnf -y install --nogpgcheck https://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm
#Then install SDL2 and ffmpeg:
RUN dnf -y install --nogpgcheck SDL2 ffmpeg
#Install Chandler and OpenVk/Capcha-extention in /opt:
RUN cd /opt && \
git clone https://github.com/samukhin/chandler.git && \
cd chandler/ && \
composer2 install && \
mv chandler-example.yml chandler.yml && \
cd extensions/available/ && \
git clone https://github.com/samukhin/commitcaptcha.git && \
cd commitcaptcha/ && \
composer2 install && \
cd .. && \
git clone https://github.com/samukhin/openvk.git && \
cd openvk/ && \
composer2 install && \
cd Web/static/js && \
yarn install && \
cd ../../../ && \
mv openvk-example.yml openvk.yml && \
ln -s /opt/chandler/extensions/available/commitcaptcha/ /opt/chandler/extensions/enabled/commitcaptcha && \
ln -s /opt/chandler/extensions/available/openvk/ /opt/chandler/extensions/enabled/openvk
#Create database
RUN cp /opt/chandler/extensions/available/openvk/install/automated/common/create_db.service /etc/systemd/system/ && \
chmod 644 /etc/systemd/system/create_db.service && \
chmod 777 /opt/chandler/extensions/available/openvk/install/automated/common/autoexec && \
systemctl enable create_db
#Make the user apache owner of the chandler folder:
RUN cd /opt && \
chown -R apache: chandler/
#Now let's create config file /etc/httpd/conf.d/10-openvk.conf and
#Also enable rewrite_module by creating /etc/httpd/conf.modules.d/02-rewrite.conf
RUN cp /opt/chandler/extensions/available/openvk/install/automated/common/10-openvk.conf /etc/httpd/conf.d/ && \
cp /opt/chandler/extensions/available/openvk/install/automated/common/02-rewrite.conf /etc/httpd/conf.modules.d/
#Make directory for OpenVK logs and make the user apache owner of it:
RUN mkdir /var/log/openvk && \
chown apache: /var/log/openvk/
#And start Apache:
#RUN systemctl enable httpd
#For login
RUN dnf -y install passwd && passwd -d root
#Start systemd
CMD ["/sbin/init"]

View file

@ -0,0 +1 @@

View file

@ -0,0 +1 @@
LoadModule rewrite_module modules/mod_rewrite.so

View file

@ -0,0 +1,13 @@
<VirtualHost *:80>
ServerName openvk.local
DocumentRoot /opt/chandler/htdocs
<Directory /opt/chandler/htdocs>
AllowOverride All
Require all granted
</Directory>
ErrorLog /var/log/openvk/error.log
CustomLog /var/log/openvk/access.log combinedio
</VirtualHost>

View file

@ -0,0 +1,8 @@
cd /opt/chandler && \
mysql -p'DATABASE_PASSWORD' -e "CREATE DATABASE openvk" && \
mysql -p'DATABASE_PASSWORD' -e "CREATE DATABASE openvk_eventdb" && \
mysql -p'DATABASE_PASSWORD' openvk < install/init-db.sql && \
cd extensions/available/openvk/ && \
mysql -p'DATABASE_PASSWORD' openvk < install/init-static-db.sql && \
mysql -p'DATABASE_PASSWORD' openvk_eventdb < install/init-event-db.sql && \
systemctl enable --now httpd

View file

@ -0,0 +1,10 @@
[Unit]
Description=Create MySQL DB
After=mysql.service
[Service]
Type=exec
ExecStart=/bin/bash /opt/chandler/extensions/available/openvk/install/automated/common/autoexec
[Install]
WantedBy=multi-user.target

View file

@ -11,32 +11,32 @@ START TRANSACTION;
CREATE TABLE `albums` ( CREATE TABLE `albums` (
`id` bigint(20) UNSIGNED NOT NULL, `id` bigint(20) UNSIGNED NOT NULL,
`owner` bigint(20) NOT NULL, `owner` bigint(20) NOT NULL,
`name` varchar(36) COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `name` varchar(36) COLLATE utf8mb4_unicode_520_ci NOT NULL,
`description` longtext COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `description` longtext COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`access_pragma` tinyint(3) UNSIGNED NOT NULL DEFAULT 255, `access_pragma` tinyint(3) UNSIGNED NOT NULL DEFAULT 255,
`cover_photo` bigint(20) UNSIGNED DEFAULT NULL, `cover_photo` bigint(20) UNSIGNED DEFAULT NULL,
`special_type` tinyint(3) UNSIGNED NOT NULL DEFAULT 0, `special_type` tinyint(3) UNSIGNED NOT NULL DEFAULT 0,
`created` bigint(20) UNSIGNED NOT NULL, `created` bigint(20) UNSIGNED NOT NULL,
`edited` bigint(20) UNSIGNED DEFAULT NULL, `edited` bigint(20) UNSIGNED DEFAULT NULL,
`deleted` tinyint(1) NOT NULL DEFAULT 0 `deleted` tinyint(1) NOT NULL DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `album_relations` ( CREATE TABLE `album_relations` (
`collection` bigint(20) UNSIGNED NOT NULL, `collection` bigint(20) UNSIGNED NOT NULL,
`media` bigint(20) UNSIGNED NOT NULL, `media` bigint(20) UNSIGNED NOT NULL,
`index` bigint(20) UNSIGNED NOT NULL `index` bigint(20) UNSIGNED NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `api_tokens` ( CREATE TABLE `api_tokens` (
`id` bigint(20) UNSIGNED NOT NULL, `id` bigint(20) UNSIGNED NOT NULL,
`user` bigint(20) NOT NULL, `user` bigint(20) NOT NULL,
`secret` char(72) COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `secret` char(72) COLLATE utf8mb4_unicode_520_ci NOT NULL,
`deleted` bit(1) NOT NULL DEFAULT b'0' `deleted` bit(1) NOT NULL DEFAULT b'0'
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `approval_queue` ( CREATE TABLE `approval_queue` (
`id` bigint(20) UNSIGNED NOT NULL, `id` bigint(20) UNSIGNED NOT NULL,
`model` varchar(128) COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `model` varchar(128) COLLATE utf8mb4_unicode_520_ci NOT NULL,
`target` bigint(20) NOT NULL, `target` bigint(20) NOT NULL,
`author` bigint(20) UNSIGNED NOT NULL, `author` bigint(20) UNSIGNED NOT NULL,
`assignee` bigint(20) UNSIGNED DEFAULT NULL, `assignee` bigint(20) UNSIGNED DEFAULT NULL,
@ -44,15 +44,15 @@ CREATE TABLE `approval_queue` (
`created` bigint(20) UNSIGNED NOT NULL, `created` bigint(20) UNSIGNED NOT NULL,
`updated` bigint(20) UNSIGNED NOT NULL, `updated` bigint(20) UNSIGNED NOT NULL,
`deleted` tinyint(1) NOT NULL DEFAULT 0 `deleted` tinyint(1) NOT NULL DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `attachments` ( CREATE TABLE `attachments` (
`attachable_type` varchar(64) COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `attachable_type` varchar(64) COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`attachable_id` bigint(20) UNSIGNED DEFAULT NULL, `attachable_id` bigint(20) UNSIGNED DEFAULT NULL,
`target_type` varchar(64) COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `target_type` varchar(64) COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`target_id` bigint(20) UNSIGNED DEFAULT NULL, `target_id` bigint(20) UNSIGNED DEFAULT NULL,
`index` bigint(20) UNSIGNED NOT NULL `index` bigint(20) UNSIGNED NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `audios` ( CREATE TABLE `audios` (
`id` bigint(20) UNSIGNED NOT NULL, `id` bigint(20) UNSIGNED NOT NULL,
@ -60,34 +60,34 @@ CREATE TABLE `audios` (
`virtual_id` bigint(20) UNSIGNED NOT NULL, `virtual_id` bigint(20) UNSIGNED NOT NULL,
`created` bigint(20) UNSIGNED NOT NULL, `created` bigint(20) UNSIGNED NOT NULL,
`edited` bigint(20) UNSIGNED DEFAULT NULL, `edited` bigint(20) UNSIGNED DEFAULT NULL,
`hash` char(128) COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `hash` char(128) COLLATE utf8mb4_unicode_520_ci NOT NULL,
`deleted` tinyint(4) DEFAULT 0, `deleted` tinyint(4) DEFAULT 0,
`name` varchar(190) COLLATE utf8mb4_unicode_nopad_ci NOT NULL DEFAULT '(no name)', `name` varchar(190) COLLATE utf8mb4_unicode_520_ci NOT NULL DEFAULT '(no name)',
`performer` varchar(190) COLLATE utf8mb4_unicode_nopad_ci NOT NULL DEFAULT 'Unknown', `performer` varchar(190) COLLATE utf8mb4_unicode_520_ci NOT NULL DEFAULT 'Unknown',
`genre` varchar(190) COLLATE utf8mb4_unicode_nopad_ci NOT NULL DEFAULT 'K-POP', `genre` varchar(190) COLLATE utf8mb4_unicode_520_ci NOT NULL DEFAULT 'K-POP',
`lyrics` longtext COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `lyrics` longtext COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`explicit` tinyint(4) NOT NULL DEFAULT 0 `explicit` tinyint(4) NOT NULL DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `audio_relations` ( CREATE TABLE `audio_relations` (
`user` bigint(20) UNSIGNED NOT NULL, `user` bigint(20) UNSIGNED NOT NULL,
`audio` bigint(20) UNSIGNED NOT NULL, `audio` bigint(20) UNSIGNED NOT NULL,
`index` bigint(20) UNSIGNED NOT NULL `index` bigint(20) UNSIGNED NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `comments` ( CREATE TABLE `comments` (
`id` bigint(20) UNSIGNED NOT NULL, `id` bigint(20) UNSIGNED NOT NULL,
`owner` bigint(20) NOT NULL, `owner` bigint(20) NOT NULL,
`model` varchar(128) COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `model` varchar(128) COLLATE utf8mb4_unicode_520_ci NOT NULL,
`target` bigint(20) UNSIGNED NOT NULL, `target` bigint(20) UNSIGNED NOT NULL,
`created` bigint(20) UNSIGNED NOT NULL, `created` bigint(20) UNSIGNED NOT NULL,
`edited` bigint(20) UNSIGNED DEFAULT NULL, `edited` bigint(20) UNSIGNED DEFAULT NULL,
`content` longtext COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `content` longtext COLLATE utf8mb4_unicode_520_ci NOT NULL,
`flags` tinyint(3) UNSIGNED DEFAULT NULL, `flags` tinyint(3) UNSIGNED DEFAULT NULL,
`ad` tinyint(1) NOT NULL DEFAULT 0, `ad` tinyint(1) NOT NULL DEFAULT 0,
`deleted` tinyint(1) DEFAULT 0, `deleted` tinyint(1) DEFAULT 0,
`virtual_id` bigint(20) DEFAULT 0 `virtual_id` bigint(20) DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `conv_sockets` ( CREATE TABLE `conv_sockets` (
`id` bigint(20) UNSIGNED NOT NULL, `id` bigint(20) UNSIGNED NOT NULL,
@ -96,32 +96,32 @@ CREATE TABLE `conv_sockets` (
`destination` bigint(20) UNSIGNED NOT NULL, `destination` bigint(20) UNSIGNED NOT NULL,
`open` bit(1) NOT NULL DEFAULT b'1', `open` bit(1) NOT NULL DEFAULT b'1',
`visible` bit(1) NOT NULL DEFAULT b'1' `visible` bit(1) NOT NULL DEFAULT b'1'
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `event_turnouts` ( CREATE TABLE `event_turnouts` (
`user` bigint(20) UNSIGNED NOT NULL, `user` bigint(20) UNSIGNED NOT NULL,
`event` bigint(20) UNSIGNED NOT NULL `event` bigint(20) UNSIGNED NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `groups` ( CREATE TABLE `groups` (
`id` bigint(20) UNSIGNED NOT NULL, `id` bigint(20) UNSIGNED NOT NULL,
`name` varchar(255) COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `name` varchar(255) COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`about` mediumtext COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `about` mediumtext COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`owner` bigint(20) UNSIGNED DEFAULT NULL, `owner` bigint(20) UNSIGNED DEFAULT NULL,
`shortcode` varchar(36) COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `shortcode` varchar(36) COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`verified` tinyint(1) NOT NULL DEFAULT 0, `verified` tinyint(1) NOT NULL DEFAULT 0,
`type` int(10) UNSIGNED DEFAULT 1, `type` int(10) UNSIGNED DEFAULT 1,
`closed` tinyint(3) UNSIGNED NOT NULL DEFAULT 0, `closed` tinyint(3) UNSIGNED NOT NULL DEFAULT 0,
`block_reason` text COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `block_reason` text COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`wall` int(11) NOT NULL DEFAULT 1 `wall` int(11) NOT NULL DEFAULT 1
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `group_coadmins` ( CREATE TABLE `group_coadmins` (
`user` bigint(20) UNSIGNED NOT NULL, `user` bigint(20) UNSIGNED NOT NULL,
`club` bigint(20) UNSIGNED NOT NULL, `club` bigint(20) UNSIGNED NOT NULL,
`comment` varchar(36) COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `comment` varchar(36) COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`id` bigint(20) NOT NULL `id` bigint(20) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `ip` ( CREATE TABLE `ip` (
`id` bigint(20) UNSIGNED NOT NULL, `id` bigint(20) UNSIGNED NOT NULL,
@ -132,28 +132,28 @@ CREATE TABLE `ip` (
`rate_limit_violation_counter_start` bigint(20) UNSIGNED NOT NULL DEFAULT 0, `rate_limit_violation_counter_start` bigint(20) UNSIGNED NOT NULL DEFAULT 0,
`rate_limit_violation_counter` tinyint(3) UNSIGNED NOT NULL DEFAULT 0, `rate_limit_violation_counter` tinyint(3) UNSIGNED NOT NULL DEFAULT 0,
`banned` tinyint(1) NOT NULL DEFAULT 0 `banned` tinyint(1) NOT NULL DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `likes` ( CREATE TABLE `likes` (
`origin` bigint(20) UNSIGNED NOT NULL, `origin` bigint(20) UNSIGNED NOT NULL,
`model` varchar(128) COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `model` varchar(128) COLLATE utf8mb4_unicode_520_ci NOT NULL,
`target` bigint(20) NOT NULL, `target` bigint(20) NOT NULL,
`index` bigint(20) UNSIGNED NOT NULL `index` bigint(20) UNSIGNED NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `messages` ( CREATE TABLE `messages` (
`id` bigint(20) NOT NULL, `id` bigint(20) NOT NULL,
`sender_type` varchar(64) COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `sender_type` varchar(64) COLLATE utf8mb4_unicode_520_ci NOT NULL,
`sender_id` bigint(20) UNSIGNED NOT NULL, `sender_id` bigint(20) UNSIGNED NOT NULL,
`recipient_type` varchar(64) COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `recipient_type` varchar(64) COLLATE utf8mb4_unicode_520_ci NOT NULL,
`recipient_id` bigint(20) UNSIGNED NOT NULL, `recipient_id` bigint(20) UNSIGNED NOT NULL,
`content` longtext COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `content` longtext COLLATE utf8mb4_unicode_520_ci NOT NULL,
`created` bigint(20) NOT NULL, `created` bigint(20) NOT NULL,
`edited` bigint(20) DEFAULT NULL, `edited` bigint(20) DEFAULT NULL,
`ad` tinyint(1) NOT NULL DEFAULT 0, `ad` tinyint(1) NOT NULL DEFAULT 0,
`deleted` tinyint(1) NOT NULL DEFAULT 0, `deleted` tinyint(1) NOT NULL DEFAULT 0,
`unread` tinyint(1) NOT NULL `unread` tinyint(1) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `msg_descriptors` ( CREATE TABLE `msg_descriptors` (
`message` bigint(20) UNSIGNED NOT NULL, `message` bigint(20) UNSIGNED NOT NULL,
@ -162,7 +162,7 @@ CREATE TABLE `msg_descriptors` (
`ack_time` bigint(20) UNSIGNED DEFAULT NULL, `ack_time` bigint(20) UNSIGNED DEFAULT NULL,
`visible` tinyint(3) UNSIGNED NOT NULL DEFAULT 1, `visible` tinyint(3) UNSIGNED NOT NULL DEFAULT 1,
`index` bigint(20) UNSIGNED NOT NULL `index` bigint(20) UNSIGNED NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `notes` ( CREATE TABLE `notes` (
`id` bigint(20) UNSIGNED NOT NULL, `id` bigint(20) UNSIGNED NOT NULL,
@ -170,24 +170,24 @@ CREATE TABLE `notes` (
`virtual_id` bigint(20) NOT NULL, `virtual_id` bigint(20) NOT NULL,
`created` bigint(20) NOT NULL, `created` bigint(20) NOT NULL,
`edited` bigint(20) DEFAULT NULL, `edited` bigint(20) DEFAULT NULL,
`name` varchar(256) COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `name` varchar(256) COLLATE utf8mb4_unicode_520_ci NOT NULL,
`source` longtext COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `source` longtext COLLATE utf8mb4_unicode_520_ci NOT NULL,
`cached_content` longtext COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `cached_content` longtext COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`deleted` tinyint(4) NOT NULL DEFAULT 0 `deleted` tinyint(4) NOT NULL DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `number_verification` ( CREATE TABLE `number_verification` (
`user` bigint(20) UNSIGNED NOT NULL, `user` bigint(20) UNSIGNED NOT NULL,
`number` varchar(48) COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `number` varchar(48) COLLATE utf8mb4_unicode_520_ci NOT NULL,
`code` mediumint(9) NOT NULL `code` mediumint(9) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `password_resets` ( CREATE TABLE `password_resets` (
`id` bigint(20) UNSIGNED NOT NULL, `id` bigint(20) UNSIGNED NOT NULL,
`profile` bigint(20) UNSIGNED NOT NULL, `profile` bigint(20) UNSIGNED NOT NULL,
`key` char(64) COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `key` char(64) COLLATE utf8mb4_unicode_520_ci NOT NULL,
`timestamp` bigint(20) UNSIGNED NOT NULL `timestamp` bigint(20) UNSIGNED NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `photos` ( CREATE TABLE `photos` (
`id` bigint(20) UNSIGNED NOT NULL, `id` bigint(20) UNSIGNED NOT NULL,
@ -195,10 +195,10 @@ CREATE TABLE `photos` (
`virtual_id` bigint(20) NOT NULL, `virtual_id` bigint(20) NOT NULL,
`created` bigint(20) UNSIGNED NOT NULL, `created` bigint(20) UNSIGNED NOT NULL,
`edited` bigint(20) UNSIGNED DEFAULT NULL, `edited` bigint(20) UNSIGNED DEFAULT NULL,
`hash` char(128) COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `hash` char(128) COLLATE utf8mb4_unicode_520_ci NOT NULL,
`deleted` tinyint(1) NOT NULL DEFAULT 0, `deleted` tinyint(1) NOT NULL DEFAULT 0,
`description` longtext COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL `description` longtext COLLATE utf8mb4_unicode_520_ci DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `posts` ( CREATE TABLE `posts` (
`id` bigint(20) UNSIGNED NOT NULL, `id` bigint(20) UNSIGNED NOT NULL,
@ -207,51 +207,51 @@ CREATE TABLE `posts` (
`virtual_id` bigint(20) UNSIGNED NOT NULL, `virtual_id` bigint(20) UNSIGNED NOT NULL,
`created` bigint(20) UNSIGNED NOT NULL, `created` bigint(20) UNSIGNED NOT NULL,
`edited` bigint(20) UNSIGNED DEFAULT NULL, `edited` bigint(20) UNSIGNED DEFAULT NULL,
`content` longtext COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `content` longtext COLLATE utf8mb4_unicode_520_ci NOT NULL,
`flags` tinyint(3) UNSIGNED DEFAULT NULL, `flags` tinyint(3) UNSIGNED DEFAULT NULL,
`nsfw` tinyint(1) NOT NULL DEFAULT 0, `nsfw` tinyint(1) NOT NULL DEFAULT 0,
`ad` tinyint(1) NOT NULL DEFAULT 0, `ad` tinyint(1) NOT NULL DEFAULT 0,
`deleted` tinyint(1) DEFAULT 0 `deleted` tinyint(1) DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `profiles` ( CREATE TABLE `profiles` (
`id` bigint(20) UNSIGNED NOT NULL, `id` bigint(20) UNSIGNED NOT NULL,
`user` varchar(36) COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `user` varchar(36) COLLATE utf8mb4_unicode_520_ci NOT NULL,
`first_name` varchar(50) COLLATE utf8mb4_unicode_nopad_ci NOT NULL DEFAULT 'Jane', `first_name` varchar(50) COLLATE utf8mb4_unicode_520_ci NOT NULL DEFAULT 'Jane',
`last_name` varchar(50) COLLATE utf8mb4_unicode_nopad_ci NOT NULL DEFAULT 'Doe', `last_name` varchar(50) COLLATE utf8mb4_unicode_520_ci NOT NULL DEFAULT 'Doe',
`pseudo` varchar(50) COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `pseudo` varchar(50) COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`info` longtext COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `info` longtext COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`about` longtext COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `about` longtext COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`status` varchar(255) COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `status` varchar(255) COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`privacy` bigint(20) UNSIGNED NOT NULL DEFAULT 1099511627775, `privacy` bigint(20) UNSIGNED NOT NULL DEFAULT 1099511627775,
`left_menu` bigint(20) UNSIGNED NOT NULL DEFAULT 1099511627775, `left_menu` bigint(20) UNSIGNED NOT NULL DEFAULT 1099511627775,
`sex` tinyint(1) NOT NULL DEFAULT 1, `sex` tinyint(1) NOT NULL DEFAULT 1,
`type` tinyint(4) NOT NULL DEFAULT 0, `type` tinyint(4) NOT NULL DEFAULT 0,
`phone` varchar(36) COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `phone` varchar(36) COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`email` varchar(90) COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `email` varchar(90) COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`coins` bigint(20) UNSIGNED NOT NULL DEFAULT 0, `coins` bigint(20) UNSIGNED NOT NULL DEFAULT 0,
`since` datetime NOT NULL, `since` datetime NOT NULL,
`block_reason` text COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `block_reason` text COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`verified` tinyint(1) NOT NULL DEFAULT 0, `verified` tinyint(1) NOT NULL DEFAULT 0,
`reputation` bigint(20) NOT NULL DEFAULT 1000, `reputation` bigint(20) NOT NULL DEFAULT 1000,
`shortcode` varchar(36) COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `shortcode` varchar(36) COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`registering_ip` varchar(256) COLLATE utf8mb4_unicode_nopad_ci NOT NULL DEFAULT '127.0.0.1', `registering_ip` varchar(256) COLLATE utf8mb4_unicode_520_ci NOT NULL DEFAULT '127.0.0.1',
`online` bigint(20) UNSIGNED NOT NULL DEFAULT 0, `online` bigint(20) UNSIGNED NOT NULL DEFAULT 0,
`birthday` bigint(20) DEFAULT 0, `birthday` bigint(20) DEFAULT 0,
`hometown` varchar(60) COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `hometown` varchar(60) COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`polit_views` int(11) DEFAULT 0, `polit_views` int(11) DEFAULT 0,
`marital_status` int(11) DEFAULT 0, `marital_status` int(11) DEFAULT 0,
`email_contact` varchar(128) COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `email_contact` varchar(128) COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`telegram` varchar(32) COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `telegram` varchar(32) COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`interests` mediumtext COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `interests` mediumtext COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`fav_music` mediumtext COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `fav_music` mediumtext COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`fav_films` mediumtext COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `fav_films` mediumtext COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`fav_shows` mediumtext COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `fav_shows` mediumtext COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`fav_books` mediumtext COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `fav_books` mediumtext COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`fav_quote` mediumtext COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `fav_quote` mediumtext COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`city` varchar(60) COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `city` varchar(60) COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`address` varchar(60) COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `address` varchar(60) COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`style` varchar(36) COLLATE utf8mb4_unicode_nopad_ci NOT NULL DEFAULT 'ovk', `style` varchar(36) COLLATE utf8mb4_unicode_520_ci NOT NULL DEFAULT 'ovk',
`style_avatar` int(11) DEFAULT 0, `style_avatar` int(11) DEFAULT 0,
`show_rating` tinyint(1) DEFAULT 1, `show_rating` tinyint(1) DEFAULT 1,
`milkshake` tinyint(1) NOT NULL DEFAULT 0, `milkshake` tinyint(1) NOT NULL DEFAULT 0,
@ -259,34 +259,47 @@ CREATE TABLE `profiles` (
`notification_offset` bigint(20) UNSIGNED DEFAULT 0, `notification_offset` bigint(20) UNSIGNED DEFAULT 0,
`deleted` tinyint(3) UNSIGNED NOT NULL DEFAULT 0, `deleted` tinyint(3) UNSIGNED NOT NULL DEFAULT 0,
`microblog` tinyint(3) UNSIGNED NOT NULL DEFAULT 0 `microblog` tinyint(3) UNSIGNED NOT NULL DEFAULT 0
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `stickerpacks` ( CREATE TABLE `stickerpacks` (
`id` bigint(20) UNSIGNED NOT NULL, `id` bigint(20) UNSIGNED NOT NULL,
`slug` varchar(36) COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `slug` varchar(36) COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`name` varchar(64) COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `name` varchar(64) COLLATE utf8mb4_unicode_520_ci NOT NULL,
`description` longtext COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `description` longtext COLLATE utf8mb4_unicode_520_ci NOT NULL,
`sold` tinyint(4) NOT NULL DEFAULT 0, `sold` tinyint(4) NOT NULL DEFAULT 0,
`price` bigint(20) UNSIGNED DEFAULT NULL `price` bigint(20) UNSIGNED DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `stickers` ( CREATE TABLE `stickers` (
`id` bigint(20) UNSIGNED NOT NULL, `id` bigint(20) UNSIGNED NOT NULL,
`hash` char(128) COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `hash` char(128) COLLATE utf8mb4_unicode_520_ci NOT NULL,
`emojis` longtext COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL `emojis` longtext COLLATE utf8mb4_unicode_520_ci DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `sticker_relations` ( CREATE TABLE `sticker_relations` (
`sticker` bigint(20) UNSIGNED NOT NULL, `sticker` bigint(20) UNSIGNED NOT NULL,
`pack` bigint(20) UNSIGNED NOT NULL, `pack` bigint(20) UNSIGNED NOT NULL,
`index` bigint(20) UNSIGNED NOT NULL `index` bigint(20) UNSIGNED NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `subscriptions` ( CREATE TABLE `subscriptions` (
`follower` bigint(20) UNSIGNED NOT NULL, `follower` bigint(20) UNSIGNED NOT NULL,
`model` longtext COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `model` longtext COLLATE utf8mb4_unicode_520_ci NOT NULL,
`target` bigint(20) UNSIGNED NOT NULL `target` bigint(20) UNSIGNED NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE subscriptions_new (
`handle` bigint(20) UNSIGNED NOT NULL,
`initiator` bigint(20) UNSIGNED NOT NULL,
`targetModel` varchar(128) COLLATE utf8mb4_unicode_520_ci NOT NULL,
`targetId` bigint(20) NOT NULL,
`targetWallHandle` bigint(20) NOT NULL,
`shortStatus` tinyint(3) UNSIGNED NOT NULL DEFAULT 1,
`detailedStatus` tinyint(3) UNSIGNED NOT NULL DEFAULT 1,
`listName` varchar(64) COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`created` bigint(20) UNSIGNED NOT NULL,
`updated` bigint(20) UNSIGNED NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE subscriptions_new ( CREATE TABLE subscriptions_new (
`handle` bigint(20) UNSIGNED NOT NULL, `handle` bigint(20) UNSIGNED NOT NULL,
@ -306,20 +319,20 @@ CREATE TABLE `tickets` (
`type` bigint(20) UNSIGNED NOT NULL, `type` bigint(20) UNSIGNED NOT NULL,
`deleted` tinyint(4) NOT NULL DEFAULT 0, `deleted` tinyint(4) NOT NULL DEFAULT 0,
`user_id` bigint(20) UNSIGNED NOT NULL, `user_id` bigint(20) UNSIGNED NOT NULL,
`name` text COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `name` text COLLATE utf8mb4_unicode_520_ci NOT NULL,
`text` longtext COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `text` longtext COLLATE utf8mb4_unicode_520_ci NOT NULL,
`created` bigint(20) UNSIGNED NOT NULL `created` bigint(20) UNSIGNED NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `tickets_comments` ( CREATE TABLE `tickets_comments` (
`id` int(11) NOT NULL, `id` int(11) NOT NULL,
`user_id` bigint(20) UNSIGNED NOT NULL, `user_id` bigint(20) UNSIGNED NOT NULL,
`user_type` int(11) NOT NULL DEFAULT 0, `user_type` int(11) NOT NULL DEFAULT 0,
`text` longtext COLLATE utf8mb4_unicode_nopad_ci NOT NULL, `text` longtext COLLATE utf8mb4_unicode_520_ci NOT NULL,
`created` int(11) NOT NULL, `created` int(11) NOT NULL,
`deleted` tinyint(4) NOT NULL DEFAULT 0, `deleted` tinyint(4) NOT NULL DEFAULT 0,
`ticket_id` bigint(20) DEFAULT NULL `ticket_id` bigint(20) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
CREATE TABLE `videos` ( CREATE TABLE `videos` (
`id` bigint(20) UNSIGNED NOT NULL, `id` bigint(20) UNSIGNED NOT NULL,
@ -327,12 +340,12 @@ CREATE TABLE `videos` (
`virtual_id` bigint(20) NOT NULL, `virtual_id` bigint(20) NOT NULL,
`created` bigint(20) UNSIGNED NOT NULL, `created` bigint(20) UNSIGNED NOT NULL,
`edited` bigint(20) UNSIGNED DEFAULT NULL, `edited` bigint(20) UNSIGNED DEFAULT NULL,
`hash` char(128) COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `hash` char(128) COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`link` varchar(64) COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `link` varchar(64) COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`deleted` tinyint(1) NOT NULL DEFAULT 0, `deleted` tinyint(1) NOT NULL DEFAULT 0,
`description` longtext COLLATE utf8mb4_unicode_nopad_ci DEFAULT NULL, `description` longtext COLLATE utf8mb4_unicode_520_ci DEFAULT NULL,
`name` varchar(64) COLLATE utf8mb4_unicode_nopad_ci NOT NULL `name` varchar(64) COLLATE utf8mb4_unicode_520_ci NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_nopad_ci; ) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci;
ALTER TABLE `albums` ALTER TABLE `albums`

View file

@ -48,10 +48,10 @@ openvk:
smsc: smsc:
enable: false enable: false
client: "" client: ""
secret: "" secret: "SECRET_KEY_HERE"
eventDB: eventDB:
enable: false # Better enable this enable: false # Better enable this
database: database:
dsn: "mysql:unix_socket=/tmp/mysql.sock;dbname=openvk-eventdb" dsn: "mysql:unix_socket=/tmp/mysql.sock;dbname=openvk-eventdb"
user: "" user: "root"
password: "" password: "DATABASE_PASSWORD"