Skip to content

Commit

Permalink
Merge pull request #175 from dscdut/setup-cicd
Browse files Browse the repository at this point in the history
chore: disable circleci
  • Loading branch information
High10Hunter authored Mar 13, 2024
2 parents f93d4cb + c773d16 commit 99b5a8b
Showing 1 changed file with 64 additions and 64 deletions.
128 changes: 64 additions & 64 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
@@ -1,64 +1,64 @@
version: 2.1
aliases:
- &restore-cache
restore_cache:
keys:
- v1-dependencies-
# fallback to using the latest cache if no exact match is found
- v1-dependencies-
- &install-deps
run:
name: Install dependencies
command: npm i

orbs:
node: circleci/node@3.0.0

jobs:
build:
environment:
DOCKER_IMAGE: ichhoa129/discord-bot
DOCKER_TAG: latest
working_directory: ~/sharinghub/backend
docker:
- image: circleci/node:14
- image: docker:17.09.1-ce-git
steps:
- checkout
- setup_remote_docker
- *restore-cache
- run: npm cache clear --force
- run:
name: Update NPM version
command: 'sudo npm install -g npm@latest'
- *install-deps
- save_cache:
key: v1-dependencies-{{ checksum "package.json" }}
paths:
- ./node_modules

deploy:
machine:
enabled: true
working_directory: ~/sharinghub/backend
steps:
- add_ssh_keys:
fingerprints:
- '39:84:cb:5e:ca:8e:c1:71:f6:19:ad:0c:bc:0f:78:21'
- run:
name: Deploy via ssh
command: |
echo Starting to deploy server
ssh -v $SSH_USER@$SSH_HOST 'cd sharinghub/backend && git checkout develop && git pull && chmod 777 ./deploy.sh && ./deploy.sh'
workflows:
version: 2
build-and-deploy:
jobs:
- build
- deploy:
requires:
- build
filters:
branches:
only:
- develop
# version: 2.1
# aliases:
# - &restore-cache
# restore_cache:
# keys:
# - v1-dependencies-
# # fallback to using the latest cache if no exact match is found
# - v1-dependencies-
# - &install-deps
# run:
# name: Install dependencies
# command: npm i

# orbs:
# node: circleci/node@3.0.0

# jobs:
# build:
# environment:
# DOCKER_IMAGE: ichhoa129/discord-bot
# DOCKER_TAG: latest
# working_directory: ~/sharinghub/backend
# docker:
# - image: circleci/node:14
# - image: docker:17.09.1-ce-git
# steps:
# - checkout
# - setup_remote_docker
# - *restore-cache
# - run: npm cache clear --force
# - run:
# name: Update NPM version
# command: 'sudo npm install -g npm@latest'
# - *install-deps
# - save_cache:
# key: v1-dependencies-{{ checksum "package.json" }}
# paths:
# - ./node_modules

# deploy:
# machine:
# enabled: true
# working_directory: ~/sharinghub/backend
# steps:
# - add_ssh_keys:
# fingerprints:
# - '39:84:cb:5e:ca:8e:c1:71:f6:19:ad:0c:bc:0f:78:21'
# - run:
# name: Deploy via ssh
# command: |
# echo Starting to deploy server
# ssh -v $SSH_USER@$SSH_HOST 'cd sharinghub/backend && git checkout develop && git pull && chmod 777 ./deploy.sh && ./deploy.sh'
# workflows:
# version: 2
# build-and-deploy:
# jobs:
# - build
# - deploy:
# requires:
# - build
# filters:
# branches:
# only:
# - develop

0 comments on commit 99b5a8b

Please sign in to comment.