Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
F
frontend
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
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
idatt2106-2024-07
frontend
Commits
fb9ea583
Commit
fb9ea583
authored
1 year ago
by
Henrik
Browse files
Options
Downloads
Patches
Plain Diff
fix: fix 11
parent
9aa2a5f7
No related branches found
Branches containing commit
No related tags found
1 merge request
!91
Feat/deployment
Pipeline
#283743
passed with warnings
1 year ago
Stage: docker_build_and_push
Stage: deploy_docker
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
.gitlab-ci.yml
+1
-1
1 addition, 1 deletion
.gitlab-ci.yml
Dockerfile
+5
-6
5 additions, 6 deletions
Dockerfile
web/nginx.conf
+6
-1
6 additions, 1 deletion
web/nginx.conf
with
12 additions
and
8 deletions
.gitlab-ci.yml
+
1
−
1
View file @
fb9ea583
...
...
@@ -36,5 +36,5 @@ deploy_docker:
-
apt-get -yqq install ssh
-
apt-get install sshpass
script
:
-
sshpass -p sParest1en ssh -v -o StrictHostKeyChecking=no root@128.199.53.153 "docker rm -f frontend ||
true
; docker run -d --name frontend registry.gitlab.com/$DOCKER_USER/sparesti-registry:frontend"
-
sshpass -p sParest1en ssh -v -o StrictHostKeyChecking=no root@128.199.53.153 "docker rm -f frontend ||
true
; docker run -d --name
-p 80:5173
frontend registry.gitlab.com/$DOCKER_USER/sparesti-registry:frontend"
when
:
manual
\ No newline at end of file
This diff is collapsed.
Click to expand it.
Dockerfile
+
5
−
6
View file @
fb9ea583
...
...
@@ -6,11 +6,10 @@ RUN npm install
COPY
. .
RUN
npm run build
# Step 2: Setup the server with Nginx
FROM
nginx:stable-alpine
as
production-stage
COPY
--from=build-stage /app/dist /usr/share/nginx/html
COPY
web/nginx.conf /etc/nginx/nginx.conf
EXPOSE
5173
# Step 2: Setup the server with Nginx
#FROM nginx:stable-alpine as production-stage
#COPY --from=build-stage /app/dist /usr/share/nginx/html
#COPY web/nginx.conf /etc/nginx/nginx.conf
CMD
["nginx", "-g", "daemon off;"]
\ No newline at end of file
#CMD ["nginx", "-g", "daemon off;"]
\ No newline at end of file
This diff is collapsed.
Click to expand it.
web/nginx.conf
+
6
−
1
View file @
fb9ea583
events
{
worker_processes
auto
;
error_log
/var/log/nginx/error.log
notice
;
pid
/var/run/nginx.pid
;
events
{
worker_connections
1024
;
}
http
{
...
...
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