Browse Source

fix: prettier linter

pull/2748/merge
KostLinux 2 weeks ago committed by Zouhair AMAZZAL
parent
commit
151aaffad6
  1. 1
      employment-tasks/devops/basic-api/README.md
  2. 17
      employment-tasks/devops/notbad-task/README.md
  3. 3
      employment-tasks/devops/notbad-task/keycloak/README.md
  4. 9
      subjects/devops/serverless/README.md

1
employment-tasks/devops/basic-api/README.md

@ -7,6 +7,7 @@ some basic validation against an expected message format and content,
and then puts that payload into a queue of your choice or a file. and then puts that payload into a queue of your choice or a file.
Example valid payload: Example valid payload:
```json ```json
{ {
"ts": "1530228282", "ts": "1530228282",

17
employment-tasks/devops/notbad-task/README.md

@ -5,19 +5,20 @@ Look at the following tasks and estimate how much time you will spend on them.
## Preconditions ## Preconditions
### Technical & Knowledge ### Technical & Knowledge
You need at least: You need at least:
* Experience with AWS stack - Experience with AWS stack
* Experience with CI/CD - Experience with CI/CD
* Experience with Bash scripts - Experience with Bash scripts
* Experience in at least one programming language (Java, Python, PHP, Perl, etc.) - Experience in at least one programming language (Java, Python, PHP, Perl, etc.)
* A text editor of your choice - A text editor of your choice
## The tasks ## The tasks
1) We have a Terraform securitygroups.tf file. Every time Terraform runs, it says the security group in that file will be updated in place. Find a way to prevent this.
2) Look into keycloak folder. What can be improved? 1. We have a Terraform securitygroups.tf file. Every time Terraform runs, it says the security group in that file will be updated in place. Find a way to prevent this.
3) Provide infrastructure and create CI/CD with a web app that will listen to 8089 port and return "ReallyNotBad" string when POST request contains header "NotBad" with value "true", eg. `curl -X POST -H "NotBad: true" https://someurl:8089/` should return "ReallyNotBad". 2. Look into keycloak folder. What can be improved?
3. Provide infrastructure and create CI/CD with a web app that will listen to 8089 port and return "ReallyNotBad" string when POST request contains header "NotBad" with value "true", eg. `curl -X POST -H "NotBad: true" https://someurl:8089/` should return "ReallyNotBad".
Use any technology you want to deploy the application to AWS. It can be Ansible, Terraform, etc. or a combination of some of them. Use any technology you want to deploy the application to AWS. It can be Ansible, Terraform, etc. or a combination of some of them.
Hint: https://aws.amazon.com/free/ Hint: https://aws.amazon.com/free/

3
employment-tasks/devops/notbad-task/keycloak/README.md

@ -1,6 +1,7 @@
# alpeso-test # alpeso-test
alpeso-test alpeso-test
## How-to use ## How-to use
Simple run ```./keycloack.sh test test1``` where test = keycloak user id and test1 = keycloak client secret. Simple run `./keycloack.sh test test1` where test = keycloak user id and test1 = keycloak client secret.

9
subjects/devops/serverless/README.md

@ -15,7 +15,7 @@ Create a simple Slack bot using:
The task is separated into multiple different levels. The levels are ordered by complexity. You can choose the level that you feel most comfortable with. The task is separated into multiple different levels. The levels are ordered by complexity. You can choose the level that you feel most comfortable with.
## Level 0: Basic Lambda Function hosted via Serverless** ## Level 0: Basic Lambda Function hosted via Serverless
**1. Create Slack Bot** **1. Create Slack Bot**
@ -54,7 +54,7 @@ AWS Eventbridge should trigger lambda function every month on the 1st day of the
**Note** Before hosting, you need to ensure that the bot is written in a way that it can be hosted on AWS Lambda. You can look at the example [here](https://github.com/KostLinux/aws-incident-manager-notifier/blob/56d52e90f8a14e689e7d2a1c7ee44590de5af2f5/main.go#L158). **Note** Before hosting, you need to ensure that the bot is written in a way that it can be hosted on AWS Lambda. You can look at the example [here](https://github.com/KostLinux/aws-incident-manager-notifier/blob/56d52e90f8a14e689e7d2a1c7ee44590de5af2f5/main.go#L158).
## Level 1: Basic Lambda Function automation via Cloudformation** ## Level 1: Basic Lambda Function automation via Cloudformation
**1. Repeat the 1st and 2nd step from Level 0** **1. Repeat the 1st and 2nd step from Level 0**
@ -70,7 +70,7 @@ Cloudformation is Infrastructure As Code (IaC) tool used to automate the provisi
Write cloudformation template with parameters (variables) `SlackWebhookUrl`, `Amount`, `IbanNumber`. The template should automatically provision the Slackbot based on architecture mentioned in [Level 0](#level-0-basic-lambda-function-hosted-via-serverless) step 3. Write cloudformation template with parameters (variables) `SlackWebhookUrl`, `Amount`, `IbanNumber`. The template should automatically provision the Slackbot based on architecture mentioned in [Level 0](#level-0-basic-lambda-function-hosted-via-serverless) step 3.
## Level 2: Basic Lambda Function automation via Basic Terraform with Local State** ## Level 2: Basic Lambda Function automation via Basic Terraform with Local State\*\*
Terraform is an Infrastructure As Code (IaC) tool used to automate the provisioning of resources inside different SaaS solutions and Cloud providers. It uses HCL syntax, which is easy maintainable. The main problem of terraform is that you need to know, how everything works under the hood (e.g. IAM roles, policies, serverless platforms etc). Terraform is an Infrastructure As Code (IaC) tool used to automate the provisioning of resources inside different SaaS solutions and Cloud providers. It uses HCL syntax, which is easy maintainable. The main problem of terraform is that you need to know, how everything works under the hood (e.g. IAM roles, policies, serverless platforms etc).
@ -94,7 +94,7 @@ Create a slack bot, that sends a reminder to slack channel. Write integration te
At this level you can use local state for terraform, no modules needed to write. At this level you can use local state for terraform, no modules needed to write.
## Level 3: Basic Lambda Function automation via Terraform Module with Remote S3 State (advanced)** ## Level 3: Basic Lambda Function automation via Terraform Module with Remote S3 State (advanced)\*\*
In a DevOps world, mostly we use remote state for terraform. The main reason is that we can share the state with other team members and we can easily manage the state of the infrastructure. Although it is a bit more complex to set up, it allows you to avoid issues when someone even removes the state file, cause S3 has versioning turned on. In a DevOps world, mostly we use remote state for terraform. The main reason is that we can share the state with other team members and we can easily manage the state of the infrastructure. Although it is a bit more complex to set up, it allows you to avoid issues when someone even removes the state file, cause S3 has versioning turned on.
@ -150,7 +150,6 @@ module "slack_bot" {
} }
``` ```
## Helpful commands ## Helpful commands
- `serverless deploy` - Deploy the serverless application - `serverless deploy` - Deploy the serverless application

Loading…
Cancel
Save