Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
becskasszasch
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
JetBrains YouTrack
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
KSZK
DevTeam
becskasszasch
Commits
d25f4a47
Verified
Commit
d25f4a47
authored
3 years ago
by
Réthelyi Bálint
Browse files
Options
Downloads
Patches
Plain Diff
try another registry
parent
01f0e600
No related branches found
No related tags found
1 merge request
!18
Dockerhub
Pipeline
#8964
failed
3 years ago
Changes
4
Pipelines
2
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
.gitlab-ci.yml
+38
-36
38 additions, 36 deletions
.gitlab-ci.yml
k8s/templates/deployment.yml
+3
-3
3 additions, 3 deletions
k8s/templates/deployment.yml
k8s/templates/secret.yml
+9
-9
9 additions, 9 deletions
k8s/templates/secret.yml
k8s/values.yaml
+1
-1
1 addition, 1 deletion
k8s/values.yaml
with
51 additions
and
49 deletions
.gitlab-ci.yml
+
38
−
36
View file @
d25f4a47
...
...
@@ -6,35 +6,10 @@ variables:
stages
:
-
pre-build
-
build
-
docker
-build
-
docker
-
deploy
format
:
tags
:
[
kszk
]
image
:
golang:alpine
stage
:
pre-build
before_script
:
-
apk add build-base
script
:
-
go fmt $(go list ./... | grep -v /vendor/)
-
go vet $(go list ./... | grep -v /vendor/)
-
go test -race $(go list ./... | grep -v /vendor/)
rules
:
-
changes
:
-
admin/*
-
auth/*
-
db/*
-
error/*
-
helpers/*
-
history/*
-
homepage/*
-
k8s/*
-
topup/*
-
main.go
-
go.mod
go_build
:
tags
:
[
kszk
]
image
:
golang:alpine
...
...
@@ -63,19 +38,17 @@ go_build:
-
go.mod
needs
:
[]
docker
:
stage
:
docker-build
tags
:
[
kszk
]
needs
:
-
go_build
-
format
dockerhub
:
stage
:
docker
image
:
name
:
gcr.io/kaniko-project/executor:debug
entrypoint
:
[
"
"
]
script
:
-
echo "{\"auths\":{\"registry.kszk.bme.hu\":{\"username\":\"$REGISTRY_USER\",\"password\":\"$REGISTRY_PASSWORD\"}}}" > /kaniko/.docker/config.json
-
echo " /kaniko/executor --context $CI_PROJECT_DIR --dockerfile $CI_PROJECT_DIR/Dockerfile --destination $REGISTRY/$CONTAINER_IMAGE"
-
/kaniko/executor --context $CI_PROJECT_DIR --dockerfile $CI_PROJECT_DIR/Dockerfile --destination $REGISTRY/$CONTAINER_IMAGE
-
mkdir -p /kaniko/.docker
-
echo "{\"auths\":{\"https://index.docker.io/v1/\":{\"username\":\"$DOCKERHUB_USER\",\"password\":\"$DOCKERHUB_PASSWORD\"}}}" > /kaniko/.docker/config.json
-
/kaniko/executor --force --context $CI_PROJECT_DIR --dockerfile $CI_PROJECT_DIR/Dockerfile --destination blintmester/$CONTAINER_IMAGE
needs
:
-
go_build
rules
:
-
if
:
$CI_COMMIT_TAG
changes
:
...
...
@@ -92,6 +65,35 @@ docker:
-
go.mod
-
Dockerfile
#docker:
# stage: docker-build
# tags: [kszk]
# needs:
# - go_build
# - format
# image:
# name: gcr.io/kaniko-project/executor:debug
# entrypoint: [""]
# script:
# - echo "{\"auths\":{\"registry.kszk.bme.hu\":{\"username\":\"$REGISTRY_USER\",\"password\":\"$REGISTRY_PASSWORD\"}}}" > /kaniko/.docker/config.json
# - echo " /kaniko/executor --context $CI_PROJECT_DIR --dockerfile $CI_PROJECT_DIR/Dockerfile --destination $REGISTRY/$CONTAINER_IMAGE"
# - /kaniko/executor --context $CI_PROJECT_DIR --dockerfile $CI_PROJECT_DIR/Dockerfile --destination $REGISTRY/$CONTAINER_IMAGE
# rules:
# - if: $CI_COMMIT_TAG
# changes:
# - admin/*
# - auth/*
# - db/*
# - error/*
# - helpers/*
# - history/*
# - homepage/*
# - k8s/*
# - topup/*
# - main.go
# - go.mod
# - Dockerfile
Upgrade helm
:
stage
:
deploy
image
:
...
...
This diff is collapsed.
Click to expand it.
k8s/templates/deployment.yml
+
3
−
3
View file @
d25f4a47
...
...
@@ -13,7 +13,7 @@ spec:
spec
:
containers
:
-
name
:
becskasszasch
image
:
"
registry.kszk.bme.hu/kszk/devteam
/becskasszasch:{{
.Values.Tag
}}"
image
:
"
docker.io/blintmester
/becskasszasch:{{
.Values.Tag
}}"
args
:
-
-logSQL
ports
:
...
...
@@ -36,5 +36,5 @@ spec:
initialDelaySeconds
:
60
failureThreshold
:
3
periodSeconds
:
60
imagePullSecrets
:
-
name
:
devteam-nexus-login
{{
/*
imagePullSecrets
:
*
/
}}
{{
/*
- name
:
devteam-nexus-login
*/
}}
This diff is collapsed.
Click to expand it.
k8s/templates/secret.yml
+
9
−
9
View file @
d25f4a47
...
...
@@ -10,12 +10,12 @@ stringData:
POSTGRES_USER
:
"
{{
.Values.POSTGRES_USER
}}"
POSTGRES_DB
:
"
{{
.Values.POSTGRES_DB
}}"
---
apiVersion
:
v1
data
:
.dockerconfigjson
:
"
{{
.Values.REGISTRY_CONF
}}"
kind
:
Secret
metadata
:
name
:
devteam-nexus-login
namespace
:
apps
type
:
kubernetes.io/dockerconfigjson
\ No newline at end of file
{{
/*---*/
}}
{{
/*apiVersion
:
v1*/
}}
{{
/*data
:
*
/
}}
{{
/* .dockerconfigjson
:
"
{{
.Values.REGISTRY_CONF
}}"
*
/
}}
{{
/*kind
:
Secret*/
}}
{{
/*metadata
:
*
/
}}
{{
/* name
:
devteam-nexus-login*/
}}
{{
/* namespace
:
apps*/
}}
{{
/*type
:
kubernetes.io/dockerconfigjson*/
}}
\ No newline at end of file
This diff is collapsed.
Click to expand it.
k8s/values.yaml
+
1
−
1
View file @
d25f4a47
...
...
@@ -7,5 +7,5 @@ POSTGRES: "${POSTGRES}"
POSTGRES_PASS
:
"
${POSTGRES_PASS}"
POSTGRES_USER
:
"
${POSTGRES_USER}"
POSTGRES_DB
:
"
${POSTGRES_DB}"
Tag
:
"
v1.6.
6
"
Tag
:
"
v1.6.
7
"
REGISTRY_CONF
:
"
${REGISTRY_CONF}"
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