apt update && apt upgrade -y
curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | apt-key add -
cat <<EOF > /etc/apt/sources.list.d/kubernetes.list
deb http://apt.kubernetes.io/ kubernetes-xenial main
EOF
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
// Algoritmos de filtragem colaborativa | |
Task BMF_F1 = new Task("BiasedMatrixFactorization-F1.out", "../../MyMediaLite-3.10/bin/rating_prediction --prediction-file=Predictions/F1/BiasedMatrixFactorization.txt --prediction-line={0},{1},{2},0 --training-file=BD/Sample2345.txt --test-file=BD/Sample1.txt --recommender=BiasedMatrixFactorization --recommender-options=\"num_factors=14 bias_reg=0.042 frequency_regularization=False learn_rate=0.064 num_iter=32 bold_driver=True\" > ../run/out/bc/predictionsCF/BiasedMatrixFactorization-F1.out"); | |
Task BMF_F2 = new Task("BiasedMatrixFactorization-F2.out", "../../MyMediaLite-3.10/bin/rating_prediction --prediction-file=Predictions/F2/BiasedMatrixFactorization.txt --prediction-line={0},{1},{2},0 --training-file=BD/Sample1345.txt --test-file=BD/Sample2.txt --recommender=BiasedMatrixFactorization --recommender-options=\"num_factors=14 bias_reg=0.042 frequency_regularization=False learn_rate=0.064 num_iter=32 bold_driver=True\" > ../run/out/bc/predictionsCF/BiasedMatrixFactoriz |
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
minikube stop; minikube delete && | |
docker stop $(docker ps -aq) && | |
rm -rf ~/.kube ~/.minikube && | |
sudo rm -rf /usr/local/bin/localkube /usr/local/bin/minikube && | |
launchctl stop '*kubelet*.mount' && | |
launchctl stop localkube.service && | |
launchctl disable localkube.service && | |
sudo rm -rf /etc/kubernetes/ && | |
docker system prune -af --volumes |
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
Você deve criar localmente na sua máquina Linux um simples sistema de CI/CD | |
utilizando a tecnologia de containers. Você deve criar um cluster local de | |
Kubernetes, neste cluster você deve fazer o deploy de um VCS e um servidor de | |
automação de builds que serão as peças principais de um sistema de CI/CD. Uma | |
vez criado esse sistema de CI/CD ele deve ser capaz de construir simples | |
containers com uma aplicação Java e enviar a imagem criada para um Registry. | |
Uma vez com essa imagem no Registry o sistema deve conseguir fazer o deploy | |
dessa aplicação no cluster e quando houver a criação de novas versões da imagem | |
a aplicação deve se atualizar para usar a imagem mais nova. Recomendamos a | |
criação de uma simples aplicação java que fica apenas escrevendo em loop infinito |
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
#include <pthread.h> | |
#include <stdio.h> | |
#include <unistd.h> | |
#include <assert.h> | |
/* Compile like this: | |
gcc --std=c99 -lpthread cond.c -o cond |
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
// quick and dirty snippet to creates a gitlab markdown table of contents for a README.md page | |
// preview gitlab page and paste in browser console | |
var str = ""; | |
$('.file-content') | |
.find('h1, h2, h3, h4, h5, h6, h7') | |
.each((i, node) => { | |
// node.tagName is H1 H2... | |
let indent = Number(node.tagName[1]) - 1; | |
// markdown mested lists are | |
// - xxx |
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
require('prompt-sync')() |
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
entrada = require('prompt-sync')(); |
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
❯ cat /etc/os-release | |
NAME="Ubuntu" | |
VERSION="20.04.1 LTS (Focal Fossa)" | |
ID=ubuntu | |
ID_LIKE=debian | |
PRETTY_NAME="Ubuntu 20.04.1 LTS" | |
VERSION_ID="20.04" | |
HOME_URL="https://www.ubuntu.com/" | |
SUPPORT_URL="https://help.ubuntu.com/" | |
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/" |
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 { Avatar, Button as MuiButton, Typography } from "@material-ui/core"; | |
import { grey } from "@material-ui/core/colors"; | |
import { | |
CloudUpload as MuiCloudUpload, | |
Delete as MuiDelete, | |
} from "@material-ui/icons"; | |
import { spacing } from "@material-ui/system"; | |
import React, { createRef, useState } from "react"; | |
import styled from "styled-components"; |
OlderNewer