Can I programmatically access gitlab secrets hash

0 votes

I have ansible on my control machine. I'm trying to setup gitlab using omnibus package. After this, I need to setup runner and mattermost.

In any case, I need the secret hash from gitlab web app to provide it to runner and mattermost.


Runner: 'regis-token'

mattermost: 'app- id' and 'app-secret'

I have checked the gitlab api and couldn't find a way to get them. I want to know is there any programmatical way through which we can access the secrets without comromising the security?

Mar 29, 2018 in Git & GitHub by Atul
• 10,230 points

1 answer to this question.

0 votes

The newer versions of gitlab do support application creation through API:

and to create a token you can do somthing like this:

sudo -u postgres psql -d gitlab_production -c "INSERT INTO personal_access_tokens VALUES ('1','1','SOMEHASH','initialToken','false','2020-01-01', '2018-01-01 12:00:00', '2018-01-01 12:00:00', E'--- \n- api \n- read_user \n');"
answered Mar 29, 2018 by DareDev
• 6,890 points

Related Questions In Git & GitHub

0 votes
1 answer

How can I retrieve previous version data in Git & GitHub!!?

Hi@akhtar, You can use reset command to do ...READ MORE

answered Jul 19, 2020 in Git & GitHub by MD
• 95,320 points
0 votes
1 answer

How can I set ssh key in GitHub?

Hi@akhtar, First you have to generate key using ...READ MORE

answered Feb 4, 2020 in Git & GitHub by MD
• 95,320 points
0 votes
1 answer

How do I access my SSH public key?

Hi@akhtar, You can use the cat command in ...READ MORE

answered Jan 4, 2021 in Git & GitHub by MD
• 95,320 points
0 votes
1 answer

Version control as source to gitlab

The steps I'm going to tell you ...READ MORE

answered Apr 23, 2018 in Git & GitHub by ajs3033
• 7,280 points
0 votes
1 answer

How do I solve a Git checkout error: updating paths is incompatible with switching branches?

This error occurs when you are checking ...READ MORE

answered Jul 26, 2018 in Git & GitHub by Sophie may
• 10,570 points
0 votes
1 answer
+15 votes
2 answers

Git management technique when there are multiple customers and need multiple customization?

Consider this - In 'extended' Git-Flow, (Git-Multi-Flow, ...READ MORE

answered Mar 27, 2018 in DevOps & Agile by DragonLord999
• 8,450 points
+2 votes
1 answer