{"id":17892678,"url":"https://github.com/ynigoreyes/quickdeploy","last_synced_at":"2025-04-03T03:43:43.451Z","repository":{"id":70432660,"uuid":"139199734","full_name":"ynigoreyes/QuickDeploy","owner":"ynigoreyes","description":"Personal CI/CD to be cloned into cloud provider","archived":false,"fork":false,"pushed_at":"2018-06-30T06:39:09.000Z","size":10,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-08T17:45:20.901Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ynigoreyes.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-06-29T22:00:06.000Z","updated_at":"2022-11-27T23:26:30.000Z","dependencies_parsed_at":"2023-02-23T22:45:52.215Z","dependency_job_id":null,"html_url":"https://github.com/ynigoreyes/QuickDeploy","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ynigoreyes%2FQuickDeploy","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ynigoreyes%2FQuickDeploy/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ynigoreyes%2FQuickDeploy/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ynigoreyes%2FQuickDeploy/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ynigoreyes","download_url":"https://codeload.github.com/ynigoreyes/QuickDeploy/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246933356,"owners_count":20857052,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-28T14:40:48.492Z","updated_at":"2025-04-03T03:43:43.430Z","avatar_url":"https://github.com/ynigoreyes.png","language":"JavaScript","readme":"### Deployment server\n\n## Requirements\n##### DISCLAIMER: This is a very specific CI/CD pipeline and has been designed for my personal work flow\n  1) Cloud Provider\n  2) Knowledge with docker-compose / Docker\n  3) Node\n  4) An app that depends on dotenv and a Dockfile with ARGS\n\n## How to use\n  1) Clone repo into root of server and install dependencies\n  ```\n  $ git clone https://github.com/ynigoreyes/QuickDeploy.git\n  $ cd QuickDeploy\n  $ npm install\n  ```\n\n  2) Install foreverjs globally\n  ```\n  $ npm install -g forever\n  ```\n\n  3) Run script as a process\n  ```\n  $ npm run start-proc\n  ```\n\n  4) Create a .env file that will be injected into container\n  ```\n  $ touch .env\n\n  // .env\n\n  msg=\"In Production!\"\n  ```\n\n  5) Navigate out of repo and create a docker-compose file\n  ```\n  $ cd \u0026\u0026 touch docker-compose.yml\n\n  ```\n  ```\n  // Inside the docker-compose.yml\n\n  version: '2'\n  services:\n\n    app:\n      env_file:\n        - .env // Whatever environment variables to be used in container\n\n      image: \u003crepository\u003e\n\n      restart:\n        - always\n\n      ports:\n        - 80:80 // Ports to open\n  ```\n  ```\n  // The Docker image the docker-composer.yml pulls\n\n  FROM node:10-alpine\n\n  WORKDIR /app\n\n  COPY . /app\n\n  RUN npm install --prod --silent\n\n  ARG msg='Hello World!' // this is where the env variables get injected\n\n  EXPOSE 80\n\n  CMD [ \"npm\", \"start\" ]\n  ```\n\n## Trigger\nThe trigger for this deployment is a simple http request to a port on the server. It defaults to port 8080.\nI use a curl script within the deploy stage of travis-ci\n```\ncurl \u003cendpoint\u003e:8080/\n```\nto signal my EC2 instance to rebuild the images. This is not very secure as there is no way (yet) of authenticating who is hitting the endpoint to restart the server.\n\n## Commands\n  ```\n  $ npm run start-proc\n  // Runs the server as a proccess\n  ```\n  ```\n  $ npm run start\n  // Runs the server normally\n  ```\n  ```\n  $ npm run kill\n  // Kills the proccess and the port it runs on\n  ```","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fynigoreyes%2Fquickdeploy","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fynigoreyes%2Fquickdeploy","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fynigoreyes%2Fquickdeploy/lists"}