This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apiVersion: networking.k8s.io/v1 | |
kind: NetworkPolicy | |
metadata: | |
name: <external-access-name> | |
spec: | |
ingress: | |
- ports: | |
- port: 8080 | |
protocol: TCP | |
podSelector: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apiVersion: autoscaling/v1 | |
kind: HorizontalPodAutoscaler | |
metadata: | |
name: <ms-name> | |
namespace: default | |
spec: | |
maxReplicas: 6 | |
minReplicas: 2 | |
scaleTargetRef: | |
apiVersion: apps/v1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apiVersion: v1 | |
kind: ConfigMap | |
metadata: | |
name: <cm-name> | |
data: | |
spring_datasource_url: "jdbc:postgresql://<database-url>/<database>?currentSchema=<schema>" | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apiVersion: batch/v1 | |
kind: CronJob | |
metadata: | |
name: <cronjob-name> | |
spec: | |
schedule: <cronjob-schedule> | |
jobTemplate: | |
spec: | |
template: | |
spec: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apiVersion: extensions/v1beta1 | |
kind: Ingress | |
metadata: | |
annotations: | |
ingress.kubernetes.io/custom-response-headers: Access-Control-Allow-Origin:http://localhost:3000 | |
|| Access-Control-Allow-Methods:POST, GET, HEAD, OPTIONS, PUT, DELETE | |
ingress.kubernetes.io/enable-cors: "true" | |
kubernetes.io/ingress.class: traefik | |
traefik.frontend.rule.type: PathPrefixStrip | |
creationTimestamp: "2021-12-02T17:00:00Z" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
apiVersion: v1 | |
kind: Secret | |
metadata: | |
name: <secret-name> | |
type: Opaque | |
data: | |
<key>: <value> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Service | |
@AllArgsConstructor | |
public class SampleRabbitmqEventHandler implements EventHandler<SampleDomainEvent> { | |
private final SampleService service; | |
@RabbitListener( | |
bindings = @QueueBinding( | |
value = @Queue(value = QUEUE_NAME, durable = "true", | |
arguments = {@Argument( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.awt.*; | |
public class UnlockScreenApplication { | |
public static void main(String[] args) throws Exception { | |
Robot robot = new Robot(); | |
while (true) { | |
robot.delay(40000); | |
Point currentLocation = MouseInfo.getPointerInfo().getLocation(); |
OlderNewer