Skip to main content

cdk-valheim

Project description

GitHub Workflow Status GitHub license npm PyPI - Downloads

cdk-valheim

A high level CDK construct of Valheim dedicated server.

Features

  • Fargate cluster to run a Valheim server, with EFS for persistence (schedulable)
  • Hourly AWS Backup with 3 days retention (customizable)
  • lloesche/valheim-server as the default container image (replaceable)

See integration test for an example.

API Doc

See API.md

References

Examples

The construct is published to both npm and PyPI.

TypeScript

new ValheimWorld(stack, 'ValheimWorld', {
  cpu: 2048,
  memoryLimitMiB: 4096,
  schedules: [{
    start: { hour: '12', weekDay: '1-5' },
    stop: { hour: '1', weekDay: '1-5' },
  }],
  environment: {
    SERVER_NAME: 'CDK Valheim',
    WORLD_NAME: 'Amazon',
    SERVER_PASS: 'fargate',
    BACKUPS: 'false',
  },
});

Python

ValheimWorld(
    self,
    'ValheimWorld',
    cpu=2048,
    memory_limit_mib=4096,
    schedules=[ValheimWorldScalingSchedule(
        start=CronOptions(hour='12', week_day='1-5'),
        stop=CronOptions(hour='1', week_day='1-5'),
    )],
    environment={
        'SERVER_NAME': 'CDK Valheim',
        'WORLD_NAME': 'Amazon',
        'SERVER_PASS': 'fargate',
        'BACKUPS': 'false',
    })

Testing

  • Unit test and snapshot test
npx projen test
  • Integration test
npx cdk -a "npx ts-node src/integ.valheim.ts" diff
npx cdk -a "npx ts-node src/integ.valheim.ts" deploy

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cdk-valheim-0.0.26.tar.gz (388.8 kB view details)

Uploaded Source

Built Distribution

cdk_valheim-0.0.26-py3-none-any.whl (387.0 kB view details)

Uploaded Python 3

File details

Details for the file cdk-valheim-0.0.26.tar.gz.

File metadata

  • Download URL: cdk-valheim-0.0.26.tar.gz
  • Upload date:
  • Size: 388.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.3

File hashes

Hashes for cdk-valheim-0.0.26.tar.gz
Algorithm Hash digest
SHA256 98955d54456fa3c691713c707c7ee6127c3a9503bd70fa8a26286c8e078b7dc8
MD5 5f79118399c8a2ebeabe4f87a724d237
BLAKE2b-256 0a49313b4b51aac1fda459a16ebef2566c5e92f3c495b76e9eb8d9993cca7468

See more details on using hashes here.

File details

Details for the file cdk_valheim-0.0.26-py3-none-any.whl.

File metadata

  • Download URL: cdk_valheim-0.0.26-py3-none-any.whl
  • Upload date:
  • Size: 387.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.11.3

File hashes

Hashes for cdk_valheim-0.0.26-py3-none-any.whl
Algorithm Hash digest
SHA256 8d016e1252565ca37b9cafa0fca0a4897a2636199fca8cc7bb126e13bc346c15
MD5 92a6115f477cb149930f8c4d0d574272
BLAKE2b-256 4fcec6e754e4f70b7833d0461d6268d52f7255e30b4dcc86f60adc6ff4f5ce26

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page