• Home
  • PS
  • C#
  • Perl
  • MSSQL
  • MariaDB
  • Linux
  • Docker
  • MacOS
  • PG
  • Exchange Server
  • Windows
  • Other

Home

Как работают и создаются тома с bind и mount в Docker

Details
Written by: po3dno
Category: Linux
Created: 25 November 2024
Hits: 147

04 июня 2022


Создаем volume в Docker используя bind и mount на примерах


Запуская контейнер Docker нам может понадобится сохранить где-то данные или наоборот добавить их в контейнер. Для реализации этой задачи, в Docker, был создан объект томов и возможность проброса папок. Рассмотрим как это работает на примерах.

Read more …

Как работают и создаются тома с bind и mount в Docker

Details
Written by: po3dno
Category: Linux
Created: 25 November 2024
Hits: 157

04 июня 2022


Создаем volume в Docker используя bind и mount на примерах


Запуская контейнер Docker нам может понадобится сохранить где-то данные или наоборот добавить их в контейнер. Для реализации этой задачи, в Docker, был создан объект томов и возможность проброса папок. Рассмотрим как это работает на примерах.

Read more …

victoria-metrics

Details
Written by: po3dno
Category: Linux
Created: 20 November 2024
Hits: 173
mkdir -p /data/victoria-metrics-data

docker run -d -it --rm -v /data/victoria-metrics-data:/victoria-metrics-data -p 8428:8428 --name victoria-metrics victoriametrics/victoria-metrics

curl -v http://localhost:8428/metrics

Extract all DLLs from a Nuget package (nupkg) with Windows cmd batch file

Details
Written by: po3dno
Category: C#
Created: 13 November 2024
Hits: 197
@echo off
REM Extracts all .dll files from nugets in this folder or its subfolders and copies them to a subfolders
REM .
REM Note: Uses .NET 4.5 to unzip the nugets. If this fails, use 7zip or something similar. 
REM       See http://stackoverflow.com/questions/17546016/how-can-you-zip-or-unzip-from-the-command-prompt-using-only-windows-built-in-ca/26843122#26843122


echo Extracting all dlls from nugets to folder \extracted-dlls

REM %mypath% is where the batch file is located
set mypath=%~dp0

set temppath=%~dp0temp\
set dllpath=%~dp0extracted-dlls\

REM Delete old dlls
echo Deleting old files
rd /s /q %dllpath%"
mkdir %dllpath%

rem traverse all nupkg files
pushd %mypath%
	for /r %%a in (*.nupkg) do (
		
		echo \- Processing %%~nxa
		
		REM unzip nuget to %temppath% folder.
		powershell.exe -nologo -noprofile -command "& { Add-Type -A 'System.IO.Compression.FileSystem'; [IO.Compression.ZipFile]::ExtractToDirectory('%%a', '%temppath%'); }
		
		REM Copy all dlls 
		REM See: http://stackoverflow.com/questions/11720681/windows-batch-copy-files-from-subfolders-to-one-folder
		pushd %temppath%
			for /r %%b in (*.dll) do (
				echo     \- Found %%~nxb
				COPY "%%b" "%dllpath%%%~nxb"
			)
		popd
		
		REM Delete Temp folder
		rd /s /q %temppath%"
    )
popd

pause

nuget

Details
Written by: po3dno
Category: Windows
Created: 13 November 2024
Hits: 188

https://dist.nuget.org/win-x86-commandline/latest/nuget.exe

%USERPROFILE%\AppData\Local\Microsoft\WindowsApps

nuget add new_package.1.0.0.nupkg -source \\myserver\packages

 

Setup Proxy

First you’ll need to tell your PowerShell session to use your proxy. You might also need to change the TLS protocol that’s accepted. Basically, what’s happening above is just a bad error message. It’s not verbose enough to say “HTTPS failure” or anything like that.

$proxy = '<YOUR CORPORATE PROXY HERE>'  # update this
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
[system.net.webrequest]::defaultwebproxy = new-object system.net.webproxy($proxy)
[system.net.webrequest]::defaultwebproxy.credentials = [System.Net.CredentialCache]::DefaultNetworkCredentials
[system.net.webrequest]::defaultwebproxy.BypassProxyOnLocal = $true

Update Package Providers

This is similar-ish to sudo apt-get update. The first line gives you the package provider itself, the second registers PSGallery and the third installs PowerShellGet, which is basically an installer that a lot of packages use.

Install-PackageProvider -Name nuget -Scope AllUsers -Confirm:$false -Force -MinimumVersion 2.8.5.201
Register-PSRepository -Default -verbose
Install-Module -Name PowerShellGet -Scope AllUsers -Confirm:$false -Force -AllowClobber -MinimumVersion 2.2.4 -SkipPublisherCheck
  1. Disable Virtualization Based Security
  2. Установка и подключение PostgreSQL на Mac Os
  3. Working with ODBC Connections in Powershell
  4. Обход мастера приветствия Windows 11

Subcategories

Power Shell Article Count:  53

C# Article Count:  10

Perl Article Count:  1

Exchange Server Article Count:  15

Other Article Count:  24

MSSQL Article Count:  17

Windows Article Count:  25

MariaDB Article Count:  3

Linux Article Count:  7

Docker Article Count:  2

pg Article Count:  1

Page 2 of 32

  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10

Login Form

  • Forgot your password?
  • Forgot your username?

Statistics

  • Users 2
  • Articles 164
  • Articles View Hits 148993