Search This Blog

Sunday 1 November 2020

Problem with installing "Cloud Foundry" CLI on MacOS!

It's a while I'm working on a government project which will deploy into a government platform as a service that is called GovPaaS.

 just in case, if someone doesn't know about GovPaaS, it's a platform built by the "Cloud foundry" technology that is using AWS as a hosting platform, but you don't have access to any of AWS services at all.

I should speak about its Pros & Cons in a different article, but our dev team (recently moved from windows to MacOS) just realized when they follow the GovPaaS instruction for downloading the CLI and installing it on the Mac, They couldn't run it.

Problem:

the CLI package isn't signed and therefore it's not trustworthy, if you run an old version of macOS, you can get away from it, but it's not the case when you are on the latest version.

here is a generic message:




Solution:

You can install the cf CLI on Mac OS X operating systems using the Homebrew package manager.

To install the cf CLI for Mac OS X using Homebrew:

  1. Install Homebrew. For instructions, see Install Homebrew on the Homebrew website.

  2. To install cf CLI v6, run:

    brew install cloudfoundry/tap/cf-cli
    
  3. To install cf CLI v7, run:

    brew install cloudfoundry/tap/cf-cli@7
    

 




Tuesday 26 May 2020

installing Heroku CLI on windows Subsystem for Linux

One of my colleagues just told me that he couldn't install the "Heroku CLI" on his WSL (Windows Subsytem for Linux)

The normal command is as below:
sudo snap install --classic heroku

I tried it on my WSL and I saw that the below error message:

Interacting with snapd is not yet supported on Windows Subsystem for Linux.
This command has been left available for documentation purposes only.

obviousely the currently "snap" is not supported on WSL yet!
but if I run the below command, it will do the same job:

curl https://cli-assets.heroku.com/install.sh | sh

Sunday 24 May 2020

How do I replace some text inside a text file with te buildId of a build/reease and save it back in the Azure DevOps ?

I would be a millionaire if I could ask a penny for each time that my colleagues ask me this question.
 
I would just run a PowerShell task with something like the below example:

<div class="code">
</div>
a=b+c

$oldValue = 'default-value'
$newValue = '$(Build.BuildId)'
$filePath='path-to-your-file/filename.txt'
(Get-Content $filePath) -replace $oldValue , $newValue | Set-Content $filePath




Friday 7 February 2020

Hello World! , Do you need a hand?

I had many titles and hats in the software development life cycle, e.g. developer, architect, engineering manager,... and always learned a lot from my colleagues and different online communities. Now when I looked at my past, my only regret is why I didn't start to give back to the community, so today I decided to start blogging!

I like to write something useful for others, so from today whenever one of my colleagues asked me to help him with anything, I do my best and then in the evening I will post about that problem.

Cheers
Farzad the polyglot Architect

Problem with installing "Cloud Foundry" CLI on MacOS!

It's a while I'm working on a government project which will deploy into a government platform as a service that is called GovPaaS.  ...