Working DB prepare
This commit is contained in:
parent
03e7d751e7
commit
da5128ac23
15
Makefile
15
Makefile
@ -19,6 +19,16 @@ install-dependencies-rocky:
|
|||||||
install-latest-mariadb-rocky:
|
install-latest-mariadb-rocky:
|
||||||
bash install-latest-mariadb-rocky.sh
|
bash install-latest-mariadb-rocky.sh
|
||||||
|
|
||||||
|
remove-gitea-conf:
|
||||||
|
rm -vf /etc/gitea/app.ini
|
||||||
|
|
||||||
|
clenaup-db-data:
|
||||||
|
rm -vrf /var/lib/mysql
|
||||||
|
|
||||||
|
remove-mariadb:
|
||||||
|
dnf remove mariadb-common -y ;true
|
||||||
|
dnf remove MariaDB-common -y ;true
|
||||||
|
|
||||||
enable-mariadb:
|
enable-mariadb:
|
||||||
systemctl daemon-reload
|
systemctl daemon-reload
|
||||||
systemctl enable mariadb
|
systemctl enable mariadb
|
||||||
@ -48,6 +58,11 @@ enable-gitea:
|
|||||||
start-gitea:
|
start-gitea:
|
||||||
systemctl start gitea
|
systemctl start gitea
|
||||||
|
|
||||||
|
stop-gitea:
|
||||||
|
systemctl start gitea
|
||||||
|
|
||||||
|
restart-gitea: stop start
|
||||||
|
|
||||||
create-user-debian:
|
create-user-debian:
|
||||||
adduser --system --shell /bin/bash --gecos 'Git Version Control' \
|
adduser --system --shell /bin/bash --gecos 'Git Version Control' \
|
||||||
--group --disabled-password --home /home/git git
|
--group --disabled-password --home /home/git git
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
|
DROP USER ''@'localhost';
|
||||||
CREATE DATABASE gitea CHARACTER SET 'utf8mb4' COLLATE 'utf8mb4_bin';
|
CREATE DATABASE gitea CHARACTER SET 'utf8mb4' COLLATE 'utf8mb4_bin';
|
||||||
CREATE USER 'gitea'@'%' IDENTIFIED BY 'gitea';
|
CREATE USER 'gitea'@'%' IDENTIFIED BY 'gitea';
|
||||||
CREATE USER 'gitea'@'localhost' IDENTIFIED BY 'gitea';
|
CREATE USER 'gitea'@'localhost' IDENTIFIED BY 'gitea';
|
||||||
GRANT ALL PRIVILEGES ON gitea.* TO 'gitea';
|
GRANT ALL PRIVILEGES ON *.* TO 'gitea'@'localhost';
|
||||||
|
GRANT ALL PRIVILEGES ON *.* TO 'gitea'@'%';
|
||||||
FLUSH PRIVILEGES;
|
FLUSH PRIVILEGES;
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user