Skip to content

Instantly share code, notes, and snippets.

View Guneetgstar's full-sized avatar
💭
Contributing

Guneet Singh Guneetgstar

💭
Contributing
View GitHub Profile
@Guneetgstar
Guneetgstar / .ebextensions\https-instance-securitygroup.config
Last active August 14, 2023 09:57
Amazon Elastic Beanstalk with SSL (HTTPS) without a Load Balancer on Single Instanced EC2 Amazon Linux 2 Image (Java)
######
## See https://github.com/awsdocs/elastic-beanstalk-samples/tree/main/configuration-files/aws-provided/security-configuration for refrence.
# .ebextensions/https-instance-securitygroup.config
Resources:
sslSecurityGroupIngress:
Type: AWS::EC2::SecurityGroupIngress
Properties:
GroupId: {"Fn::GetAtt" : ["AWSEBSecurityGroup", "GroupId"]}
IpProtocol: tcp
ToPort: 443
@Guneetgstar
Guneetgstar / serverless.yaml
Last active September 8, 2020 06:52
Secure S3-CloudFront-Serverless config
service: a-stack-name
org: someOrg
provider:
name: aws
runtime: nodejs12.x
stackName: a-stack-name
resources:
Resources:
@Guneetgstar
Guneetgstar / SimpleRecyclerViewAdapter.java
Last active May 7, 2020 06:41
A Simple Generic Implementation of `RecyclerView.Adapter`.
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import androidx.annotation.LayoutRes;
import androidx.annotation.NonNull;
import androidx.core.util.Supplier;
import androidx.recyclerview.widget.RecyclerView;
import java.util.ArrayList;