Skip to content

Instantly share code, notes, and snippets.

@levlas
levlas / output_of_ps_aux
Created August 24, 2017 16:10
nexus server process
/opt/java/bin/java -server -Dinstall4j.jvmDir=/opt/java
-Dexe4j.moduleName=/opt/sonatype/nexus/bin/nexus -XX:+UnlockDiagnosticVMOptions -Dinstall4j.launcherId=245
-Dinstall4j.swt=false -Di4jv=0 -Di4jv=0 -Di4jv=0 -Di4jv=0 -Di4jv=0 -Xms4G -Xmx4G -XX:MaxDirectMemorySize=18G
-Duser.timezone=Europe/Budapest -XX:MaxDirectMemorySize=2G -XX:+UnlockDiagnosticVMOptions -XX:+UnsyncloadClass...
@levlas
levlas / Dockerfile.custom
Last active August 18, 2017 19:26
nexus docker volume ownership problem
FROM sonatype/nexus3:3.5.0
ENV OLD_AVON_BLOBS=/app/sonatype-work/avon-maps/blobs \
NEW_AVON_BLOBS=/nexus-data/blobs \
CONFIG_EXPORT=/nexus-data/config-export
USER root
RUN mkdir -p ${OLD_AVON_BLOBS} \
&& ln -s ${NEW_AVON_BLOBS}/avon-maps ${OLD_AVON_BLOBS}/avon-maps \
&& chown -R nexus:nexus ${OLD_AVON_BLOBS}
@levlas
levlas / pam.d_lightdm
Created August 4, 2017 15:36
config file editing to fix X session issue
George Vasileiou (gvasileiou) wrote on 2017-06-30: #11
I had the same problem in elementary OS Loki. The same messages as it is described above. Those bug was affecting my login time in the pantheon graphical environment so I came out with a very quickie work - arround. I edited and I delete the lines which have pam_kwallet.so and pam_kwallet5.so. Make a backup before you try it.
/etc/pam.d/lightdm
#%PAM-1.0
auth requisite pam_nologin.so
auth sufficient pam_succeed_if.so user ingroup nopasswdlogin
@include common-auth
auth optional pam_gnome_keyring.so
@levlas
levlas / sources_list_add
Created August 4, 2017 11:01
I have to add these lines to /etc/apt/sources.list with Ansible
#------------------------------------------------------------------------------#
# OFFICIAL UBUNTU REPOS #
#------------------------------------------------------------------------------#
###### Ubuntu Main Repos
deb http://hu.archive.ubuntu.com/ubuntu/ xenial main restricted universe multiverse
###### Ubuntu Update Repos
deb http://hu.archive.ubuntu.com/ubuntu/ xenial-security main restricted universe multiverse
@levlas
levlas / Gemfile
Created February 2, 2017 11:45
my Gemfile
source 'https://rubygems.org'
gem 'github-pages', group: :jekyll_plugins
group :jekyll_plugins do
gem 'octopress-multilingual'
end
@levlas
levlas / bundle_output
Created February 2, 2017 07:47
output of bundle exec jekyll serve after add octopress-multilingual gem
MacBook:levlas.github.io lev$ bundle exec jekyll serve
bundler: failed to load command: jekyll (/usr/local/bin/jekyll)
Bundler::GemRequireError: There was an error while trying to load the gem 'octopress-multilingual'.
Gem Load Error is: undefined method `template' for class `Jekyll::Post'
Backtrace for gem load error is:
/usr/local/lib/ruby/gems/2.4.0/gems/octopress-multilingual-1.2.0/lib/octopress-multilingual/jekyll.rb:85:in `<class:Post>'
/usr/local/lib/ruby/gems/2.4.0/gems/octopress-multilingual-1.2.0/lib/octopress-multilingual/jekyll.rb:84:in `<module:Jekyll>'
/usr/local/lib/ruby/gems/2.4.0/gems/octopress-multilingual-1.2.0/lib/octopress-multilingual/jekyll.rb:1:in `<top (required)>'
/usr/local/lib/ruby/gems/2.4.0/gems/octopress-multilingual-1.2.0/lib/octopress-multilingual.rb:9:in `require'
/usr/local/lib/ruby/gems/2.4.0/gems/octopress-multilingual-1.2.0/lib/octopress-multilingual.rb:9:in `<top (required)>'
@levlas
levlas / preloader_part.txt
Created February 2, 2017 04:02
part of Alcatel 8079 scatter file
- partition_index: SYS0
partition_name: PRELOADER
file_name: preloader_pixi3_10.bin
is_download: true
type: SV5_BL_BIN
linear_start_addr: 0
physical_start_addr: 0x0
partition_size: 0x40000
region: EMMC_BOOT_1
storage: HW_STORAGE_EMMC
{
"me":"Do your project!",
"St. Jerome":"Good, better, best. Never let it rest. 'Til your good is better and your better is best.",
"Francis of Assisi":"If God can work through me, he can work through anyone.",
"Pope John Paul II":"Freedom consists not in doing what we like, but in having the right to do what we ought.",
"St. Pio of Pietrelcino":"Pray, Hope, and Don't Worry",
"St. Catherine of Siena":"Be who God meant you to be and you will set the world on fire!",
"St. John Paul II":"Life with Christ is a wonderful adventure."
}
@levlas
levlas / diff_2array_v1.js
Last active April 13, 2016 00:06
Diff Arrays algorithm
function diffArray(arr1, arr2) {
var newArr = [];
var intersArr = [];
newArr = arr1.filter(function(elem) {
if(arr2.indexOf(elem) === -1) {
return true;
}
else {
intersArr.push(elem);
var d = new Date(2012, 2, 23, 23, 0, 0, 0);
d.setUTCDate(d.getDate() + 3);
console.log(d.toLocaleString());