-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Updated docker image file * rename lint
- Loading branch information
Showing
7 changed files
with
39 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
--- | ||
name: release | ||
on: | ||
'on': | ||
push: | ||
branches: | ||
- staging | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,10 @@ | ||
#Create MySQL Image for CICDPlay Tutorial Application | ||
FROM mysql | ||
# Derived from official mysql image (our base image) | ||
FROM mysql:8.0.32-debian | ||
|
||
ENV MYSQL_ROOT_PASSWORD cicdplaypassword | ||
ADD cplay.sql /docker-entrypoint-initdb.d | ||
# Add a database | ||
ENV MYSQL_DATABASE company | ||
|
||
EXPOSE 3306 | ||
# Add the content of the sql-scripts/ directory to your image | ||
# All scripts in docker-entrypoint-initdb.d/ are automatically | ||
# executed during container startup | ||
COPY ./sql-scripts/ /docker-entrypoint-initdb.d/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,22 @@ | ||
#!/bin/bash | ||
|
||
docker build -t cplaymysql:0.1 . | ||
# Docker build image | ||
docker build -t cicd-app1-db . | ||
|
||
# Docker List images | ||
docker images | grep cicd-app1-db | ||
|
||
# Docker Tag images | ||
docker tag cicd-app1-db:latest makwanji/cicd-app1-db:0.0.2 | ||
docker tag cicd-app1-db:latest makwanji/cicd-app1-db:latest | ||
|
||
# Docker Push images | ||
docker push makwanji/cicd-app1-db:0.0.2 | ||
docker push makwanji/cicd-app1-db:latest | ||
|
||
# Docker list images | ||
docker images | grep cicd-app1-db | ||
|
||
# Docker build container from image | ||
docker run -d --name cicd-app1-db makwanji/cicd-app1-db:latest | ||
docker run -d -p 3306:3306 --name cicd-app1-db -e MYSQL_ROOT_PASSWORD=supersecret makwanji/cicd-app1-db:latest |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
CREATE TABLE employees ( | ||
first_name varchar(25), | ||
last_name varchar(25), | ||
department varchar(15), | ||
email varchar(50) | ||
); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
INSERT INTO employees (first_name, last_name, department, email) | ||
VALUES ('Lorenz', 'Vanthillo', 'IT', 'lvthillo@mail.com'); |