WEB SERVICE FOR https://github.com/rolwyn/infrastructure
Name: Rolwyn Quadras, NUID - 001554737, Email - [email protected]
-
Clone the Organization Repo using
git clone
command followed by the SSH link using the terminalExample:
[email protected]:spring2022-csye6225/webservice.git
-
In the terminal run the
npm install
command -
After all the dependencies are installed, do
npm run dev
to run the application in a development environment. Usenpm run start
in production -
Use curl or send request using REST Client extension of VS code to run APIs
-
The server.js file is the entry file of the application
- Run
npm install
to install all dependencies - In terminal use the
npm run test
command to run tests using Jest - All test files are located inside test folder
- The CI script is located in
.github/workflows/ci.yml
file - Pushing the code to forked remote branch will trigger a workflow. Use the
Actions
tab to check running workflow - A pull request to Upstream branch will also trigger a workflow
Packer init command to install plugins
packer init application-ami.pkr.hcl
Packer validate command
packer validate -var-file="variables.pkrvars.hcl" application-ami.pkr.hcl
Packer build command
packer build -var-file="variables.pkrvars.hcl" application-ami.pkr.hcl
Delete AMI and Snapshot
- aws ec2 deregister-image --image-id
<YOUR-IMAGE-ID>
- aws ec2 delete-snapshot --snapshot-id
<YOUR-SNAPSHOT-ID>