This file contains hidden or 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
| #!/usr/bin/env ruby | |
| # frozen_string_literal: true | |
| require 'net/http' | |
| require 'json' | |
| require 'date' | |
| # Russian Calendar Holidays Fetcher | |
| class RussianCalendarService | |
| BASE_ENDPOINT = 'https://datazen.katren.ru/calendar/day/' |
This file contains hidden or 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
| { | |
| "Version": "2012-10-17", | |
| "Statement": [ | |
| { | |
| "Sid": "ECRPushAccess", | |
| "Effect": "Allow", | |
| "Action": [ | |
| "ecr:GetDownloadUrlForLayer", | |
| "ecr:BatchGetImage", | |
| "ecr:CompleteLayerUpload", |
This file contains hidden or 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
| concurrent = 1 | |
| check_interval = 0 | |
| [session_server] | |
| session_timeout = 1800 | |
| [[runners]] | |
| name = "docker" | |
| url = "<GITLAB_INSTANCE_URL>" | |
| token = "<GITLAB_RUNNER_ACCESS_TOKEN" |
This file contains hidden or 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
| FROM maven:3.6-jdk-13 as BUILD | |
| COPY . /usr/src/app | |
| RUN mvn -Dmaven.repo.local=/root/m2 --batch-mode -f /usr/src/app/pom.xml clean install | |
| FROM openjdk:13-slim | |
| RUN mkdir /app && mkdir /app/lib && mkdir /app/config | |
| WORKDIR /app |
This file contains hidden or 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
| /** | |
| * Deep diff between two object, using lodash | |
| * @param {Object} object Object compared | |
| * @param {Object} base Object to compare with | |
| * @return {Object} Return a new object who represent the diff | |
| */ | |
| function difference(object, base) { | |
| function changes(object, base) { | |
| return _.transform(object, function(result, value, key) { | |
| if (!_.isEqual(value, base[key])) { |
This file contains hidden or 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
| FROM python:3.5.2 | |
| ENV TZ=Asia/Shanghai | |
| RUN apt-get update \ | |
| && apt-get install -y cron \ | |
| && apt-get autoremove -y | |
| COPY ./cronpy /etc/cron.d/cronpy | |
| CMD ["cron", "-f"] |
This file contains hidden or 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.io.IOException; | |
| import java.nio.file.Files; | |
| import java.nio.file.Paths; | |
| import java.util.Arrays; | |
| import java.util.function.Function; | |
| import java.util.stream.Collectors; | |
| import java.util.stream.Stream; | |
| public class TopTen { |
This file contains hidden or 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
| FROM debian:stable | |
| LABEL maintainer="Anton Kozik" | |
| ENV LAST_UPDATE=2019-01-03 | |
| ARG KOPS_VERSION=1.11.0 | |
| ARG KUBECTL_VERSION=1.11.6 | |
| ARG AWSCLI_VERSION=1.16.82 | |
| RUN apt-get update -qq |
This file contains hidden or 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
| function remove-docker-containers | |
| echo "Stop running shit" | |
| docker stop (docker ps -q) | |
| echo "Remove the whale shit" | |
| docker rm (docker ps -a -q) | |
| end | |
| function remove-docker-images | |
| remove-docker-containers |
This file contains hidden or 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
| module.exports.Link = class Link { | |
| constructor(x,y,range) { | |
| this.x = x; | |
| this.y = y; | |
| this.range = range; | |
| } | |
| } |
NewerOlder