I’m running makefile in Githubactions. My makefile is failing to run touch command. I’m not sure what is the error here.
Tried adding : `$(shell) to make command, still the same error. It worked in jenkins and locally.
Make file:
test:
$(Shell prometheus/generated_config.sh --first-cluster-url "test.yl4.us-east-1.eks.amazonaws.com" --first-cluster-name test --first-cluster-token "test" --test-context)
Make version:
Run make --version
make --version
shell: /usr/bin/bash -e {0}
GNU Make 4.3
Built for x86_64-pc-linux-gnu
Copyright (C) 1988-2020 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Workflow file:
- name: prometheus-deploy-${{ inputs.environment }}
env:
FIRST_KUBE_TOKEN: ${{ secrets.FIRST_KUBE_TOKEN }}
DEPLOYER_KEY: ${{ secrets.IHR_DEPLOYER_KEY }}
FIRST_CLUSTER_URL: ${{ secrets.FIRST_CLUSTER_URL }}
CLUSTER_NAME: ${{ secrets.CLUSTER_NAME }}
SSH_HOST: ${{ secrets.SSH_HOST }}
run: |
touch DEPLOYER_KEY.pem
echo "${DEPLOYER_KEY}" >> DEPLOYER_KEY.pem
chmod 0600 ./DEPLOYER_KEY.pem
echo $SHELL
ls prometheus/
sudo chsh -s /bin/bash
if [[ "true" == "true" ]]; then
export CONFIG_ONLY_FLAG='--config-only'
make test
./prometheus/generate_config.sh --first-cluster-url "${FIRST_CLUSTER_URL}" --first-cluster-name "${CLUSTER_NAME}" --first-cluster-token "${FIRST_KUBE_TOKEN}"
ERROR:
shell: /usr/bin/bash -e {0}
env:
FIRST_KUBE_TOKEN: ***
IHR_DEPLOYER_KEY: ***
FIRST_CLUSTER_URL: ***
CLUSTER_NAME: ***
SSH_HOST: ***
/bin/bash
config
generate_config.sh
rules
tests
web-config.yml
prometheus/generate_config.sh --first-cluster-url "test.yl4.us-east-1.eks.amazonaws.com" --first-cluster-name test --first-cluster-token "test" --test-context
touch: cannot touch '/home/runner/_work/prometheus/project-prometheus/prometheus/generated_config/first_token': No such file or directory
touch: cannot touch '/home/runner/_work/prometheus/project-prometheus/prometheus/generated_config/second_token': No such file or directory