Skip to content
This repository has been archived by the owner on Feb 20, 2020. It is now read-only.

Do not set version=latest when package manager is pkg. #30

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

boukeversteegh
Copy link
Contributor

No value implies latest by default. It results in an error to specify version=latest.

E: Version 'latest' for 'go-server' was not found

@@ -8,7 +8,7 @@

- name: apt install go-server
sudo: yes
apt: pkg=go-server={{ GOCD_GO_VERSION }} state=present force=yes
apt: pkg=go-server{{ '=' + GOCD_GO_VERSION if GOCD_GO_VERSION != 'latest' else ''}} state=present force=yes
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would you make a similar change for go-server yum installer and the go-agent playbooks?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm I think that I was using this package in a different way than intended; namely I ran the Common role separately from the Server / Agent role (because they may be different machines). It looks like then the common role is run in the same play with server or agent, then GOCD_GO_VERSION=latest is replaced by the actual latest version, but this change does not pass on to the server/agent role when it is in a separate play.

I will also change the go-agent there none the less.

I cannot test yum as my disk is too full to launch another VM, so i will just change apt for now.

@ghost
Copy link

ghost commented Feb 20, 2020

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants