{"id":18653369,"url":"https://github.com/fullstackacademy/boilermaker","last_synced_at":"2025-05-16T18:06:35.354Z","repository":{"id":17491703,"uuid":"82096379","full_name":"FullstackAcademy/boilermaker","owner":"FullstackAcademy","description":"Code scaffold for projects","archived":false,"fork":false,"pushed_at":"2023-06-12T18:48:59.000Z","size":3576,"stargazers_count":214,"open_issues_count":58,"forks_count":704,"subscribers_count":14,"default_branch":"main","last_synced_at":"2025-05-16T18:06:17.358Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://www.youtube.com/watch?v=7bLSuTHH4Ag\u0026list=PLx0iOsdUOUmn7D5XL4mRUftn8hvAJGs8H","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/FullstackAcademy.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":".github/CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2017-02-15T19:09:45.000Z","updated_at":"2025-04-04T14:07:47.000Z","dependencies_parsed_at":"2023-02-15T04:01:50.677Z","dependency_job_id":"68ccd2f5-1524-4efe-bfa2-ec19e14ace46","html_url":"https://github.com/FullstackAcademy/boilermaker","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/FullstackAcademy%2Fboilermaker","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FullstackAcademy%2Fboilermaker/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FullstackAcademy%2Fboilermaker/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/FullstackAcademy%2Fboilermaker/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/FullstackAcademy","download_url":"https://codeload.github.com/FullstackAcademy/boilermaker/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254582904,"owners_count":22095518,"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-11-07T07:11:21.271Z","updated_at":"2025-05-16T18:06:35.304Z","avatar_url":"https://github.com/FullstackAcademy.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Boilermaker\n\n_Good things come in pairs_\n\nLooking to mix up a backend with `express`/`sequelize` and a frontend with\n`react`/`redux`? That's `boilermaker`!\n\nFollow along with the boilerplate workshop to make your own! This canonical\nversion can serve as a reference, or a starting point. For an in depth\ndiscussion into the code that makes up this repository, see the\n[Boilermaker Guided Tour][boilermaker-yt]\n\n[boilermaker-yt]: https://www.youtube.com/playlist?list=PLx0iOsdUOUmn7D5XL4mRUftn8hvAJGs8H\n\n## Setup\n\nTo use this as boilerplate, you'll need to take the following steps:\n\n* Don't fork or clone this repo! Instead, create a new, empty\n  directory on your machine and `git init` (or create an empty repo on\n  Github and clone it to your local machine)\n* Run the following commands:\n\n```\ngit remote add boilermaker https://github.com/FullstackAcademy/boilermaker.git\ngit fetch boilermaker\ngit merge boilermaker/master\n```\n\nWhy did we do that? Because every once in a while, `boilermaker` may\nbe updated with additional features or bug fixes, and you can easily\nget those changes from now on by entering:\n\n```\ngit fetch boilermaker\ngit merge boilermaker/master\n```\n\n## Customize\n\nNow that you've got the code, follow these steps to get acclimated:\n\n* Update project name and description in `package.json` and\n  `.travis.yml` files\n* `npm install`\n* Create two postgres databases (`MY_APP_NAME` should match the `name`\n  parameter in `package.json`):\n\n```\nexport MY_APP_NAME=boilermaker\ncreatedb $MY_APP_NAME\ncreatedb $MY_APP_NAME-test\n```\n\n* By default, running `npm test` will use `boilermaker-test`, while\n  regular development uses `boilermaker`\n* Create a file called `secrets.js` in the project root\n  * This file is listed in `.gitignore`, and will _only_ be required\n    in your _development_ environment\n  * Its purpose is to attach the secret environment variables that you\n    will use while developing\n  * However, it's **very** important that you **not** push it to\n    Github! Otherwise, _prying eyes_ will find your secret API keys!\n  * It might look like this:\n\n```\nprocess.env.GOOGLE_CLIENT_ID = 'hush hush'\nprocess.env.GOOGLE_CLIENT_SECRET = 'pretty secret'\nprocess.env.GOOGLE_CALLBACK = '/auth/google/callback'\n```\n\n### OAuth\n\n* To use OAuth with Google, complete the steps above with a real client\n  ID and client secret supplied from Google\n  * You can get them from the [Google APIs dashboard][google-apis].\n\n[google-apis]: https://console.developers.google.com/apis/credentials\n\n## Linting\n\nLinters are fundamental to any project. They ensure that your code\nhas a consistent style, which is critical to writing readable code.\n\nBoilermaker comes with a working linter (ESLint, with\n`eslint-config-fullstack`) \"out of the box.\" However, everyone has\ntheir own style, so we recommend that you and your team work out yours\nand stick to it. Any linter rule that you object to can be \"turned\noff\" in `.eslintrc.json`. You may also choose an entirely different\nconfig if you don't like ours:\n\n* [Standard style guide](https://standardjs.com/)\n* [Airbnb style guide](https://github.com/airbnb/javascript)\n* [Google style guide](https://google.github.io/styleguide/jsguide.html)\n\n## Start\n\nRunning `npm run start-dev` will make great things happen!\n\nIf you want to run the server and/or `webpack` separately, you can also\n`npm run start-server` and `npm run build-client`.\n\nFrom there, just follow your bliss.\n\n## Deployment\n\nReady to go world wide? Here's a guide to deployment! There are two\nsupported ways to deploy in Boilermaker:\n\n* automatically, via continuous deployment with Travis.\n* \"manually\", from your local machine via the `deploy` script.\n\nEither way, you'll need to set up your deployment server to start.\nThe steps below are also covered in the CI/CD workshop.\n\n### Heroku\n\n1.  Set up the [Heroku command line tools][heroku-cli]\n2.  `heroku login`\n3.  Add a git remote for heroku:\n\n[heroku-cli]: https://devcenter.heroku.com/articles/heroku-cli\n\n* **If you are creating a new app...**\n\n  1.  `heroku create` or `heroku create your-app-name` if you have a\n      name in mind.\n  2.  `heroku addons:create heroku-postgresql:hobby-dev` to add\n      (\"provision\") a postgres database to your heroku dyno\n\n* **If you already have a Heroku app...**\n\n  1.  `heroku git:remote your-app-name` You'll need to be a\n      collaborator on the app.\n\n### Travis\n\n_**NOTE**_ that this step assumes that Travis-CI is already testing your code.\nContinuous Integration is not about testing per se – it's about _continuously\nintegrating_ your changes into the live application, instead of periodically\n_releasing_ new versions. CI tools can not only test your code, but then\nautomatically deploy your app. This is known as Continuous Deployment.\nBoilermaker comes with a `.travis.yml` configuration almost ready for\ncontinuous deployment; follow these steps to the job.\n\n1.  Run the following commands to create a new branch:\n\n```\ngit checkout master\ngit pull\ngit checkout -b f/travis-deploy\n```\n\n2.  Run the following script to finish configuring `travis.yml` :\n    `npm run heroku-token`\n    This will use your `heroku` CLI (that you configured previously, if\n    not then see [above](#Heroku)) to generate an authentication token. It\n    will then use `openssl` to encrypt this token using a public key that\n    Travis has generated for you. It will then update your `.travis.yml`\n    file with the encrypted value to be sent with the `secure` key under\n    the `api_key`.\n3.  Run the following commands to commit these changes\n\n```\ngit add .travis.yml\ngit commit -m 'travis: activate deployment'\ngit push -u origin f/travis-deploy\n```\n\n4.  Make a Pull Request for the new branch, get it approved, and merge it into\n    the master branch.\n\n_**NOTE**_ that this script depends on your local `origin` Git remote matching\nyour GitHub URL, and your local `heroku` remote matching the name of your\nHeroku app. This is only an issue if you rename your GitHub organization,\nrepository name or Heroku app name. You can update these values using\n`git remote` and its related commands.\n\n#### Travis CLI\n\nThere is a procedure to complete the above steps by installing the official\n[Travis CLI tools][travis-cli]. This requires a recent Ruby, but this step\nshould not be, strictly speaking, necessary. Only explore this option when the\nabove has failed.\n\n[travis-cli]: https://github.com/travis-ci/travis.rb#installation\n\nThat's it! From now on, whenever `master` is updated on GitHub, Travis\nwill automatically push the app to Heroku for you.\n\n### Cody's own deploy script\n\nYour local copy of the application can be pushed up to Heroku at will,\nusing Boilermaker's handy deployment script:\n\n1.  Make sure that all your work is fully committed and merged into your\n    master branch on Github.\n2.  If you currently have an existing branch called \"deploy\", delete\n    it now (`git branch -d deploy`). We will use a dummy branch\n    with the name `deploy` (see below), so and the script below will error if a\n    branch with that name already exists.\n3.  `npm run deploy`\n    _ this will cause the following commands to happen in order:\n    _ `git checkout -b deploy`: checks out a new branch called\n    `deploy`. Note that the name `deploy` here is not magical, but it needs\n    to match the name of the branch we specify when we push to our `heroku`\n    remote.\n    _ `webpack -p`: webpack will run in \"production mode\"\n    _ `git add -f public/bundle.js public/bundle.js.map`: \"force\" add\n    these files which are listed in `.gitignore`.\n    _ `git commit --allow-empty -m 'Deploying'`: create a commit, even\n    if nothing changed\n    _ `git push --force heroku deploy:master`: push your local\n    `deploy` branch to the `master` branch on `heroku`\n    _ `git checkout master`: return to your master branch\n    _ `git branch -D deploy`: remove the deploy branch\n\nNow, you should be deployed!\n\nWhy do all of these steps? The big reason is because we don't want our\nproduction server to be cluttered up with dev dependencies like\n`webpack`, but at the same time we don't want our development\ngit-tracking to be cluttered with production build files like\n`bundle.js`! By doing these steps, we make sure our development and\nproduction environments both stay nice and clean!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffullstackacademy%2Fboilermaker","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffullstackacademy%2Fboilermaker","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffullstackacademy%2Fboilermaker/lists"}