Update docker-compose

This commit is contained in:
Aelita4 2022-09-16 18:57:14 +02:00
parent e7c6a51752
commit 899f26ab35
Signed by: Aelita4
GPG Key ID: E4773B4E7238A472
2 changed files with 7 additions and 29 deletions

View File

@ -3,40 +3,18 @@ services:
app: app:
container_name: sshmon_main container_name: sshmon_main
restart: always restart: always
image: sshmon image: sshmon:surreal
ports: ports:
- "8080:8080" - "8080:8080"
depends_on:
- mysql
networks: networks:
- network - network
mysql: surrealdb:
container_name: sshmon_mysql container_name: sshmon_surrealdb
restart: always restart: always
image: mysql:latest image: surrealdb/surrealdb:latest
environment: command: start --user root --pass root memory
MYSQL_ROOT_PASSWORD: 'root'
ports: ports:
- "3306:3306" - "8000:8000"
volumes:
- volume:/var/lib/mysql
networks:
- network
healthcheck:
test: "/usr/bin/mysql --user=root --password=root --execute \"SHOW DATABASES;\""
interval: 2s
timeout: 20s
retries: 10
pma:
image: phpmyadmin/phpmyadmin
container_name: sshmon_pma
restart: always
environment:
- PMA_ARBITRARY=1
ports:
- "8081:80"
depends_on:
- mysql
networks: networks:
- network - network
volumes: volumes:

View File

@ -35,7 +35,7 @@ const getIP = () : Promise<string[]> => {
}); });
} }
const connection = new Surreal("http://127.0.0.1:8000/rpc"); const connection = new Surreal("http://surrealdb:8000/rpc");
await connection.signin({ await connection.signin({
user: "root", user: "root",