So I want my PyPI username and password to be secret to upload the module secretly also I want my readthedocs.io API token secret to fact that I can’t keep it on GitHub cuz it is public!
So I see the environment variable and context that Circle CI provides and I use it, So config.YAML content is like this!
version: 2.1 jobs: build_module: docker: - image: circleci/python:3.9.5 steps: - checkout - run: command: | python setup.py sdist sudo pip install dist/* sudo pip install twine sudo twine upload dist/* build_document: docker: - image: circleci/python:3.9.5 steps: - checkout - run: command: | sudo pip install requests sudo python builddoc.py workflows: build_module: jobs: - build_module: context: API_TOKEN_TWINE_API build_document: jobs: - build_document: context: API_TOKEN_TWINE_API
After killing my head with error stuff I now can build and there’s another problem.
I CAN NOT GET MY ENVIRONMENT VARIABLE FROM THE PROJECT ENVIRONMENT VARIABLE OR CONTEXT!!
When I try to print out the list of environment variable, the result shock me.
HOSTNAME LANG PATH DEBIAN_FRONTEND MAIL LOGNAME USER HOME SHELL TERM SUDO_COMMAND SUDO_USER SUDO_UID SUDO_GID
Where’s the environment variable that I set go?
Where is it?
I recheck everything but nothing is fixed.
Help I am new at Circle CI. I just come from Github Workflow