Skip to content

Instantly share code, notes, and snippets.

@ahunigel
ahunigel / nginx-vhost
Created August 13, 2019 03:02 — forked from Foxandxss/nginx-vhost
Nginx vhost configuration for proxying requests to an API running on a different port. Easy to avoid CORS / JSONP
upstream api_node_js {
server 127.0.0.1:8080;
}
server {
listen 80 default_server;
listen [::]:80 default_server ipv6only=on;
root /var/www/my-kickass-domain/public_html;
index index.html index.htm;
@ahunigel
ahunigel / build.gradle
Last active May 9, 2019 04:21
spring gradle bootRun classpath too long
buildscript {
ext {
springBootVersion = '2.0.1.RELEASE'
ciBuild = System.getenv()['CI'] ? true : false
jenkinsCI = System.getenv()['JENKINS_URL'] ? true : false
gitlabCI = System.getenv()['GITLAB_CI'] ? true : false
intranetCI = jenkinsCI || gitlabCI
nexusUrl = "http://10.161.92.100:8081/nexus"
}
repositories {
@ahunigel
ahunigel / git-force-push.sh
Last active May 9, 2019 18:03 — forked from wojtha/gist:1281288
Git - force push to remote
# Force push changes to the remote repository after "git commit --amend", "git rebase" or similar
#
# !!! WARNING: YOU ARE REWRITING THE HISTORY, DO IT ONLY IF YOU'RE THE ONLY COMMITER !!!
#
# See http://stackoverflow.com/questions/253055/how-do-i-push-amended-commit-to-the-remote-git-repo/253726#253726
git push origin +master:master