20 Commits
Author SHA1 Message Date
tiutriumov.sm e3b1bfec25 --- 2024-05-20 22:44:26 +03:00
tiutriumov.sm 8600b9dabc -docker compose 2024-05-20 22:34:48 +03:00
tiutriumov.sm ff7e86b602 apk add --no-cache py-pi 2024-05-20 22:22:48 +03:00
tiutriumov.sm 81146eefb6 apk add --no-cache py-pip 2024-05-20 22:20:09 +03:00
tiutriumov.sm 1d76eca96c tags removed 2024-05-20 22:06:04 +03:00
tiutriumov.sm 2d8542475b tags 2024-05-20 22:04:07 +03:00
tiutriumov.sm b6eb3e37b6 runnerfix 2024-05-20 21:49:45 +03:00
tiutriumov.sm bad2619deb AppArmor 2024-05-20 21:38:19 +03:00
tiutriumov.sm 61efc501f6 --privileged 2024-05-20 21:10:14 +03:00
tiutriumov.sm b5d5041103 try again 2024-05-20 20:14:07 +03:00
tiutriumov.sm a753eda2f9 docker login 2024-05-19 16:39:42 +03:00
tiutriumov.sm a17c4d6464 docker build 2024-05-19 16:11:49 +03:00
tiutriumov.sm ff649de3d2 only front lint 2024-05-19 14:16:19 +03:00
tiutriumov.sm 7607d2ade6 . 2024-05-19 14:02:16 +03:00
tiutriumov.sm ec987885aa node:18-slim 2024-05-19 13:43:21 +03:00
tiutriumov.sm f79c1a4332 syntax error 2024-05-19 01:51:30 +03:00
tiutriumov.sm 9dade06d0a lint . 2024-05-19 01:45:55 +03:00
tiutriumov.sm 3c1c1ee58c only removed 2024-05-19 01:22:43 +03:00
tiutriumov.sm 7496c17cec lint stage 2024-05-19 01:12:26 +03:00
tiutriumov.sm 4f3f6a8e4a lint 2024-05-19 01:04:18 +03:00
4 changed files with 89 additions and 20 deletions
+29 -20
View File
@@ -1,24 +1,33 @@
build-job:
stages:
- build
- push
variables:
DOCKER_DRIVER: overlay2
DOCKER_TLS_CERTDIR: ""
DOCKER_HOST: tcp://docker:2375/
DOCKER_USERNAME: serjiomarello
DOCKER_PASSWORD: TaReMona225657
services:
- name: docker:dind
command: ["--privileged"]
before_script:
- docker info
build_container:
stage: build
image: docker:19.03.12
script:
- echo "Hello, $GITLAB_USER_LOGIN!"
- docker build -t $CI_REGISTRY_IMAGE/my-container:latest .
- docker tag $CI_REGISTRY_IMAGE/my-container:latest $CI_REGISTRY_IMAGE/my-container:$CI_COMMIT_SHORT_SHA
test-job1:
stage: test
push_container:
stage: push
image: docker:19.03.12
script:
- echo "This job tests something"
test-job2:
stage: test
script:
- echo "This job tests something, but takes more time than test-job1."
- echo "After the echo commands complete, it runs the sleep command for 20 seconds"
- echo "which simulates a test that runs 20 seconds longer than test-job1"
- sleep 20
deploy-prod:
stage: deploy
script:
- echo "This job deploys something from the $CI_COMMIT_BRANCH branch."
environment: production
- echo "$CI_REGISTRY_PASSWORD" | docker login -u "$CI_REGISTRY_USER" --password-stdin $CI_REGISTRY
- docker push $CI_REGISTRY_IMAGE/my-container:latest
- docker push $CI_REGISTRY_IMAGE/my-container:$CI_COMMIT_#
+22
View File
@@ -0,0 +1,22 @@
#Front
FROM node:18-slim
WORKDIR /usr/local/app
COPY notes-app/package*.json ./
RUN npm i && npm cache clean --force
COPY notes-app/ .
RUN npm run build
#Backend
FROM node:18-slim
WORKDIR /usr/local/app
COPY notes-backend/package*.json ./
RUN npm i && npm cache clean --force
COPY notes-backend/ .
RUN npm run build
#nginx
FROM nginx:alpine
COPY nginx/default.conf /etc/nginx/conf.d/default.conf
COPY --from=build-react /app/build /usr/share/nginx/html
COPY --from=build-node /app/dist /usr/share/nginx/html/api
EXPOSE 80
CMD ["nginx", "-g", "daemon off;"]
+19
View File
@@ -0,0 +1,19 @@
{
"env": {
"browser": true,
"es2021": true
},
"extends": ["eslint:recommended", "plugin:react/recommended"],
"parserOptions": {
"ecmaFeatures": {
"jsx": true
},
"ecmaVersion": 12,
"sourceType": "module"
},
"plugins": ["react"],
"rules": {
"react/prop-types": "off"
}
}
+19
View File
@@ -0,0 +1,19 @@
{
"env": {
"browser": true,
"es2021": true
},
"extends": ["eslint:recommended", "plugin:react/recommended"],
"parserOptions": {
"ecmaFeatures": {
"jsx": true
},
"ecmaVersion": 12,
"sourceType": "module"
},
"plugins": ["react"],
"rules": {
"react/prop-types": "off"
}
}