|
36 | 36 | - '.github/workflows/java-code-analysis.yml' |
37 | 37 | - '.github/workflows/*documentation.yml' |
38 | 38 |
|
39 | | -# Requires the secret NEO4J_INITIAL_PASSWORD to be configured |
40 | 39 | jobs: |
41 | 40 | analysis-results: |
42 | 41 | runs-on: ubuntu-latest |
@@ -64,14 +63,23 @@ jobs: |
64 | 63 | - name: (Code Analysis Setup) Set ANALYSIS_NAME |
65 | 64 | run: echo "ANALYSIS_NAME=${{ env.PROJECT_NAME }}-${{ env.REACT_ROUTER_VERSION }}" >> $GITHUB_ENV |
66 | 65 |
|
| 66 | + - name: (Code Analysis Setup) Generate Neo4j Initial Password |
| 67 | + id: generate_neo4j_initial_password |
| 68 | + shell: bash |
| 69 | + # generated_password=$(LC_ALL=C tr -dc 'A-Za-z0-9!?%=' < /dev/urandom | head -c 10) |
| 70 | + run: | |
| 71 | + generated_password=$(head -c 10 <(LC_ALL=C tr -dc 'A-Za-z0-9!?%=' < /dev/urandom)) |
| 72 | + echo "::add-mask::$generated_password" |
| 73 | + echo "neo4j_initial_password=$generated_password" >> "$GITHUB_OUTPUT" |
| 74 | + |
67 | 75 | - name: Setup Code Analysis |
68 | 76 | uses: ./.github/actions/setup-code-analysis |
69 | 77 | with: |
70 | 78 | java-version: ${{ matrix.java }} |
71 | 79 | python-version: ${{ matrix.python }} |
72 | 80 | miniforge-version: ${{ matrix.miniforge }} |
73 | 81 | analysis-name: ${{ env.ANALYSIS_NAME }} |
74 | | - neo4j-password: ${{ secrets.NEO4J_INITIAL_PASSWORD }} |
| 82 | + neo4j-password: ${{ steps.generate_neo4j_initial_password.outputs.neo4j_initial_password }} |
75 | 83 |
|
76 | 84 | - name: (Code Analysis Setup) Download ${{ env.ANALYSIS_NAME }} |
77 | 85 | working-directory: code-graph-analysis-pipeline/temp/${{ env.ANALYSIS_NAME }} |
|
93 | 101 | # Shell type can be skipped if jupyter notebook analysis-results (and therefore conda) aren't needed |
94 | 102 | shell: bash -el {0} |
95 | 103 | env: |
96 | | - NEO4J_INITIAL_PASSWORD: ${{ secrets.NEO4J_INITIAL_PASSWORD }} |
| 104 | + NEO4J_INITIAL_PASSWORD: ${{ steps.generate_neo4j_initial_password.outputs.neo4j_initial_password }} |
97 | 105 | ENABLE_JUPYTER_NOTEBOOK_PDF_GENERATION: "true" |
98 | 106 | IMPORT_GIT_LOG_DATA_IF_SOURCE_IS_PRESENT: "" # Options: "none", "aggregated", "full". default = "plugin" or "" |
99 | 107 | run: | |
|
0 commit comments