Skip to content

Instantly share code, notes, and snippets.

View maxgfr's full-sized avatar
🎯
Focusing

Maxime Golfier maxgfr

🎯
Focusing
View GitHub Profile
@maxgfr
maxgfr / basic_cnn.py
Last active March 8, 2018 09:47
CNN on tensorflow
"""
From Jeremie :)
"""
from __future__ import print_function
import numpy
import tensorflow as tf
rng = numpy.random
@maxgfr
maxgfr / data_loaded_tensorflow.py
Last active March 8, 2018 09:47
Load data on tensorflow
"""
From Jeremie :)
"""
from __future__ import print_function
import numpy
import tensorflow as tf
rng = numpy.random
@maxgfr
maxgfr / kubernetes_cloudant.yaml
Last active March 21, 2018 10:11
Kubernetes & Cloudant
kind: PersistentVolume
apiVersion: v1
metadata:
name: cloudant-pv
labels:
app: microprofile-app
spec:
capacity:
storage: 4Gi
accessModes:
@maxgfr
maxgfr / laradock.md
Last active September 13, 2022 04:29
Laradock with Laravel / Laravel with Laradock

Laradock X Laravel

Initialize

1) In .env of laravel app, add :

DB_HOST=mysql

REDIS_HOST=redis
@maxgfr
maxgfr / 0-install.md
Last active January 2, 2022 22:39
Hyperledger X Ubuntu : Single Organization

Hyperledger X Ubuntu : Single Organization

AFTER A REBOOT

sudo reboot
ssh -i ....
nvm use 8
sudo systemctl restart docker
sudo ~/fabric-dev-servers/./startFabric.sh 
cd ~/blockchain-container/dist/
@maxgfr
maxgfr / twitch_react_native.js
Created November 27, 2018 16:01
Twitch library using react-native (expo)
import { AsyncStorage } from 'react-native';
import { WebBrowser, AuthSession } from 'expo';
import {
TWITCH_CLIENT_ID,
TWITCH_SECRET_ID
} from 'react-native-dotenv'
const TWITCH_REDIRECT_URI= AuthSession.getRedirectUrl();
const TWITCH_BASE_URL="https://api.twitch.tv/kraken/";
@maxgfr
maxgfr / path.md
Last active January 2, 2022 22:32
Add to path to mac os

Add path to mac os

echo $PATH;

If we want to add $HOME/.composer/vendor/bin to the path, we should run :

export PATH=$PATH:$HOME/.composer/vendor/bin  
@maxgfr
maxgfr / kafka_mac_os_x.md
Last active May 22, 2019 14:38
Kafka on mac os X

Kafka on mac os X

brew install kafka
brew install zookeeper
zookeeper-server-start /usr/local/etc/kafka/zookeeper.properties
kafka-server-start /usr/local/etc/kafka/server.properties
kafka-topics --create --zookeeper localhost:2181 --replication-factor 1 --partitions 1 --topic test
kafka-console-producer --broker-list localhost:9092 --topic test
kafka-console-consumer --bootstrap-server localhost:9092 --topic test --from-beginning
@maxgfr
maxgfr / remove_all_docker_container.md
Last active January 2, 2022 22:31
Remove all docker container

Remove all docker container

docker system prune
# Stop all containers
docker stop `docker ps -qa`
@maxgfr
maxgfr / configure_libnfc.md
Last active December 2, 2022 22:17
How to configure libnfc ACS ACR122U on Mac OS X ?

Configure libnfc ACS ACR122U on Mac OS X

git clone https://github.com/nfc-tools/libnfc.git
cd libnfc 
autoreconf -is 
./configure --with-drivers=acr122_pcsc
make install