unknown target when doing a fly sync - concourse

I have spun up a VM and I am trying to login to my concourse server with the following:
Christoher:pipeline christopher$ fly --target chris login --team-name chris --concourse-url http://ld4370.mycompany.com
Then, I am receiving this message:
WARNING:
fly version (2.5.0) is out of sync with the target (2.4.0). to sync up, run the following:
fly -t chris sync
However, when I do the following, I get this issue:
Christoher:pipeline christopher$ fly -t chris sync
error: unknown target: chris
At first, I had an older version of fly. So I deleted fly in my /usr/local/bin directory and then downloaded the latest. Now I am ahead of the concourse version that I installed on my VM. I have taken a look at the fly documentation but have not figured out how to get around this.

As an immediate fix to your problem, you can download any version of fly from github https://github.com/concourse/concourse/releases.

Download concourse & fly new version 5.0.0 on Mac do the following:
Download the latest version from concourse website https://mockersf.github.io/docs/download.html
then open finder press CMD + Shift + .
it will make all your hidden files visible temporarily open your user/local/bin folder then drag the new version of concourse to the bin and click replace
do the same for the fly and now go in command line press fly --version and you should see the new version

Download/ update concourse and fly version 4 and below 4 Hi go to this website basically you need to install the relevant version https://gist.github.com/kevin-smets/f20afd45a24ab3f88d01b2049ce7744f
for example:
copy this command
curl -Lo fly https://github.com/concourse/concourse/releases/download/2.5.0/fly_darwin_amd64 && chmod +x fly && mv fly /usr/local/bin/
and changed the version v2.6.0 to v2.5.0 past it in the terminal and same goes for the below :
curl -Lo concourse
https://github.com/concourse/concourse/releases/download/v2.4.0/concourse_darwin_amd64 && chmod +x concourse && mv concourse /usr/local/bin
and it should work.
I had similar problem i wanted install the v4.2.2 and it worked. the idea is the get the same version

Related

Install MongoDB on Manjaro

I'm facing difficulties installing the MongoDB community server on Manjaro Linux.
There isn't official documentation on how to install it on Arch-based systems and Pacman can't find it in the AUR repos.
Has anyone ever tried to install it?
Here is what I did to install.
As the package is not available in the official Arch repositories and can't be installed using pacman, you need to follow a few steps to install it.
First, you need to get the URL for the repo of prebuilt binaries from AUR. It can be found here and by the time of writing this it was https://aur.archlinux.org/mongodb-bin.git
Simply clone the repo in your home directory or anywhere else. Do git clone https://aur.archlinux.org/mongodb-bin.git, then head to the cloned directory, cd mongodb-bin.
Now, all you need to do is to run makepkg -si command to make the package. the -s flag will handle the dependencies for you and the -i flag will install the package.
After makepkg finishes its execution, don't forget to start mongodb.service. Run systemctl start mongodb and if needed enable it with systemctl enable mongodb.
Type mongo in the terminal and if the Mongo Shell runs you are all set.
Later edit (8.2.2021): This package is now available in AUR.
It is available in AUR, so you can view it with pamac with -a flag,
eg.
pamac search -a mongodb-bin
pamac info -a mongodb-bin
And, then build and install with (this can be done after manually cloning too) -
pamac build mongodb-bin
Note that there's also a package named mongodb, but mongodb-bin is a newer release (you can check the version numbers by search or info arguments)
I've been using mongodb via docker for a couple of years.
In my experience, it's easier than installing the regular way. (assuming you already have docker installed)
1. Ensure you have docker installed
If you don't already have it, you can install via pacman/pamac, because it's in the official Arch/Manjaro package repositories. The easiest way is to run the following command:
sudo pacman -S docker
2. Run a single docker command
sudo docker run -d -p 27017:27017 -v ~/mongodb_data:/data/db mongo
This command will run mongodb on a port 27017, and place its data files into a folder ~/mongodb_data.
If you're running this command for the first time, it will also download all the required files.
Now you're successfully running a local instance of mongodb, and you can connect it with your favorite db management tool or from your code.

when i upgrade mongo it still says version 2.x.x , how can i go to a higher version?

How do I upgrade from mongo version 2 to version 3 ?
I am trying to upgrade from mongo 2.x.x to the latest version (which at the time is 3.2.x).
The official (3.2 upgrade) instructions say I need to go to version 3.0.x first and so that is all i'm trying to achieve right now - to get from version 2 to version 3.
First try : apt-get
I first tried using apt-get, following these instructions (linked to from this page, which was linked to from these official (3.0 upgrade) instructions).
That all appeared to work alright, however my version ($ mongo --version) number didn't change, so no upgrade actually happened at all.
Second try : mongod-10gen
I then found these instructions and followed them.
This time, again, every step was successful but the end result was that my version has now gone down! (from 2.6.1 to 2.4.14)
I've also tried following the instructions in this SO answer, which are essentially the same as the other instructions - and gave the same result - success on every step, but the final result is still a v2 mongo.
Third try : copy the binaries
The official (3.0 upgrade) instructions actually first suggest downloading and copying over the binaries (but I tried the auto install instructions first because that seemed easier).
My binaries are all actually directly in /usr/bin/.
Get the url for the binaries for your system (for the curl command below) from the download binaries page.
(For me it was for Ubuntu 14, for previous release, v3.0.14)
Then download the binaries, and copy them directly into /usr/bin/.
Like so:
$ curl https://fastdl.mongodb.org/linux/mongodb-linux-x86_64-ubuntu1404-3.0.14.tgz -o mongo_3.0.14.tgz
$ tar -xvf mongo_3.0.14.tgz
$ sudo service mongod stop # stop DB
$ sudo cp mongodb-linux-x86_64-ubuntu1404-3.0.14/bin/* /usr/bin
$ sudo service mongod start # and restart
$ mongo --version
MongoDB shell version: 3.0.14
Success!!
So, the correct approach was to follow the initial instructions - however it was not obvious to me what "copy the binaries" meant at first, and the alternative auto install with apt-get I really thought would be the simple and right way to go (why doesn't that work??) - I suspect others will come across this problem so I will put this third try as an answer and still post the question

Snapcraft Placing Default Config Files

I am trying to build an application release by using Snapcraft.io, and I have almost all working.Snapcraft already compiles the source code, generates the .snap file, includes all the dependencies, and so on.However, I am stuck at how I can initialize some configuration files in the SNAP_USER_DATA folder after the first app install.I do not want to place the files in the default read-only path SNAP, as the default parameters should be modified by the user, also I need to generate some additional files, like server certificates.So I need to copy some files, and also run a script after the first install. Is this possible?
Thanks.
Because snaps are installed as root, it's impossible to do exactly as you ask at install time, as $SNAP_USER_DATA is user-specific, so it'll always be root's. However, you can do this at install-time using a system-wide directory, such as $SNAP_DATA, using the install hook:
$ snapcraft init
Created snap/snapcraft.yaml.
Edit the file to your liking or run `snapcraft` to get started
Create the hook. In our case we'll just create a new file in $SNAP_DATA, but you could do whatever you wanted.
$ mkdir -p snap/hooks
$ echo "touch \$SNAP_DATA/foo" >> snap/hooks/install
$ chmod a+x snap/hooks/install
Build the snap.
$ snapcraft
Preparing to pull my-part
Pulling my-part
Preparing to build my-part
Building my-part
Staging my-part
Priming my-part
Snapping 'my-snap-name' |
Snapped my-snap-name_0.1_amd64.snap
Install the snap. This will run the install hook.
$ sudo snap install my-snap-name_0.1_amd64.snap --devmode --dangerous
my-snap-name 0.1 installed
Notice a file was created in $SNAP_DATA.
$ ls /var/snap/my-snap-name/current
foo
The only way to get similar functionality for $SNAP_USER_DATA would be to wrap your real command in a script that creates the config. This command is then run by the user, which means you get the $SNAP_USER_DATA you intend. Of course, this isn't at install-time.

MySQL Workbench - Cannot add columns to a table

I have a critical problem with MySQL Workbench: I actually cannot edit the "Columns" tab, because it is greyed out.
I tried to edit a table's columns both for a newly created diagram and for an existing diagram, but with no luck. Is there a bug in the last versions of WB, or am I missing something else?
I found this problem both with the WB version installed via the OS package management (apt) and with the version installed from source.
OS: debian jessie/sid
WB version (installed via APT): 6.1.7 build 1788 (6.1.7+dfsg-1)
WB version (installed from source): 6.2.3 build 2280
P.S. I have already readed a couple of similar questions (see here and here), but they don't fit with my problem.
If you want it to work before Debian updates it, I suggest you to download the mysql-workbench source, apply this patch, build the package and then install it.
EDIT:
Instructions
As normal user, open a terminal and do the following:
cd ~
mkdir mysql-workbench-source
cd mysql-workbench-source
su root (type root password)
apt-get install build-essential
apt-get install pbuilder
apt-get source mysql-workbench
apt-get build-dep mysql-workbench
cd mysql-workbench-6.1.7+dfsg/frontend/linux/linux_utilities
cp ~/Downloads/glib.diff . (don't forget the last dot).
patch <glib.diff
cd ~/mysql-workbench-6.1.7+dfsg
debuild -us -uc -b (this will take a while)
cd ..
dpkg -i mysql-workbench_6.1.7+dfsg-1_amd64.deb
dpkg -i mysql-workbench-data_6.1.7+dfsg-1_all.deb
It should be fixed now.
If it's like my problem was - I created a table and I couldn't add columns - there was a panel over the editable area. Maximize the window, and it should become visible.
There seems to be a problem on the linux platform which needs to be addressed by the dev team. The best way to have this fixed quickly is to create a bug report on http://bugs.mysql.com. Give it a high severity.

Magento refuses to upgrade 1.4.2.0 ===> 1.5.0.1

This is my first time using Magento. I upgraded this site from 1.4.1.1 to 1.4.2.0 without issue. Now trying to go to 1.5.0.1 it just seems to refuse at every turn. I tried by entering this key into Magento Connect:
magento-core/Mage_All_Latest
And it says this:
Ignoring installed package magento-core/Mage_All_Latest
Nothing to install
I tried to upgrade via SSH and got this:
Attempting to discover channel "magento-core"...
unknown channel "magento-core" in "magento-core/Mage_All_Latest"
invalid package name/package file "magento-core/Mage_All_Latest"
Cannot initialize 'magento-core/Mage_All_Latest', invalid or missing package file
Package "magento-core/Mage_All_Latest" is not valid
install failed
In the downloader I noticed a the downloader had a version 1.5.0.0 upgrade available. I thought maybe I needed the newest downloader before I could update all the packages. I upgraded just the downloader to 1.5.0.0 which worked. Then I tried the full upgrade again and now it is mega retarded with this:
Couldn't resolve host 'magento-core'
That’s cute isn't it? So I gave it once last whirl at the ssh console and i get this bad boy:
Attempting to discover channel "magento-core"...
Attempting fallback to https instead of http on channel "magento-core"...
unknown channel "magento-core" in "magento-core/Mage_All_Latest"
invalid package name/package file "magento-core/Mage_All_Latest"
install failed
I tried a forcing it via SSH but still no love. I reverted from a backup I made so I do not have downloader 1.5.0.0 any more. Now of course I am back to square one with it telling me there is nothing to install when I try to update via MC.
When I check in MC if there are any updates available it lists these two:
Mage_All_Latest Upgrade to 1.4.2.1 (stable) Metapackage for latest Magento 1.4 release
And the Mage Downloader 1.5.0.1 but I already installed these before and it did no good so I restored my backup before the failed update.
I was trying to ask this question Magento's Forums but they are a mess right now. Their captcha fails and threads close on their own so you get little to no help. I wouldn't be surprised if they did this on purpose in concert with their 1.5.0.1 release.
Go to the root of your website and execute these commands (Where index.php is):
wget http://www.magentocommerce.com/downloads/assets/1.5.0.1/magento-1.5.0.1.tar.gz
tar -zxvf magento-1.5.0.1.tar.gz
Skip the next 4 commands if you have your magento install in a folder called Magento:
cd magento
cp -rf * /home/bitscom/public_html
cd ../
rm -rf magento
rm magento-1.5.0.1.tar.gz
For a detailed explanation see my post on the offical magento forum: here My name is Veracious on there.
If your SSH account is anything other than your apache user (i.e.: root. you will get error 500 when trying to access the site do the the permissions on the new files you just extracted. To resolve that use chown and chgrp. For a detailed explanation once again see my post:
here
I think the location for the upgrades have changed. Instead of the:
magento-core/Mage_All_Latest
use:
community/Mage_All_Latest
As what mrdon has mentioned.
I couldn't upgrade through Magento Connect either. I followed these instructions for installing magento and it worked fairly well. I changed line 3 as below to copy the folders/files over my existing ones.
wget http://www.magentocommerce.com/downloads/assets/1.5.0.1/magento-1.5.0.1.tar.gz
tar -zxvf magento-1.5.0.1.tar.gz
cp magento/* magento/.htaccess .
chmod -R o+w media var
chmod o+w app/etc
I followed the instructions from the following post to upgrade from 1.4.1.1 to 1.5.0.1:
http://www.magentocommerce.com/boards/viewthread/219720/#t301761
Then flushed the cache and reindexed everything. Everything worked.
Don't forget to change magento folder ownership to your web server user. In my case I had to run
chown -R www-data:www-data /var/www/magento