Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
K
kubernetes-krash
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Henrik Henriksson
kubernetes-krash
Commits
8fedb72d
Commit
8fedb72d
authored
4 years ago
by
Henrik Henriksson
Browse files
Options
Downloads
Patches
Plain Diff
Go back to python....
parent
3c0be472
Branches
Branches containing commit
No related tags found
No related merge requests found
Pipeline
#19702
failed
4 years ago
Stage: build
Stage: images
Stage: deploy
Changes
4
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
.gitlab-ci.yml
+0
-2
0 additions, 2 deletions
.gitlab-ci.yml
realworld/backend-deployment.yaml
+5
-2
5 additions, 2 deletions
realworld/backend-deployment.yaml
realworld/backend/Dockerfile
+5
-8
5 additions, 8 deletions
realworld/backend/Dockerfile
realworld/ingress.yaml
+1
-1
1 addition, 1 deletion
realworld/ingress.yaml
with
11 additions
and
13 deletions
.gitlab-ci.yml
+
0
−
2
View file @
8fedb72d
...
@@ -23,7 +23,6 @@ deploy-hello-world:
...
@@ -23,7 +23,6 @@ deploy-hello-world:
-
sleep
5
# Wait for containers to start before showing status
-
sleep
5
# Wait for containers to start before showing status
-
kubectl get all
# Show everything again
-
kubectl get all
# Show everything again
build-realworld-backend
:
build-realworld-backend
:
stage
:
images
stage
:
images
image
:
docker.io/buildah/buildah
image
:
docker.io/buildah/buildah
...
@@ -112,7 +111,6 @@ deploy-realworld:
...
@@ -112,7 +111,6 @@ deploy-realworld:
needs
:
[]
needs
:
[]
rules
:
rules
:
-
if
:
'
$CI_COMMIT_BRANCH
==
"master"'
-
if
:
'
$CI_COMMIT_BRANCH
==
"master"'
stage
:
deploy
stage
:
deploy
image
:
lachlanevenson/k8s-kubectl
image
:
lachlanevenson/k8s-kubectl
script
:
script
:
...
...
This diff is collapsed.
Click to expand it.
realworld/backend-deployment.yaml
+
5
−
2
View file @
8fedb72d
api
V
ersion
:
apps/v1
api
v
ersion
:
apps/v1
kind
:
Deployment
kind
:
Deployment
metadata
:
metadata
:
name
:
realworld-backend-deployment
name
:
realworld-backend-deployment
...
@@ -24,8 +24,11 @@ spec:
...
@@ -24,8 +24,11 @@ spec:
-
-
name
:
DATABASE_URL
name
:
DATABASE_URL
value
:
postgresql://realworld:intel123@postgres-service/postgres-realworld
value
:
postgresql://realworld:intel123@postgres-service/postgres-realworld
-
name
:
CONDUIT_SECRET
value
:
hunter2
ports
:
ports
:
-
containerPort
:
8
0
-
containerPort
:
500
0
protocol
:
TCP
protocol
:
TCP
resources
:
resources
:
limits
:
limits
:
...
...
This diff is collapsed.
Click to expand it.
realworld/backend/Dockerfile
+
5
−
8
View file @
8fedb72d
FROM
elixir
FROM
python:3.8-buster
ENV
SECRET_KEY_BASE hunter2
RUN
apt update
-y
&&
apt
install
-y
git
RUN
apt update
-y
&&
apt
install
-y
git
RUN
git clone https://github.com/gothinkster/
elixir-phoenix
-realworld-example-app.git
RUN
git clone https://github.com/gothinkster/
flask
-realworld-example-app.git
RUN
apt autoremove
-y
git
RUN
apt autoremove
-y
git
RUN
apt-get clean
RUN
apt-get clean
RUN
apt-get autoclean
RUN
apt-get autoclean
COPY
config.exs elixir-phoenix-realworld-example-app/config/prod.exs
RUN
cd
flask-realworld-example-app/requirements
&&
pip
install
-r
dev.txt
COPY
config.exs elixir-phoenix-realworld-example-app/config/dev.exs
RUN
cd
elixir-phoenix-realworld-example-app
;
cp
config/prod.exs config/dev.exs
;
mix local.hex
--force
;
mix deps.get
ENV
FLASK_APP=autoapp.py
CMD
cd
elixir-phoenix
-realworld-example-app
;
sleep 30; mix local.hex --force; mix ecto.create ; mix ecto.mi
gra
t
e ;
mix phx.server
CMD
cd
flask
-realworld-example-app;
flask db init; flask db migrate ; flask db up
gra
d
e ;
flask run --host=0.0.0.0
This diff is collapsed.
Click to expand it.
realworld/ingress.yaml
+
1
−
1
View file @
8fedb72d
...
@@ -13,7 +13,7 @@ spec:
...
@@ -13,7 +13,7 @@ spec:
paths
:
paths
:
-
backend
:
-
backend
:
serviceName
:
realworld-backend-service
serviceName
:
realworld-backend-service
servicePort
:
8
0
servicePort
:
500
0
path
:
/api/
path
:
/api/
-
frontend
:
-
frontend
:
serviceName
:
realworld-frontend-service
serviceName
:
realworld-frontend-service
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment