Skip to content

Commit

Permalink
Install cronie package on main node (#432)
Browse files Browse the repository at this point in the history
Signed-off-by: Rishabh Singh <sngri@amazon.com>
  • Loading branch information
rishabh6788 committed Jun 10, 2024
1 parent b43f71e commit f7cdddd
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 9 deletions.
3 changes: 3 additions & 0 deletions lib/compute/jenkins-main-node.ts
Original file line number Diff line number Diff line change
Expand Up @@ -235,6 +235,7 @@ export class JenkinsMainNode {
reloadPasswordSecretsArn: string, efsId?: string): InitElement[] {
return [
InitPackage.yum('wget'),
InitPackage.yum('cronie'),
InitPackage.yum('openssl'),
InitPackage.yum('mod_ssl'),
InitPackage.yum('amazon-efs-utils'),
Expand All @@ -243,6 +244,8 @@ export class JenkinsMainNode {
InitPackage.yum('python3'),
InitPackage.yum('python3-pip.noarch'),
InitCommand.shellCommand('pip3 install botocore'),
InitCommand.shellCommand('systemctl enable crond.service'),
InitCommand.shellCommand('systemctl start crond.service'),
// eslint-disable-next-line max-len
InitCommand.shellCommand('sudo wget -nv https://github.com/mikefarah/yq/releases/download/v4.22.1/yq_linux_amd64 -O /usr/bin/yq && sudo chmod +x /usr/bin/yq'),
// eslint-disable-next-line max-len
Expand Down
4 changes: 2 additions & 2 deletions lib/compute/oidc-config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -79,14 +79,14 @@ export class OidcConfig {
roleBased: {
roles: {
global: [{
entries: adminUsers.map(user => ({ user })),
entries: adminUsers.map((user) => ({ user })),
name: 'admin',
pattern: '.*',
permissions: OidcConfig.adminRolePermissions
,
},
{
entries: readOnlyUsers.map(user => ({ user })),
entries: readOnlyUsers.map((user) => ({ user })),
name: 'read',
pattern: '.*',
permissions: OidcConfig.readOnlyRolePermissions,
Expand Down
4 changes: 2 additions & 2 deletions test/compute/jenkins-main-node.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,8 @@ describe('JenkinsMainNode Config Elements', () => {

// THEN
test('Config elements expected counts', async () => {
expect(configElements.filter((e) => e.elementType === 'COMMAND')).toHaveLength(22);
expect(configElements.filter((e) => e.elementType === 'PACKAGE')).toHaveLength(9);
expect(configElements.filter((e) => e.elementType === 'COMMAND')).toHaveLength(24);
expect(configElements.filter((e) => e.elementType === 'PACKAGE')).toHaveLength(10);
expect(configElements.filter((e) => e.elementType === 'FILE')).toHaveLength(4);
});

Expand Down
9 changes: 4 additions & 5 deletions test/data/test_env.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,9 @@ globalCredentialsConfiguration:
configuration:
providerFilter: none
typeFilter: none
appearance:
loginTheme:
useDefaultTheme: true
security:
apiToken:
creationOfLegacyTokenEnabled: false
Expand Down Expand Up @@ -185,7 +188,7 @@ unclassified:
apiRateLimitChecker: ThrottleForNormalize
gitHubPluginConfig:
hookUrl: http://localhost:8080/github-webhook/
gitSCM:
scmGit:
addGitTagAction: false
allowSecondFetch: false
createAccountBasedOnEmail: false
Expand All @@ -199,14 +202,10 @@ unclassified:
storage: file
location:
adminAddress: address not configured yet <nobody@nowhere>
login-theme-plugin:
useDefaultTheme: true
mailer:
charset: UTF-8
useSsl: false
useTls: false
pluginImpl:
enableCredentialsFromNode: false
pollSCM:
pollingThreadCount: 10
timestamper:
Expand Down

0 comments on commit f7cdddd

Please sign in to comment.