Skip to content

Instantly share code, notes, and snippets.

View arcanisgk's full-sized avatar
🏦
looking for a job

Walter Nuñez arcanisgk

🏦
looking for a job
View GitHub Profile
192.168.1.12 avisistema-3.vh
192.168.1.12 avisistema-2.vh
@arcanisgk
arcanisgk / docker-script.ps1
Last active February 27, 2024 20:51
docker-script.ps1
$ErrorActionPreference = 'Continue'
Stop-Service -Name "com.docker.*" -ErrorAction SilentlyContinue
Set-Service -Name "com.docker.service" -StartupType Automatic -ErrorAction SilentlyContinue
$processesToStop = @('Docker Desktop', 'com.docker.backend', 'com.docker.extensions')
$processesToStop | ForEach-Object {
Get-Process -Name $_ -ErrorAction Ignore | Stop-Process -Force -ErrorAction Ignore
}
$settingsToUpdate = @{
@arcanisgk
arcanisgk / steps.md
Created February 23, 2024 18:59
UseShellExecute = false vs Verb = "RunAs" while running an elevated parent application

These are the steps I am doing:

  1. Take VS2022 and open it with elevated privileges (as administrator).

  2. create a C#/Winform project for .net-8.0

  3. Embed a manifest that states:

  4. since I want it to always run as administrator in main form i am runing this method, add a script that allows me to relaunch the application as administrator:

     private static bool IsRunAsAdmin()
     {
    

try

@arcanisgk
arcanisgk / config.ym
Created October 27, 2023 00:35
flujo de trabajo
name: "CodeQL"
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
schedule:
- cron: '21 0 * * 4'
@arcanisgk
arcanisgk / docker-compose.yml
Last active September 22, 2023 18:25
reverse proxy + LAMP + Websocket in development
version: "3.8"
services:
reverse-proxy:
env_file:
- .env
container_name: Proxy-Server
image: jwilder/nginx-proxy:alpine
restart: always
volumes:
@arcanisgk
arcanisgk / docker-compose.yml
Created July 18, 2023 16:44
DNS+Revese Proxy+LAMP Stack
version: "3.9"
services:
dnsmasq:
env_file:
- .env
container_name: ${SYSTEM_NAME}-DNS-Server
image: jpillora/dnsmasq
ports:
@arcanisgk
arcanisgk / Session.php
Created January 17, 2023 17:08
Session.php
<?php
declare(strict_types=1);
namespace FrameWork\App;
use DataBase\UserAccount;
use Exception;
class Session
@arcanisgk
arcanisgk / quick_search.json
Created December 29, 2022 14:46
quick_search
This file has been truncated, but you can view the full file.
$srcfile = "C:\Users\wnune\OneDrive\Escritorio\imagenes\cardlist.txt"
$urls = Get-Content $srcfile
$lines = 0
switch -File $srcfile { default { ++$lines } }
$i = 0
$urls |
ForEach-Object -Parallel {
try {
$url = $_
$filename = Split-Path $url -Leaf
@arcanisgk
arcanisgk / list.txt
Created December 24, 2022 04:35
list card image yu-gi-oh database
https://images.ygoprodeck.com/images/cards/34541863.jpg
https://images.ygoprodeck.com/images/cards/64163367.jpg
https://images.ygoprodeck.com/images/cards/91231901.jpg
https://images.ygoprodeck.com/images/cards/73262676.jpg
https://images.ygoprodeck.com/images/cards/37478723.jpg
https://images.ygoprodeck.com/images/cards/64867422.jpg
https://images.ygoprodeck.com/images/cards/90861137.jpg
https://images.ygoprodeck.com/images/cards/44256816.jpg
https://images.ygoprodeck.com/images/cards/86988864.jpg
https://images.ygoprodeck.com/images/cards/11714098.jpg