Ory Kratos in Scoop - scoop-installer

I have a small question
I have run Ory Kratos using the following command in docker
docker-compose -f quickstart.yml -f quickstart-standalone.yml up --build --force-recreate
Now I am using scoop for windows so how to run the above command in using scoop in windows ? Like what to change in above command for scoop?

Related

Cant Install Laravel with Docker on Windows WSL

I can't seem to install the new laravel with Docker Desktop on Windows 10.
What I did so far:
I installed Docker Setup with WSL2.
then I installed Ubuntu Distro from Ms Store.
then on command prompt terminal I run wsl command then when I tried to run curl -s "https://laravel.build/example-app" | bash I got this error -sh: curl: not found.
I can't event use the apt command, it gives the same error.
The only working command is ls
WSL integration options on Docker Desktop are already checked
Am I missing something here? How to fix this?
It looks like the curl command is not installed in your Ubuntu WSL distribution. You can install it by running the following command in your WSL terminal:
sudo apt-get update
sudo apt-get install curl
This should install curl and allow you to run the curl command to download the Laravel installer script.
If you're still having trouble using apt, it's possible that your Ubuntu WSL distribution is not properly installed or configured. You may want to try reinstalling or resetting it.
Once you have curl installed, try running the Laravel installer script again with the curl command:
curl -s "https://laravel.build/example-app" | bash
This should create a new Laravel application in a directory called example-app.
If you're still having trouble, you can try using the Docker image for Laravel instead of installing it directly on your machine. The official Laravel Docker image includes everything you need to get started with Laravel in a containerized environment.

I have used the Bash script task in Azure DevOps for Snowflake schema change and using the Microsoft ubuntu agent

I have used the Bash script task in Azure DevOps for Snowflake schema change and using the Microsoft ubuntu agent. Now I need to change the agent to a Windows agent. Can you please help me with the below code to change? So that it will run smoothly on the windows agent also.
Code
echo 'Starting bash task'
echo "PROJECT_FOLDER $(PROJECT_FOLDER)"
python --version
echo 'Step 1: Installing schemachange'
pip install schemachange --upgrade
echo 'Step 2: Running schemachange'
schemachange -f $(PROJECT_FOLDER) -a $(SF_ACCOUNT) -u $(SF_USERNAME) -r $(SF_ROLE) -w $(SF_WAREHOUSE) -d $(SF_DATABASE) -c $(SF_DATABASE).SCHEMACHANGE.CHANGE_HISTORY --create-change-history-table
env:
SNOWFLAKE_PASSWORD: $(SF_PASSWORD)
When I run the same code with the windows agent, the build is failing with an error as an invalid root folder. The above is working fine with the ubuntu agent.

Docker is not running when run curl command to create new laravel project

I just start learning laravel, and follow the tutorial from https://laravel.com/docs/8.x/installation "Getting started on Windows" .
I manage to install Docker Desktop and COnfigured to use WSL2 Backend.
When I run the command curl -s https://laravel.build/example-app | bash to create laravel application directory from cmd, this warning come out Docker is not running.
I run curl using command prompt. (cmd).
Update:
So, I run the command in Windows Terminal:.
PS E:\Play> curl -s https://laravel.build/example-app | bash
Here is the response I get:
cmdlet Invoke-WebRequest at command pipeline position 1
Supply values for the following parameters:
Uri:
Any Idea what to do?
Try to explicitly enable integration with your distro in Docker settings:
After that relaunch your WSL2 terminal & try again. That should help.
You can also open https://laravel.build/example-app in a browser & check what commands the script is running: and run them manually to check the output for any errors.
For those who are using Ubuntu or Debian can check this guide out on how to install and configure Docker.
sudo snap install docker
sudo usermod -aG docker $(whoami)
sudo chmod 666 /var/run/docker.sock
You need to install a linux distro, and then in Windows Terminal create a new tab for the linux distro and run the command there, not in a windows powershell tab.
Make sure that you are running curl command on your distro. Use Windows Terminal app and open a new tab as WSL2 (your distro).
sudo chmod 666 /var/run/docker.sock
I guess you are using ubuntu or debian.
chmod will do the trick here.

Phundament under Windows - "Interactive mode is not yet supported on Windows"

I have Docker Toolbox installed under Windows 7. The Docker daemon is running inside a VM (the default behavior of Docker Toolbox).
I am trying to get Phundament running using the default tutorial.
It all works fine until I reach this command:
docker-compose run php composer install
It results in:
I've successfully attached to the running container using docker exec -it <container ID> bash but when I do a ls /app command on any of the two containers I get no files in that directory. In effect, the attempt to run composer install there fails.
I tried attaching to both containers and the result is identical.
I also noticed that behavior just recently, it's sadly a limitation of docker-compose on Windows.
For the command you mentioned you can actually run
docker-compose run -d php composer install
As general workarounds...
use docker exec -it app_php_1 bash
see also https://getcarina.com/docs/troubleshooting/troubleshooting-cannot-enable-tty-mode-on-windows/
if you don't really need an interactive shell, you could just run a command or script, like docker-compose run -d php setup.sh
Note: I need to double-check the above suggestions on a real Windows testing system.
PS: I am the author if Phundament. I've also just created an issue for this.
Please try:
winpty docker-compose run php composer install
it works for example:
winpty docker run --rm -it debian bash

'docker run -v' does not work on Windows using Docker Toolbox

When running the following command from a CoreOS VM, it works as expected:
docker run --rm -v $PWD:/data composer init
It will initialize the composer.json file in the current working directory by using the Docker volume mapping as specified. The Docker container basically has the PHP tool composer installed and will run that tool inside the /data folder of the container. By using the mapping it actually applies it on the files on the host machine.
However when trying to run this command on Windows using Docker Toolbox I get the following error.
$ docker run --rm -v $PWD:/data composer --help
invalid value "C:\\Users\\Marco;C:\\Program Files\\Git\\data" for flag -v: bad mount mode specified : \Program Files\Git\data
See 'C:\ProgramData\Chocolatey\lib\docker\bin\docker.exe run --help'.
What I notice here is although I am in Git Bash when executing the command it still uses Windows paths. So then I tried following (surround with quotes):
$ "docker run --rm -v $PWD:/data composer --help"
bash: docker run --rm -v /c/Users/Marco:/data composer --help: No such file or directory
Now it is unable to find the directory.
I also tried without the $PWD variable, but this doesn't make a difference.
How do I make this work on Windows?
This should work:
$ docker run --rm -v //c/Users/Marco:/data composer --help
Try MSYS_NO_PATHCONV=1 docker run ...
Git Bash tries to convert the path for other Windows commands.

Resources