Mariadb Docker image and init.sql
This commit is contained in:
0
.gitignore
vendored
Normal file
0
.gitignore
vendored
Normal file
@@ -4,3 +4,9 @@ This is a practical test for a DevSecOps Engineer candidate at Bank J. Safra Sar
|
|||||||
|
|
||||||
### On 09.02.2026
|
### On 09.02.2026
|
||||||
I created repo on https://git.harshanu.space. I'll work on code changes tomorrow as I will be free in the afternoon (Fashing Tuesday, half day work)
|
I created repo on https://git.harshanu.space. I'll work on code changes tomorrow as I will be free in the afternoon (Fashing Tuesday, half day work)
|
||||||
|
|
||||||
|
### On 10.02.2026
|
||||||
|
- Defined the database schema for the API endpoints in `init.sql`.
|
||||||
|
- Pulled the `docker.io/library/mariadb:12` Docker image.
|
||||||
|
- Tested the schema by spinning up a MariaDB container and verifying the table creation.
|
||||||
|
- Python will be used to write API endpoints
|
||||||
|
|||||||
9
init.sql
Normal file
9
init.sql
Normal file
@@ -0,0 +1,9 @@
|
|||||||
|
CREATE DATABASE IF NOT EXISTS devsecops_db;
|
||||||
|
USE devsecops_db;
|
||||||
|
|
||||||
|
CREATE TABLE IF NOT EXISTS device_registrations (
|
||||||
|
id INT AUTO_INCREMENT PRIMARY KEY,
|
||||||
|
user_key VARCHAR(255) NOT NULL,
|
||||||
|
device_type VARCHAR(50) NOT NULL,
|
||||||
|
created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP
|
||||||
|
);
|
||||||
Reference in New Issue
Block a user